use enumerations instead of integers for wxFont style/weight/family

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58159 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Francesco Montorsi
2009-01-16 20:46:20 +00:00
parent 634ad7722b
commit 7d76fbd5a1
7 changed files with 113 additions and 61 deletions

View File

@@ -314,11 +314,11 @@ bool wxRichTextFontPage::TransferDataFromWindow()
if (m_styleCtrl->GetSelection() != wxNOT_FOUND)
{
int style;
wxFontStyle style;
if (m_styleCtrl->GetStringSelection() == _("Italic"))
style = wxITALIC;
style = wxFONTSTYLE_ITALIC;
else
style = wxNORMAL;
style = wxFONTSTYLE_NORMAL;
attr->SetFontStyle(style);
}
@@ -327,11 +327,11 @@ bool wxRichTextFontPage::TransferDataFromWindow()
if (m_weightCtrl->GetSelection() != wxNOT_FOUND)
{
int weight;
wxFontWeight weight;
if (m_weightCtrl->GetStringSelection() == _("Bold"))
weight = wxBOLD;
weight = wxFONTWEIGHT_BOLD;
else
weight = wxNORMAL;
weight = wxFONTWEIGHT_NORMAL;
attr->SetFontWeight(weight);
}