fix sample
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58160 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -435,7 +435,7 @@ void MyApp::CreateStyles()
|
|||||||
wxRichTextAttr indentedAttr2;
|
wxRichTextAttr indentedAttr2;
|
||||||
indentedAttr2.SetFontFaceName(romanFont.GetFaceName());
|
indentedAttr2.SetFontFaceName(romanFont.GetFaceName());
|
||||||
indentedAttr2.SetFontSize(12);
|
indentedAttr2.SetFontSize(12);
|
||||||
indentedAttr2.SetFontWeight(wxBOLD);
|
indentedAttr2.SetFontWeight(wxFONTWEIGHT_BOLD);
|
||||||
indentedAttr2.SetTextColour(*wxRED);
|
indentedAttr2.SetTextColour(*wxRED);
|
||||||
indentedAttr2.SetFontSize(12);
|
indentedAttr2.SetFontSize(12);
|
||||||
indentedAttr2.SetLeftIndent(100, 0);
|
indentedAttr2.SetLeftIndent(100, 0);
|
||||||
@@ -462,7 +462,7 @@ void MyApp::CreateStyles()
|
|||||||
wxRichTextAttr boldAttr;
|
wxRichTextAttr boldAttr;
|
||||||
boldAttr.SetFontFaceName(romanFont.GetFaceName());
|
boldAttr.SetFontFaceName(romanFont.GetFaceName());
|
||||||
boldAttr.SetFontSize(12);
|
boldAttr.SetFontSize(12);
|
||||||
boldAttr.SetFontWeight(wxBOLD);
|
boldAttr.SetFontWeight(wxFONTWEIGHT_BOLD);
|
||||||
// We only want to affect boldness
|
// We only want to affect boldness
|
||||||
boldAttr.SetFlags(wxTEXT_ATTR_FONT_WEIGHT);
|
boldAttr.SetFlags(wxTEXT_ATTR_FONT_WEIGHT);
|
||||||
boldDef->SetStyle(boldAttr);
|
boldDef->SetStyle(boldAttr);
|
||||||
@@ -473,7 +473,7 @@ void MyApp::CreateStyles()
|
|||||||
wxRichTextAttr italicAttr;
|
wxRichTextAttr italicAttr;
|
||||||
italicAttr.SetFontFaceName(romanFont.GetFaceName());
|
italicAttr.SetFontFaceName(romanFont.GetFaceName());
|
||||||
italicAttr.SetFontSize(12);
|
italicAttr.SetFontSize(12);
|
||||||
italicAttr.SetFontStyle(wxITALIC);
|
italicAttr.SetFontStyle(wxFONTSTYLE_ITALIC);
|
||||||
// We only want to affect italics
|
// We only want to affect italics
|
||||||
italicAttr.SetFlags(wxTEXT_ATTR_FONT_ITALIC);
|
italicAttr.SetFlags(wxTEXT_ATTR_FONT_ITALIC);
|
||||||
italicDef->SetStyle(italicAttr);
|
italicDef->SetStyle(italicAttr);
|
||||||
@@ -484,7 +484,7 @@ void MyApp::CreateStyles()
|
|||||||
wxRichTextAttr redAttr;
|
wxRichTextAttr redAttr;
|
||||||
redAttr.SetFontFaceName(romanFont.GetFaceName());
|
redAttr.SetFontFaceName(romanFont.GetFaceName());
|
||||||
redAttr.SetFontSize(12);
|
redAttr.SetFontSize(12);
|
||||||
redAttr.SetFontWeight(wxBOLD);
|
redAttr.SetFontWeight(wxFONTWEIGHT_BOLD);
|
||||||
redAttr.SetTextColour(*wxRED);
|
redAttr.SetTextColour(*wxRED);
|
||||||
// We only want to affect colour, weight and face
|
// We only want to affect colour, weight and face
|
||||||
redAttr.SetFlags(wxTEXT_ATTR_FONT_FACE|wxTEXT_ATTR_FONT_WEIGHT|wxTEXT_ATTR_TEXT_COLOUR);
|
redAttr.SetFlags(wxTEXT_ATTR_FONT_FACE|wxTEXT_ATTR_FONT_WEIGHT|wxTEXT_ATTR_TEXT_COLOUR);
|
||||||
|
Reference in New Issue
Block a user