diff --git a/Source/DialogTemplate.cpp b/Source/DialogTemplate.cpp index ddd883b3..aeec1547 100644 --- a/Source/DialogTemplate.cpp +++ b/Source/DialogTemplate.cpp @@ -247,11 +247,14 @@ void CDialogTemplate::RemoveItem(WORD wId) { // Sets the font of the dialog void CDialogTemplate::SetFont(char* szFaceName, WORD wFontSize) { - m_dwStyle |= DS_SETFONT; + m_dwStyle &= ~DS_SHELLFONT; + m_dwStyle &= ~DS_FIXEDSYS; + m_dwStyle |= DS_SETFONT; if (m_szFont) delete [] m_szFont; m_szFont = new char[lstrlen(szFaceName)]; lstrcpy(m_szFont, szFaceName); m_sFontSize = wFontSize; + m_bExtended = false; } // Adds an item to the dialog diff --git a/Source/DialogTemplate.h b/Source/DialogTemplate.h index 91681cb3..453fefe0 100644 --- a/Source/DialogTemplate.h +++ b/Source/DialogTemplate.h @@ -82,7 +82,7 @@ typedef struct { short cx; short cy; WORD id; - WORD _miscrosoft_docs_are_wrong; + WORD _miscrosoft_docs_are_wrong; } DLGITEMTEMPLATEEX; #pragma pack(pop) @@ -105,7 +105,7 @@ public: void RTrimToString(WORD id, char *str, int margins); void LTrimToString(WORD id, char *str, int margins); void CTrimToString(WORD id, char *str, int margins); - void ConvertToRTL(); + void ConvertToRTL(); BYTE* Save(DWORD& dwSize); DWORD GetSize(); @@ -129,7 +129,7 @@ private: short m_sFontSize; short m_sFontWeight; // Extended only BYTE m_bItalic; // Extended only - BYTE m_bCharset; // Extended only + BYTE m_bCharset; // Extended only char* m_szFont; // Items vector