X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d0cf495347a87ca7282a8b38e6bf1e0c606fabe2..8ca1a013e4e699724040ff1f514dab3b4a11d3c9:/src/richtext/richtextformatdlg.cpp diff --git a/src/richtext/richtextformatdlg.cpp b/src/richtext/richtextformatdlg.cpp index 93ef4bb597..e93767e702 100644 --- a/src/richtext/richtextformatdlg.cpp +++ b/src/richtext/richtextformatdlg.cpp @@ -65,9 +65,9 @@ #endif #if 0 // def __WXMAC__ -#define wxRICHTEXT_USE_TOOLBOOK true +#define wxRICHTEXT_USE_TOOLBOOK 1 #else -#define wxRICHTEXT_USE_TOOLBOOK false +#define wxRICHTEXT_USE_TOOLBOOK 0 #endif bool wxRichTextFormattingDialog::sm_showToolTips = false; @@ -346,6 +346,8 @@ bool wxRichTextFormattingDialogFactory::SetSheetStyle(wxRichTextFormattingDialog dialog->SetSheetStyle(sheetStyle); dialog->SetSheetInnerBorder(0); dialog->SetSheetOuterBorder(0); +#else + wxUnusedVar(dialog); #endif // wxRICHTEXT_USE_TOOLBOOK return true; @@ -377,8 +379,8 @@ class wxRichTextFormattingDialogModule: public wxModule DECLARE_DYNAMIC_CLASS(wxRichTextFormattingDialogModule) public: wxRichTextFormattingDialogModule() {} - bool OnInit() { wxRichTextFormattingDialog::SetFormattingDialogFactory(new wxRichTextFormattingDialogFactory); return true; }; - void OnExit() { wxRichTextFormattingDialog::SetFormattingDialogFactory(NULL); }; + bool OnInit() { wxRichTextFormattingDialog::SetFormattingDialogFactory(new wxRichTextFormattingDialogFactory); return true; } + void OnExit() { wxRichTextFormattingDialog::SetFormattingDialogFactory(NULL); } }; IMPLEMENT_DYNAMIC_CLASS(wxRichTextFormattingDialogModule, wxModule) @@ -402,7 +404,7 @@ void wxRichTextFontPreviewCtrl::OnPaint(wxPaintEvent& WXUNUSED(event)) { dc.SetFont(font); // Calculate vertical and horizontal centre - long w = 0, h = 0; + wxCoord w = 0, h = 0; wxString text(_("ABCDEFGabcdefg12345")); if (GetTextEffects() & wxTEXT_ATTR_EFFECT_CAPITALS) @@ -415,13 +417,13 @@ void wxRichTextFontPreviewCtrl::OnPaint(wxPaintEvent& WXUNUSED(event)) dc.SetTextForeground(GetForegroundColour()); dc.SetClippingRegion(2, 2, size.x-4, size.y-4); dc.DrawText(text, cx, cy); - + if (GetTextEffects() & wxTEXT_ATTR_EFFECT_STRIKETHROUGH) { dc.SetPen(wxPen(GetForegroundColour(), 1)); dc.DrawLine(cx, (int) (cy + h/2 + 0.5), cx + w, (int) (cy + h/2 + 0.5)); } - + dc.DestroyClippingRegion(); } }