Jacek Caban : win32u: Simplify get_text_metr_size.
Alexandre Julliard
julliard at winehq.org
Mon Jun 13 16:02:16 CDT 2022
Module: wine
Branch: master
Commit: 6ead654f5537c75e61294bd2ea6acfc97247db2b
URL: https://source.winehq.org/git/wine.git/?a=commit;h=6ead654f5537c75e61294bd2ea6acfc97247db2b
Author: Jacek Caban <jacek at codeweavers.com>
Date: Fri Jun 10 18:40:27 2022 +0200
win32u: Simplify get_text_metr_size.
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
---
dlls/win32u/sysparams.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/dlls/win32u/sysparams.c b/dlls/win32u/sysparams.c
index 7c333953f7e..0b6053a5ab9 100644
--- a/dlls/win32u/sysparams.c
+++ b/dlls/win32u/sysparams.c
@@ -2743,14 +2743,13 @@ static LONG get_char_dimensions( HDC hdc, TEXTMETRICW *metric, LONG *height )
/* get text metrics and/or "average" char width of the specified logfont
* for the specified dc */
-static void get_text_metr_size( HDC hdc, LOGFONTW *plf, TEXTMETRICW *metric, UINT *psz)
+static void get_text_metr_size( HDC hdc, LOGFONTW *lf, TEXTMETRICW *metric, UINT *psz )
{
- ENUMLOGFONTEXDVW exdv = { .elfEnumLogfontEx.elfLogFont = *plf };
HFONT hfont, hfontsav;
TEXTMETRICW tm;
UINT ret;
if (!metric) metric = &tm;
- hfont = NtGdiHfontCreate( &exdv, sizeof(exdv), 0, 0, NULL );
+ hfont = NtGdiHfontCreate( lf, sizeof(*lf), 0, 0, NULL );
if (!hfont || !(hfontsav = NtGdiSelectFont( hdc, hfont )))
{
metric->tmHeight = -1;
More information about the wine-cvs
mailing list