Alexandre Julliard : wineconsole: Set the correct font height even when no registry data is present.
Alexandre Julliard
julliard at winehq.org
Thu Oct 18 15:02:46 CDT 2018
Module: wine
Branch: master
Commit: b4516a2f1ffdeb44d32881f292c67cb0d92788ab
URL: https://source.winehq.org/git/wine.git/?a=commit;h=b4516a2f1ffdeb44d32881f292c67cb0d92788ab
Author: Alexandre Julliard <julliard at winehq.org>
Date: Thu Oct 18 21:42:52 2018 +0200
wineconsole: Set the correct font height even when no registry data is present.
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
programs/wineconsole/registry.c | 2 +-
programs/wineconsole/user.c | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/programs/wineconsole/registry.c b/programs/wineconsole/registry.c
index e892305..359034f 100644
--- a/programs/wineconsole/registry.c
+++ b/programs/wineconsole/registry.c
@@ -211,7 +211,7 @@ void WINECON_RegLoad(const WCHAR* appname, struct config_data* cfg)
cfg->cursor_visible = 1;
cfg->exit_on_die = 1;
memset(cfg->face_name, 0, sizeof(cfg->face_name));
- cfg->cell_height = MulDiv( 12, GetDpiForSystem(), USER_DEFAULT_SCREEN_DPI );
+ cfg->cell_height = MulDiv( 16, GetDpiForSystem(), USER_DEFAULT_SCREEN_DPI );
cfg->cell_width = MulDiv( 8, GetDpiForSystem(), USER_DEFAULT_SCREEN_DPI );
cfg->font_weight = FW_NORMAL;
cfg->history_size = 50;
diff --git a/programs/wineconsole/user.c b/programs/wineconsole/user.c
index a515501..28e8126 100644
--- a/programs/wineconsole/user.c
+++ b/programs/wineconsole/user.c
@@ -403,6 +403,7 @@ static int CALLBACK get_first_font_enum_2(const LOGFONTW* lf, const TEXTMETRICW*
*/
mlf.lfWidth = fc->data->curcfg.cell_width;
mlf.lfHeight = fc->data->curcfg.cell_height;
+ if (!mlf.lfHeight) mlf.lfHeight = MulDiv( 16, GetDpiForSystem(), USER_DEFAULT_SCREEN_DPI );
if (WCUSER_SetFont(fc->data, &mlf))
{
struct config_data defcfg;
More information about the wine-cvs
mailing list