Extending wxFont API & OSX Core Text Implementation (#877)
* Switch to pure Core Text Implementation, Start extended Font API * mac fixes * First msw implementation * Fixing paste error * fixing typo * Rearranging lines to former fallthrough order * Blind fixes for covering new abstract methods * Blind gtk implementations * Fixing according to travis .. * Removing method defined in base * formatting adaptions * Extending the schema definition for new weights * fixing typo, using wxRound, other fixes according to comments * changes according to suggestions * fixing init order, before the init of m_info was overridden by Init() * redo * redo * redo * Cleanup Removing obsolete code snippets, proper traces for font names * Moving common code Only the Get/SetNumericWeight calls should now be implemented in the native part, the ‚old‘ Get/SetWeight are common code and use the numeric counterparts. * Updating docs * commit wa missing changes.txt * Doc fixes * Full stops added
This commit is contained in:
@@ -2306,10 +2306,24 @@ wxFont wxXmlResourceHandlerImpl::GetFont(const wxString& param, wxWindow* parent
|
||||
if (hasWeight)
|
||||
{
|
||||
wxString weight = GetParamValue(wxT("weight"));
|
||||
if (weight == wxT("bold"))
|
||||
iweight = wxFONTWEIGHT_BOLD;
|
||||
if (weight == wxT("thin"))
|
||||
iweight = wxFONTWEIGHT_THIN;
|
||||
else if (weight == wxT("extralight"))
|
||||
iweight = wxFONTWEIGHT_EXTRALIGHT;
|
||||
else if (weight == wxT("light"))
|
||||
iweight = wxFONTWEIGHT_LIGHT;
|
||||
else if (weight == wxT("medium"))
|
||||
iweight = wxFONTWEIGHT_MEDIUM;
|
||||
else if (weight == wxT("semibold"))
|
||||
iweight = wxFONTWEIGHT_SEMIBOLD;
|
||||
else if (weight == wxT("bold"))
|
||||
iweight = wxFONTWEIGHT_BOLD;
|
||||
else if (weight == wxT("extrabold"))
|
||||
iweight = wxFONTWEIGHT_EXTRABOLD;
|
||||
else if (weight == wxT("heavy"))
|
||||
iweight = wxFONTWEIGHT_HEAVY;
|
||||
else if (weight == wxT("extraheavy"))
|
||||
iweight = wxFONTWEIGHT_EXTRAHEAVY;
|
||||
else if (weight != wxT("normal"))
|
||||
{
|
||||
ReportParamError
|
||||
|
Reference in New Issue
Block a user