Use the encoding in StyleSetFont too.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@33803 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
498a1eeb8d
commit
af0531a5a8
@ -2524,14 +2524,14 @@ void wxStyledTextCtrl::StyleSetFont(int styleNum, wxFont& font) {
|
|||||||
int x, y;
|
int x, y;
|
||||||
GetTextExtent(wxT("X"), &x, &y, NULL, NULL, &font);
|
GetTextExtent(wxT("X"), &x, &y, NULL, NULL, &font);
|
||||||
#endif
|
#endif
|
||||||
int size = font.GetPointSize();
|
int size = font.GetPointSize();
|
||||||
wxString faceName = font.GetFaceName();
|
wxString faceName = font.GetFaceName();
|
||||||
bool bold = font.GetWeight() == wxBOLD;
|
bool bold = font.GetWeight() == wxBOLD;
|
||||||
bool italic = font.GetStyle() != wxNORMAL;
|
bool italic = font.GetStyle() != wxNORMAL;
|
||||||
bool under = font.GetUnderlined();
|
bool under = font.GetUnderlined();
|
||||||
|
wxFontEncoding encoding = font.GetDefaultEncoding();
|
||||||
// TODO: add encoding/charset mapping
|
|
||||||
StyleSetFontAttr(styleNum, size, faceName, bold, italic, under);
|
StyleSetFontAttr(styleNum, size, faceName, bold, italic, under, encoding);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set all font style attributes at once.
|
// Set all font style attributes at once.
|
||||||
|
@ -296,14 +296,14 @@ void wxStyledTextCtrl::StyleSetFont(int styleNum, wxFont& font) {
|
|||||||
int x, y;
|
int x, y;
|
||||||
GetTextExtent(wxT("X"), &x, &y, NULL, NULL, &font);
|
GetTextExtent(wxT("X"), &x, &y, NULL, NULL, &font);
|
||||||
#endif
|
#endif
|
||||||
int size = font.GetPointSize();
|
int size = font.GetPointSize();
|
||||||
wxString faceName = font.GetFaceName();
|
wxString faceName = font.GetFaceName();
|
||||||
bool bold = font.GetWeight() == wxBOLD;
|
bool bold = font.GetWeight() == wxBOLD;
|
||||||
bool italic = font.GetStyle() != wxNORMAL;
|
bool italic = font.GetStyle() != wxNORMAL;
|
||||||
bool under = font.GetUnderlined();
|
bool under = font.GetUnderlined();
|
||||||
|
wxFontEncoding encoding = font.GetDefaultEncoding();
|
||||||
// TODO: add encoding/charset mapping
|
|
||||||
StyleSetFontAttr(styleNum, size, faceName, bold, italic, under);
|
StyleSetFontAttr(styleNum, size, faceName, bold, italic, under, encoding);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set all font style attributes at once.
|
// Set all font style attributes at once.
|
||||||
|
@ -2524,14 +2524,14 @@ void wxStyledTextCtrl::StyleSetFont(int styleNum, wxFont& font) {
|
|||||||
int x, y;
|
int x, y;
|
||||||
GetTextExtent(wxT("X"), &x, &y, NULL, NULL, &font);
|
GetTextExtent(wxT("X"), &x, &y, NULL, NULL, &font);
|
||||||
#endif
|
#endif
|
||||||
int size = font.GetPointSize();
|
int size = font.GetPointSize();
|
||||||
wxString faceName = font.GetFaceName();
|
wxString faceName = font.GetFaceName();
|
||||||
bool bold = font.GetWeight() == wxBOLD;
|
bool bold = font.GetWeight() == wxBOLD;
|
||||||
bool italic = font.GetStyle() != wxNORMAL;
|
bool italic = font.GetStyle() != wxNORMAL;
|
||||||
bool under = font.GetUnderlined();
|
bool under = font.GetUnderlined();
|
||||||
|
wxFontEncoding encoding = font.GetDefaultEncoding();
|
||||||
// TODO: add encoding/charset mapping
|
|
||||||
StyleSetFontAttr(styleNum, size, faceName, bold, italic, under);
|
StyleSetFontAttr(styleNum, size, faceName, bold, italic, under, encoding);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set all font style attributes at once.
|
// Set all font style attributes at once.
|
||||||
|
@ -296,14 +296,14 @@ void wxStyledTextCtrl::StyleSetFont(int styleNum, wxFont& font) {
|
|||||||
int x, y;
|
int x, y;
|
||||||
GetTextExtent(wxT("X"), &x, &y, NULL, NULL, &font);
|
GetTextExtent(wxT("X"), &x, &y, NULL, NULL, &font);
|
||||||
#endif
|
#endif
|
||||||
int size = font.GetPointSize();
|
int size = font.GetPointSize();
|
||||||
wxString faceName = font.GetFaceName();
|
wxString faceName = font.GetFaceName();
|
||||||
bool bold = font.GetWeight() == wxBOLD;
|
bool bold = font.GetWeight() == wxBOLD;
|
||||||
bool italic = font.GetStyle() != wxNORMAL;
|
bool italic = font.GetStyle() != wxNORMAL;
|
||||||
bool under = font.GetUnderlined();
|
bool under = font.GetUnderlined();
|
||||||
|
wxFontEncoding encoding = font.GetDefaultEncoding();
|
||||||
// TODO: add encoding/charset mapping
|
|
||||||
StyleSetFontAttr(styleNum, size, faceName, bold, italic, under);
|
StyleSetFontAttr(styleNum, size, faceName, bold, italic, under, encoding);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set all font style attributes at once.
|
// Set all font style attributes at once.
|
||||||
|
Loading…
Reference in New Issue
Block a user