X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ae3c17b4013e80b99976c750c19fca47729517f6..e4821c39c43133f7b48588a51d96cfdfeff79f6f:/interface/wx/richtext/richtextstyles.h diff --git a/interface/wx/richtext/richtextstyles.h b/interface/wx/richtext/richtextstyles.h index a054d938cc..23cba9b4a7 100644 --- a/interface/wx/richtext/richtextstyles.h +++ b/interface/wx/richtext/richtextstyles.h @@ -8,21 +8,22 @@ /** @class wxRichTextStyleListCtrl - @headerfile richtextstyles.h wx/richtext/richtextstyles.h - This class incorporates a wxRichTextStyleListBox and - a choice control that allows the user to select the category of style to view. + This class incorporates a wxRichTextStyleListBox and a choice control that + allows the user to select the category of style to view. + It is demonstrated in the wxRichTextCtrl sample in @c samples/richtext. To use wxRichTextStyleListCtrl, add the control to your window hierarchy and - call wxRichTextStyleListCtrl::SetStyleType with - one of wxRichTextStyleListBox::wxRICHTEXT_STYLE_ALL, + call wxRichTextStyleListCtrl::SetStyleType with one of + wxRichTextStyleListBox::wxRICHTEXT_STYLE_ALL, wxRichTextStyleListBox::wxRICHTEXT_STYLE_PARAGRAPH, wxRichTextStyleListBox::wxRICHTEXT_STYLE_CHARACTER and wxRichTextStyleListBox::wxRICHTEXT_STYLE_LIST to set the current view. + Associate the control with a style sheet and rich text control with - SetStyleSheet and SetRichTextCtrl, - so that when a style is double-clicked, it is applied to the selection. + SetStyleSheet and SetRichTextCtrl, so that when a style is double-clicked, + it is applied to the selection. @beginStyleTable @style{wxRICHTEXTSTYLELIST_HIDE_TYPE_SELECTOR} @@ -30,7 +31,7 @@ @endStyleTable @library{wxrichtext} - @category{FIXME} + @category{richtext} */ class wxRichTextStyleListCtrl : public wxControl { @@ -91,10 +92,13 @@ public: void SetStyleSheet(wxRichTextStyleSheet* styleSheet); /** - Sets the style type to display. One of - wxRichTextStyleListBox::wxRICHTEXT_STYLE_ALL, wxRichTextStyleListBox::wxRICHTEXT_STYLE_PARAGRAPH, - wxRichTextStyleListBox::wxRICHTEXT_STYLE_CHARACTER and - wxRichTextStyleListBox::wxRICHTEXT_STYLE_LIST. + Sets the style type to display. + + One of + - wxRichTextStyleListBox::wxRICHTEXT_STYLE_ALL, + - wxRichTextStyleListBox::wxRICHTEXT_STYLE_PARAGRAPH, + - wxRichTextStyleListBox::wxRICHTEXT_STYLE_CHARACTER + - wxRichTextStyleListBox::wxRICHTEXT_STYLE_LIST. */ void SetStyleType(wxRichTextStyleListBox::wxRichTextStyleType styleType); @@ -108,12 +112,11 @@ public: /** @class wxRichTextStyleDefinition - @headerfile richtextstyles.h wx/richtext/richtextstyles.h This is a base class for paragraph and character styles. @library{wxrichtext} - @category{FIXME} + @category{richtext} */ class wxRichTextStyleDefinition : public wxObject { @@ -126,7 +129,7 @@ public: /** Destructor. */ - ~wxRichTextStyleDefinition(); + virtual ~wxRichTextStyleDefinition(); /** Returns the style on which this style is based. @@ -182,7 +185,6 @@ public: /** @class wxRichTextParagraphStyleDefinition - @headerfile richtextstyles.h wx/richtext/richtextstyles.h This class represents a paragraph style definition, usually added to a wxRichTextStyleSheet. @@ -201,7 +203,7 @@ public: /** Destructor. */ - ~wxRichTextParagraphStyleDefinition(); + virtual ~wxRichTextParagraphStyleDefinition(); /** Returns the style that should normally follow this style. @@ -218,7 +220,6 @@ public: /** @class wxRichTextStyleListBox - @headerfile richtextstyles.h wx/richtext/richtextstyles.h This is a listbox that can display the styles in a wxRichTextStyleSheet, and apply the selection to an associated wxRichTextCtrl. @@ -228,8 +229,7 @@ public: @library{wxrichtext} @category{richtext} - @see wxRichTextStyleComboCtrl, @ref overview_wxrichtextctrloverview - "wxRichTextCtrl overview" + @see wxRichTextStyleComboCtrl, @ref overview_richtextctrl */ class wxRichTextStyleListBox : public wxHtmlListBox { @@ -246,7 +246,7 @@ public: /** Destructor. */ - ~wxRichTextStyleListBox(); + virtual ~wxRichTextStyleListBox(); /** Applies the @e ith style to the associated rich text control. @@ -265,8 +265,7 @@ public: /** If the return value is @true, clicking on a style name in the list will - immediately - apply the style to the associated rich text control. + immediately apply the style to the associated rich text control. */ bool GetApplyOnSelection() const; @@ -293,7 +292,7 @@ public: /** Returns the HTML for this item. */ - wxString OnGetItem(size_t n) const; + virtual wxString OnGetItem(size_t n) const; /** Implements left click behaviour, applying the clicked style to the @@ -308,8 +307,7 @@ public: /** If @a applyOnSelection is @true, clicking on a style name in the list will - immediately - apply the style to the associated rich text control. + immediately apply the style to the associated rich text control. */ void SetApplyOnSelection(bool applyOnSelection); @@ -325,9 +323,10 @@ public: /** Sets the style type to display. One of - wxRichTextStyleListBox::wxRICHTEXT_STYLE_ALL, wxRichTextStyleListBox::wxRICHTEXT_STYLE_PARAGRAPH, - wxRichTextStyleListBox::wxRICHTEXT_STYLE_CHARACTER and - wxRichTextStyleListBox::wxRICHTEXT_STYLE_LIST. + - wxRichTextStyleListBox::wxRICHTEXT_STYLE_ALL, + - wxRichTextStyleListBox::wxRICHTEXT_STYLE_PARAGRAPH, + - wxRichTextStyleListBox::wxRICHTEXT_STYLE_CHARACTER + - wxRichTextStyleListBox::wxRICHTEXT_STYLE_LIST. */ void SetStyleType(wxRichTextStyleListBox::wxRichTextStyleType styleType); @@ -341,7 +340,6 @@ public: /** @class wxRichTextStyleComboCtrl - @headerfile richtextstyles.h wx/richtext/richtextstyles.h This is a combo control that can display the styles in a wxRichTextStyleSheet, and apply the selection to an associated wxRichTextCtrl. @@ -351,8 +349,7 @@ public: @library{wxrichtext} @category{richtext} - @see wxRichTextStyleListBox, @ref overview_wxrichtextctrloverview - "wxRichTextCtrl overview" + @see wxRichTextStyleListBox, @ref overview_richtextctrl */ class wxRichTextStyleComboCtrl : public wxComboCtrl { @@ -369,7 +366,7 @@ public: /** Destructor. */ - ~wxRichTextStyleComboCtrl(); + virtual ~wxRichTextStyleComboCtrl(); /** Returns the wxRichTextCtrl associated with this control. @@ -401,7 +398,6 @@ public: /** @class wxRichTextCharacterStyleDefinition - @headerfile richtextstyles.h wx/richtext/richtextstyles.h This class represents a character style definition, usually added to a wxRichTextStyleSheet. @@ -420,30 +416,27 @@ public: /** Destructor. */ - ~wxRichTextCharacterStyleDefinition(); + virtual ~wxRichTextCharacterStyleDefinition(); }; /** @class wxRichTextListStyleDefinition - @headerfile richtextstyles.h wx/richtext/richtextstyles.h This class represents a list style definition, usually added to a wxRichTextStyleSheet. - The class inherits paragraph attributes from - wxRichTextStyleParagraphDefinition, and adds 10 further attribute objects, one for each level of a list. + The class inherits paragraph attributes from wxRichTextStyleParagraphDefinition, + and adds 10 further attribute objects, one for each level of a list. When applying a list style to a paragraph, the list style's base and - appropriate level attributes are merged with the - paragraph's existing attributes. - - You can apply a list style to one or more paragraphs using - wxRichTextCtrl::SetListStyle. You - can also use the functions wxRichTextCtrl::NumberList, - wxRichTextCtrl::PromoteList and - wxRichTextCtrl::ClearListStyle. As usual, there are wxRichTextBuffer versions - of these functions + appropriate level attributes are merged with the paragraph's existing attributes. + + You can apply a list style to one or more paragraphs using wxRichTextCtrl::SetListStyle. + You can also use the functions wxRichTextCtrl::NumberList, wxRichTextCtrl::PromoteList and + wxRichTextCtrl::ClearListStyle. + + As usual, there are wxRichTextBuffer versions of these functions so that you can apply them directly to a buffer without requiring a control. @library{wxrichtext} @@ -460,11 +453,12 @@ public: /** Destructor. */ - ~wxRichTextListStyleDefinition(); + virtual ~wxRichTextListStyleDefinition(); /** This function combines the given paragraph style with the list style's base attributes and level style matching the given indent, returning the combined attributes. + If @a styleSheet is specified, the base style for this definition will also be included in the result. */ @@ -481,6 +475,7 @@ public: /** This function combines the list style's base attributes and the level style matching the given indent, returning the combined attributes. + If @a styleSheet is specified, the base style for this definition will also be included in the result. */ @@ -490,6 +485,7 @@ public: /** This function combines the list style's base attributes and the style for the specified level, returning the combined attributes. + If @a styleSheet is specified, the base style for this definition will also be included in the result. */ @@ -530,14 +526,12 @@ public: /** @class wxRichTextStyleSheet - @headerfile richtextstyles.h wx/richtext/richtextstyles.h A style sheet contains named paragraph and character styles that make it easy for a user to apply combinations of attributes to a wxRichTextCtrl. - You can use a wxRichTextStyleListBox in your - user interface to show available styles to the user, and allow application - of styles to the control. + You can use a wxRichTextStyleListBox in your user interface to show available + styles to the user, and allow application of styles to the control. @library{wxrichtext} @category{richtext} @@ -553,7 +547,7 @@ public: /** Destructor. */ - ~wxRichTextStyleSheet(); + virtual ~wxRichTextStyleSheet(); /** Adds a definition to the character style list.