Add wxFontDialog::RestrictSelection() to disallow raster fonts
Under MSW it is possible to restrict the native font dialog to showing only scalable fonts only, disallowing the raster fonts, so add a method to wxFontDialog exposing this functionality in wxWidgets API. Closes https://github.com/wxWidgets/wxWidgets/pull/1926 Closes #16988.
This commit is contained in:
committed by
Vadim Zeitlin
parent
b35ef94a72
commit
76c7f723fc
@@ -26,6 +26,7 @@ wxFontData::wxFontData()
|
||||
m_maxSize = 0;
|
||||
|
||||
m_encoding = wxFONTENCODING_SYSTEM;
|
||||
m_restrictSelection = wxFONTRESTRICT_NONE;
|
||||
}
|
||||
|
||||
wxFontData::~wxFontData()
|
||||
@@ -43,7 +44,8 @@ wxFontData::wxFontData(const wxFontData& data)
|
||||
m_minSize(data.m_minSize),
|
||||
m_maxSize(data.m_maxSize),
|
||||
m_encoding(data.m_encoding),
|
||||
m_encodingInfo(data.m_encodingInfo)
|
||||
m_encodingInfo(data.m_encodingInfo),
|
||||
m_restrictSelection(data.m_restrictSelection)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -52,16 +54,17 @@ wxFontData& wxFontData::operator=(const wxFontData& data)
|
||||
if (&data != this)
|
||||
{
|
||||
wxObject::operator=(data);
|
||||
m_fontColour = data.m_fontColour;
|
||||
m_showHelp = data.m_showHelp;
|
||||
m_allowSymbols = data.m_allowSymbols;
|
||||
m_enableEffects = data.m_enableEffects;
|
||||
m_initialFont = data.m_initialFont;
|
||||
m_chosenFont = data.m_chosenFont;
|
||||
m_minSize = data.m_minSize;
|
||||
m_maxSize = data.m_maxSize;
|
||||
m_encoding = data.m_encoding;
|
||||
m_encodingInfo = data.m_encodingInfo;
|
||||
m_fontColour = data.m_fontColour;
|
||||
m_showHelp = data.m_showHelp;
|
||||
m_allowSymbols = data.m_allowSymbols;
|
||||
m_enableEffects = data.m_enableEffects;
|
||||
m_initialFont = data.m_initialFont;
|
||||
m_chosenFont = data.m_chosenFont;
|
||||
m_minSize = data.m_minSize;
|
||||
m_maxSize = data.m_maxSize;
|
||||
m_encoding = data.m_encoding;
|
||||
m_encodingInfo = data.m_encodingInfo;
|
||||
m_restrictSelection = data.m_restrictSelection;
|
||||
}
|
||||
return *this;
|
||||
}
|
||||
|
Reference in New Issue
Block a user