]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/richtextstylesheet.tex
explain that wxRTTI macros must be used for OnCompareItems() to be called
[wxWidgets.git] / docs / latex / wx / richtextstylesheet.tex
1 \section{\class{wxRichTextStyleSheet}}\label{wxrichtextstylesheet}
2
3 A style sheet contains named paragraph and character styles that make it
4 easy for a user to apply combinations of attributes to a \helpref{wxRichTextCtrl}{wxrichtextctrl}.
5
6 You can use a \helpref{wxRichTextStyleListBox}{wxrichtextstylelistbox} in your
7 user interface to show available styles to the user, and allow application
8 of styles to the control.
9
10 \wxheading{Derived from}
11
12 \helpref{wxObject}{wxobject}
13
14 \wxheading{Include files}
15
16 <wx/richtext/richtextstyles.h>
17
18 \wxheading{Data structures}
19
20 \latexignore{\rtfignore{\wxheading{Members}}}
21
22 \membersection{wxRichTextStyleSheet::wxRichTextStyleSheet}\label{wxrichtextstylesheetwxrichtextstylesheet}
23
24 \func{}{wxRichTextStyleSheet}{\void}
25
26 Constructor.
27
28 \membersection{wxRichTextStyleSheet::\destruct{wxRichTextStyleSheet}}\label{wxrichtextstylesheetdtor}
29
30 \func{}{\destruct{wxRichTextStyleSheet}}{\void}
31
32 Destructor.
33
34 \membersection{wxRichTextStyleSheet::AddCharacterStyle}\label{wxrichtextstylesheetaddcharacterstyle}
35
36 \func{bool}{AddCharacterStyle}{\param{wxRichTextCharacterStyleDefinition* }{def}}
37
38 Adds a definition to the character style list.
39
40 \membersection{wxRichTextStyleSheet::AddListStyle}\label{wxrichtextstylesheetaddliststyle}
41
42 \func{bool}{AddListStyle}{\param{wxRichTextListStyleDefinition* }{def}}
43
44 Adds a definition to the list style list.
45
46 \membersection{wxRichTextStyleSheet::AddParagraphStyle}\label{wxrichtextstylesheetaddparagraphstyle}
47
48 \func{bool}{AddParagraphStyle}{\param{wxRichTextParagraphStyleDefinition* }{def}}
49
50 Adds a definition to the paragraph style list.
51
52 \membersection{wxRichTextStyleSheet::DeleteStyles}\label{wxrichtextstylesheetdeletestyles}
53
54 \func{void}{DeleteStyles}{\void}
55
56 Deletes all styles.
57
58 \membersection{wxRichTextStyleSheet::FindCharacterStyle}\label{wxrichtextstylesheetfindcharacterstyle}
59
60 \constfunc{wxRichTextCharacterStyleDefinition*}{FindCharacterStyle}{\param{const wxString\& }{name}}
61
62 Finds a character definition by name.
63
64 \membersection{wxRichTextStyleSheet::FindListStyle}\label{wxrichtextstylesheetfindliststyle}
65
66 \constfunc{wxRichTextListStyleDefinition*}{FindListStyle}{\param{const wxString\& }{name}}
67
68 Finds a list definition by name.
69
70 \membersection{wxRichTextStyleSheet::FindParagraphStyle}\label{wxrichtextstylesheetfindparagraphstyle}
71
72 \constfunc{wxRichTextParagraphStyleDefinition*}{FindParagraphStyle}{\param{const wxString\& }{name}}
73
74 Finds a paragraph definition by name.
75
76 \membersection{wxRichTextStyleSheet::GetCharacterStyle}\label{wxrichtextstylesheetgetcharacterstyle}
77
78 \constfunc{wxRichTextCharacterStyleDefinition*}{GetCharacterStyle}{\param{size\_t }{n}}
79
80 Returns the {\it n}th character style.
81
82 \membersection{wxRichTextStyleSheet::GetCharacterStyleCount}\label{wxrichtextstylesheetgetcharacterstylecount}
83
84 \constfunc{size\_t}{GetCharacterStyleCount}{\void}
85
86 Returns the number of character styles.
87
88 \membersection{wxRichTextStyleSheet::GetListStyle}\label{wxrichtextstylesheetgetliststyle}
89
90 \constfunc{wxRichTextListStyleDefinition*}{GetListStyle}{\param{size\_t }{n}}
91
92 Returns the {\it n}th list style.
93
94 \membersection{wxRichTextStyleSheet::GetListStyleCount}\label{wxrichtextstylesheetgetliststylecount}
95
96 \constfunc{size\_t}{GetListStyleCount}{\void}
97
98 Returns the number of list styles.
99
100 \membersection{wxRichTextStyleSheet::GetParagraphStyle}\label{wxrichtextstylesheetgetparagraphstyle}
101
102 \constfunc{wxRichTextParagraphStyleDefinition*}{GetParagraphStyle}{\param{size\_t }{n}}
103
104 Returns the {\it n}th paragraph style.
105
106 \membersection{wxRichTextStyleSheet::GetParagraphStyleCount}\label{wxrichtextstylesheetgetparagraphstylecount}
107
108 \constfunc{size\_t}{GetParagraphStyleCount}{\void}
109
110 Returns the number of paragraph styles.
111
112 \membersection{wxRichTextStyleSheet::Init}\label{wxrichtextstylesheetinit}
113
114 \func{void}{Init}{\void}
115
116 Initialises the style sheet.
117
118 \membersection{wxRichTextStyleSheet::RemoveCharacterStyle}\label{wxrichtextstylesheetremovecharacterstyle}
119
120 \func{bool}{RemoveCharacterStyle}{\param{wxRichTextStyleDefinition* }{def}, \param{bool }{deleteStyle = false}}
121
122 Removes a character style.
123
124 \membersection{wxRichTextStyleSheet::RemoveListStyle}\label{wxrichtextstylesheetremoveliststyle}
125
126 \func{bool}{RemoveListStyle}{\param{wxRichTextStyleDefinition* }{def}, \param{bool }{deleteStyle = false}}
127
128 Removes a list style.
129
130 \membersection{wxRichTextStyleSheet::RemoveParagraphStyle}\label{wxrichtextstylesheetremoveparagraphstyle}
131
132 \func{bool}{RemoveParagraphStyle}{\param{wxRichTextStyleDefinition* }{def}, \param{bool }{deleteStyle = false}}
133
134 Removes a paragraph style.
135