From 1c069a8c8384bd385463e878ca3c0c97e33d08b7 Mon Sep 17 00:00:00 2001 From: zeromus Date: Wed, 5 Feb 2014 20:01:16 +0000 Subject: [PATCH] fix bugs in hexeditor font handling from last commits --- trunk/src/drivers/win/debugger.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/trunk/src/drivers/win/debugger.cpp b/trunk/src/drivers/win/debugger.cpp index 20b34b00..980ca65d 100644 --- a/trunk/src/drivers/win/debugger.cpp +++ b/trunk/src/drivers/win/debugger.cpp @@ -2325,7 +2325,9 @@ void DebugSystem::init() "Courier New"); /*font name*/ //if the user provided his own courier font, use that - AddFontResourceEx("coure.fon", FR_PRIVATE, NULL); + extern std::string BaseDirectory; + std::string courefon_path = BaseDirectory + "\\coure.fon"; + AddFontResourceEx(courefon_path.c_str(), FR_PRIVATE, NULL); char* hexfn = hexeditorFontName; if(!hexfn) hexfn = "Courier"; @@ -2335,7 +2337,7 @@ void DebugSystem::init() FW_REGULAR,FALSE,FALSE,FALSE, /*weight, italic, underline, strikeout*/ ANSI_CHARSET,OUT_DEVICE_PRECIS,CLIP_MASK, /*charset, precision, clipping*/ DEFAULT_QUALITY, DEFAULT_PITCH, /*quality, and pitch*/ - hexeditorFontName); /*font name*/ + hexfn); /*font name*/ HDC hdc = GetDC(GetDesktopWindow()); HGDIOBJ old = SelectObject(hdc,hFixedFont);