/////////////////////////////////////////////////////////////////////////////
// Name: richtext/richtextstyles.h
-// Purpose: documentation for wxRichTextStyleListCtrl class
+// Purpose: interface of wxRichTextStyleListCtrl
// Author: wxWidgets team
// RCS-ID: $Id$
// Licence: wxWindows license
so that when a style is double-clicked, it is applied to the selection.
@beginStyleTable
- @style{wxRICHTEXTSTYLELIST_HIDE_TYPE_SELECTOR}:
+ @style{wxRICHTEXTSTYLELIST_HIDE_TYPE_SELECTOR}
This style hides the category selection control.
@endStyleTable
/**
Returns the associated rich text control, if any.
*/
- wxRichTextCtrl* GetRichTextCtrl();
+ wxRichTextCtrl* GetRichTextCtrl() const;
/**
Returns the wxChoice control used for selecting the style category.
*/
- wxChoice* GetStyleChoice();
+ wxChoice* GetStyleChoice() const;
/**
Returns the wxListBox control used to view the style list.
*/
- wxRichTextStyleListBox* GetStyleListBox();
+ wxRichTextStyleListBox* GetStyleListBox() const;
/**
Returns the associated style sheet, if any.
*/
- wxRichTextStyleSheet* GetStyleSheet();
+ wxRichTextStyleSheet* GetStyleSheet() const;
/**
Returns the type of style to show in the list box.
*/
- wxRichTextStyleListBox::wxRichTextStyleType GetStyleType();
+ wxRichTextStyleListBox::wxRichTextStyleType GetStyleType() const;
/**
Associates the control with a wxRichTextCtrl.
};
+
/**
@class wxRichTextStyleDefinition
@headerfile richtextstyles.h wx/richtext/richtextstyles.h
/**
Returns the style on which this style is based.
*/
- const wxString GetBaseStyle();
+ const wxString GetBaseStyle() const;
/**
Returns the style's description.
*/
- const wxString GetDescription();
+ const wxString GetDescription() const;
/**
Returns the style name.
*/
- const wxString GetName();
+ const wxString GetName() const;
//@{
/**
Returns the attributes associated with this style.
*/
- wxTextAttr GetStyle();
- const wxTextAttr GetStyle();
+ wxTextAttr GetStyle() const;
+ const wxTextAttr GetStyle() const;
//@}
/**
Returns the style attributes combined with the attributes of the specified base
style, if any. This function works recursively.
*/
- wxTextAttr GetStyleMergedWithBase(wxRichTextStyleSheet* sheet);
+ wxTextAttr GetStyleMergedWithBase(wxRichTextStyleSheet* sheet) const;
/**
Sets the name of the style that this style is based on.
};
+
/**
@class wxRichTextParagraphStyleDefinition
@headerfile richtextstyles.h wx/richtext/richtextstyles.h
wxRichTextStyleSheet.
@library{wxrichtext}
- @category{FIXME}
+ @category{richtext}
*/
class wxRichTextParagraphStyleDefinition : public wxRichTextStyleDefinition
{
/**
Returns the style that should normally follow this style.
*/
- const wxString GetNextStyle();
+ const wxString GetNextStyle() const;
/**
Sets the style that should normally follow this style.
};
+
/**
@class wxRichTextStyleListBox
@headerfile richtextstyles.h wx/richtext/richtextstyles.h
See @c samples/richtext for an example of how to use it.
@library{wxrichtext}
- @category{FIXME}
+ @category{richtext}
- @seealso
- wxRichTextStyleComboCtrl, @ref overview_wxrichtextctrloverview "wxRichTextCtrl
- overview"
+ @see wxRichTextStyleComboCtrl, @ref overview_wxrichtextctrloverview
+ "wxRichTextCtrl overview"
*/
class wxRichTextStyleListBox : public wxHtmlListBox
{
/**
Converts units in tenths of a millimetre to device units.
*/
- int ConvertTenthsMMToPixels(wxDC& dc, int units);
+ int ConvertTenthsMMToPixels(wxDC& dc, int units) const;
/**
Creates a suitable HTML fragment for a definition.
*/
- wxString CreateHTML(wxRichTextStyleDefinition* def);
+ wxString CreateHTML(wxRichTextStyleDefinition* def) const;
/**
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.
*/
- bool GetApplyOnSelection();
+ bool GetApplyOnSelection() const;
/**
Returns the wxRichTextCtrl associated with this listbox.
*/
- wxRichTextCtrl* GetRichTextCtrl();
+ wxRichTextCtrl* GetRichTextCtrl() const;
/**
Gets a style for a listbox index.
*/
- wxRichTextStyleDefinition* GetStyle(size_t i);
+ wxRichTextStyleDefinition* GetStyle(size_t i) const;
/**
Returns the style sheet associated with this listbox.
*/
- wxRichTextStyleSheet* GetStyleSheet();
+ wxRichTextStyleSheet* GetStyleSheet() const;
/**
Returns the type of style to show in the list box.
*/
- wxRichTextStyleListBox::wxRichTextStyleType GetStyleType();
+ wxRichTextStyleListBox::wxRichTextStyleType GetStyleType() const;
/**
Returns the HTML for this item.
*/
- wxString OnGetItem(size_t n);
+ wxString OnGetItem(size_t n) const;
/**
Implements left click behaviour, applying the clicked style to the
void OnSelect(wxCommandEvent& event);
/**
- If @e applyOnSelection is @true, clicking on a style name in the list will
+ If @a applyOnSelection is @true, clicking on a style name in the list will
immediately
apply the style to the associated rich text control.
*/
};
+
/**
@class wxRichTextStyleComboCtrl
@headerfile richtextstyles.h wx/richtext/richtextstyles.h
See @c samples/richtext for an example of how to use it.
@library{wxrichtext}
- @category{FIXME}
+ @category{richtext}
- @seealso
- wxRichTextStyleListBox, @ref overview_wxrichtextctrloverview "wxRichTextCtrl
- overview"
+ @see wxRichTextStyleListBox, @ref overview_wxrichtextctrloverview
+ "wxRichTextCtrl overview"
*/
class wxRichTextStyleComboCtrl : public wxComboCtrl
{
/**
Returns the wxRichTextCtrl associated with this control.
*/
- wxRichTextCtrl* GetRichTextCtrl();
+ wxRichTextCtrl* GetRichTextCtrl() const;
/**
Returns the style sheet associated with this control.
*/
- wxRichTextStyleSheet* GetStyleSheet();
+ wxRichTextStyleSheet* GetStyleSheet() const;
/**
Associates the control with a wxRichTextCtrl.
};
+
/**
@class wxRichTextCharacterStyleDefinition
@headerfile richtextstyles.h wx/richtext/richtextstyles.h
wxRichTextStyleSheet.
@library{wxrichtext}
- @category{FIXME}
+ @category{richtext}
*/
class wxRichTextCharacterStyleDefinition : public wxRichTextStyleDefinition
{
};
+
/**
@class wxRichTextListStyleDefinition
@headerfile richtextstyles.h wx/richtext/richtextstyles.h
so that you can apply them directly to a buffer without requiring a control.
@library{wxrichtext}
- @category{FIXME}
+ @category{richtext}
*/
class wxRichTextListStyleDefinition : public wxRichTextParagraphStyleDefinition
{
/**
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 @e styleSheet is specified, the base style for this definition will also be
+ If @a styleSheet is specified, the base style for this definition will also be
included in the result.
*/
wxTextAttr CombineWithParagraphStyle(int indent,
const wxTextAttr& paraStyle,
- wxRichTextStyleSheet* styleSheet = @NULL);
+ wxRichTextStyleSheet* styleSheet = NULL);
/**
This function finds the level (from 0 to 9) whose indentation attribute mostly
- closely matches @e indent (expressed in tenths of a millimetre).
+ closely matches @a indent (expressed in tenths of a millimetre).
*/
- int FindLevelForIndent(int indent);
+ int FindLevelForIndent(int indent) const;
/**
This function combines the list style's base attributes and the level style
matching the given indent, returning the combined attributes.
- If @e styleSheet is specified, the base style for this definition will also be
+ If @a styleSheet is specified, the base style for this definition will also be
included in the result.
*/
wxTextAttr GetCombinedStyle(int indent,
- wxRichTextStyleSheet* styleSheet = @NULL);
+ wxRichTextStyleSheet* styleSheet = NULL) const;
/**
This function combines the list style's base attributes and the style for the
specified level, returning the combined attributes.
- If @e styleSheet is specified, the base style for this definition will also be
+ If @a styleSheet is specified, the base style for this definition will also be
included in the result.
*/
wxTextAttr GetCombinedStyleLevel(int level,
- wxRichTextStyleSheet* styleSheet = @NULL);
+ wxRichTextStyleSheet* styleSheet = NULL) const;
/**
- Returns the style for the given level. @e level is a number between 0 and 9.
+ Returns the style for the given level. @a level is a number between 0 and 9.
*/
- const wxTextAttr* GetLevelAttributes(int level);
+ const wxTextAttr* GetLevelAttributes(int level) const;
/**
Returns the number of levels. This is hard-wired to 10.
-
Returns the style for the given level. @e level is a number between 0 and 9.
*/
- int GetLevelCount();
+ int GetLevelCount() const;
/**
Returns @true if the given level has numbered list attributes.
*/
- int IsNumbered(int level);
+ int IsNumbered(int level) const;
//@{
/**
- Sets the style for the given level. @e level is a number between 0 and 9.
-
+ Sets the style for the given level. @a level is a number between 0 and 9.
The first and most flexible form uses a wxTextAttr object, while the second
form is for convenient setting of the most commonly-used attributes.
*/
};
+
/**
@class wxRichTextStyleSheet
@headerfile richtextstyles.h wx/richtext/richtextstyles.h
of styles to the control.
@library{wxrichtext}
- @category{FIXME}
+ @category{richtext}
*/
class wxRichTextStyleSheet : public wxObject
{
/**
Finds a character definition by name.
*/
- wxRichTextCharacterStyleDefinition* FindCharacterStyle(const wxString& name);
+ wxRichTextCharacterStyleDefinition* FindCharacterStyle(const wxString& name) const;
/**
Finds a list definition by name.
*/
- wxRichTextListStyleDefinition* FindListStyle(const wxString& name);
+ wxRichTextListStyleDefinition* FindListStyle(const wxString& name) const;
/**
Finds a paragraph definition by name.
*/
- wxRichTextParagraphStyleDefinition* FindParagraphStyle(const wxString& name);
+ wxRichTextParagraphStyleDefinition* FindParagraphStyle(const wxString& name) const;
/**
Finds a style definition by name.
*/
- wxRichTextStyleDefinition* FindStyle(const wxString& name);
+ wxRichTextStyleDefinition* FindStyle(const wxString& name) const;
/**
Returns the @e nth character style.
*/
- wxRichTextCharacterStyleDefinition* GetCharacterStyle(size_t n);
+ wxRichTextCharacterStyleDefinition* GetCharacterStyle(size_t n) const;
/**
Returns the number of character styles.
*/
- size_t GetCharacterStyleCount();
+ size_t GetCharacterStyleCount() const;
/**
Returns the style sheet's description.
*/
- const wxString GetDescription();
+ const wxString GetDescription() const;
/**
Returns the @e nth list style.
*/
- wxRichTextListStyleDefinition* GetListStyle(size_t n);
+ wxRichTextListStyleDefinition* GetListStyle(size_t n) const;
/**
Returns the number of list styles.
*/
- size_t GetListStyleCount();
+ size_t GetListStyleCount() const;
/**
Returns the style sheet's name.
*/
- const wxString GetName();
+ const wxString GetName() const;
/**
Returns the @e nth paragraph style.
*/
- wxRichTextParagraphStyleDefinition* GetParagraphStyle(size_t n);
+ wxRichTextParagraphStyleDefinition* GetParagraphStyle(size_t n) const;
/**
Returns the number of paragraph styles.
*/
- size_t GetParagraphStyleCount();
+ size_t GetParagraphStyleCount() const;
/**
Removes a character style.
*/
bool RemoveCharacterStyle(wxRichTextStyleDefinition* def,
- bool deleteStyle = @false);
+ bool deleteStyle = false);
/**
Removes a list style.
*/
bool RemoveListStyle(wxRichTextStyleDefinition* def,
- bool deleteStyle = @false);
+ bool deleteStyle = false);
/**
Removes a paragraph style.
*/
bool RemoveParagraphStyle(wxRichTextStyleDefinition* def,
- bool deleteStyle = @false);
+ bool deleteStyle = false);
/**
Removes a style.
*/
bool RemoveStyle(wxRichTextStyleDefinition* def,
- bool deleteStyle = @false);
+ bool deleteStyle = false);
/**
Sets the style sheet's description.
*/
void SetName(const wxString& name);
};
+