- if (Style == wxDEFAULT) Style = wxNORMAL;
- M_FONTDATA->m_style = Style;
- if (Weight == wxDEFAULT) Weight = wxNORMAL;
- M_FONTDATA->m_weight = Weight;
- if (PointSize == wxDEFAULT) PointSize = 12;
- M_FONTDATA->m_pointSize = PointSize;
- M_FONTDATA->m_underlined = Underlined;
-
- if (wxTheFontList) wxTheFontList->Append( this );
-}
-
-wxFont::wxFont(int PointSize, const char *Face, int Family, int Style,
- int Weight, bool Underlined)
-{
- m_refData = new wxFontRefData();
-
- M_FONTDATA->m_fontId = wxTheFontNameDirectory->FindOrCreateFontId( Face, Family );
- M_FONTDATA->m_faceName = (Face) ? copystring(Face) : (char*)NULL;
- M_FONTDATA->m_family = wxTheFontNameDirectory->GetFamily( M_FONTDATA->m_fontId );
- M_FONTDATA->m_style = Style;
- M_FONTDATA->m_weight = Weight;
- M_FONTDATA->m_pointSize = PointSize;
- M_FONTDATA->m_underlined = Underlined;
+ if (style == wxDEFAULT) style = wxNORMAL;
+ M_FONTDATA->m_style = style;
+ if (weight == wxDEFAULT) weight = wxNORMAL;
+ M_FONTDATA->m_weight = weight;
+ if (pointSize == wxDEFAULT) pointSize = 12;
+ M_FONTDATA->m_pointSize = pointSize;
+ M_FONTDATA->m_underlined = underlined;