Skip to content

Commit ca4a90c

Browse files
committed
Update
1 parent d9bd0a3 commit ca4a90c

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/Files.App/NativeMethods.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,3 +99,4 @@ S_OK
9999
S_FALSE
100100
MSG
101101
E_NOTIMPL
102+
LOGFONTW

src/Files.App/Utils/Shell/PreviewHandler.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@
55
using Windows.UI;
66
using Windows.Win32;
77
using Windows.Win32.Foundation;
8+
using Windows.Win32.Graphics.Gdi;
89
using Windows.Win32.System.Com;
10+
using Windows.Win32.UI.WindowsAndMessaging;
911

1012
namespace Files.App.Utils.Shell
1113
{
@@ -94,7 +96,7 @@ interface IPreviewHandlerVisuals
9496
[PreserveSig]
9597
HRESULT SetBackgroundColor(uint color);
9698
[PreserveSig]
97-
HRESULT SetFont(ref LOGFONT plf);
99+
HRESULT SetFont(ref LOGFONTW plf);
98100
[PreserveSig]
99101
HRESULT SetTextColor(uint color);
100102
}
@@ -488,7 +490,7 @@ public bool SetForeground(Color color)
488490
/// </summary>
489491
/// <param name="font">The LogFontW reference.</param>
490492
/// <returns>Whether the call succeeds.</returns>
491-
public bool SetFont(ref LOGFONT font)
493+
public bool SetFont(ref LOGFONTW font)
492494
{
493495
var hr = visuals?.SetFont(ref font);
494496
return hr.HasValue && (int)hr.Value >= 0;

0 commit comments

Comments
 (0)