]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/richtextheaderfooterdata.tex
GetBestFittingSize --> GetEffectiveMinSize
[wxWidgets.git] / docs / latex / wx / richtextheaderfooterdata.tex
1 \section{\class{wxRichTextHeaderFooterData}}\label{wxrichtextheaderfooterdata}
2
3
4 This class represents header and footer data to be passed to the \helpref{wxRichTextPrinting}{wxrichtextprinting} and
5 \helpref{wxRichTextPrintout}{wxrichtextprintout} classes.
6
7 Headers and footers can be specified independently for odd, even or both page sides. Different text can be specified
8 for left, centre and right locations on the page, and the font and text colour can also
9 be specified. You can specify the following keywords in header and footer text, which will
10 be substituted for the actual values during printing and preview.
11
12 \begin{itemize}\itemsep=0pt
13 \item @DATE@: the current date.
14 \item @PAGESCNT@: the total number of pages.
15 \item @PAGENUM@: the current page number.
16 \item @TIME@: the current time.
17 \item @TITLE@: the title of the document, as passed to the wxRichTextPrinting or wxRichTextLayout constructor.
18 \end{itemize}
19
20 \wxheading{Derived from}
21
22 \helpref{wxObject}{wxobject}
23
24 \wxheading{Include files}
25
26 <wx/richtex/richtextprint.h>
27
28 \wxheading{Data structures}
29
30 These are the header and footer page identifiers, passed to functions such as SetFooterText to specify
31 the odd or even page for the text:
32
33 \begin{verbatim}
34 enum wxRichTextOddEvenPage {
35 wxRICHTEXT_PAGE_ODD,
36 wxRICHTEXT_PAGE_EVEN,
37 wxRICHTEXT_PAGE_ALL,
38 }
39 \end{verbatim}
40
41 These are the location identifiers for passing to functions such as SetFooterText, to specify
42 whether the text is on the left, centre or right of the page:
43
44 \begin{verbatim}
45 enum wxRichTextPageLocation {
46 wxRICHTEXT_PAGE_LEFT,
47 wxRICHTEXT_PAGE_CENTRE,
48 wxRICHTEXT_PAGE_RIGHT
49 }
50 \end{verbatim}
51
52 \latexignore{\rtfignore{\wxheading{Members}}}
53
54 \membersection{wxRichTextHeaderFooterData::wxRichTextHeaderFooterData}\label{wxrichtextheaderfooterdatawxrichtextheaderfooterdata}
55
56 \func{}{wxRichTextHeaderFooterData}{\void}
57
58 \func{}{wxRichTextHeaderFooterData}{\param{const wxRichTextHeaderFooterData\& }{data}}
59
60 Constructors.
61
62 \membersection{wxRichTextHeaderFooterData::Clear}\label{wxrichtextheaderfooterdataclear}
63
64 \func{void}{Clear}{\void}
65
66 Clears all text.
67
68 \membersection{wxRichTextHeaderFooterData::Copy}\label{wxrichtextheaderfooterdatacopy}
69
70 \func{void}{Copy}{\param{const wxRichTextHeaderFooterData\& }{data}}
71
72 Copies the data.
73
74 \membersection{wxRichTextHeaderFooterData::GetFont}\label{wxrichtextheaderfooterdatagetfont}
75
76 \constfunc{const wxFont\&}{GetFont}{\void}
77
78 Returns the font specified for printing the header and footer.
79
80 \membersection{wxRichTextHeaderFooterData::GetFooterMargin}\label{wxrichtextheaderfooterdatagetfootermargin}
81
82 \constfunc{int}{GetFooterMargin}{\void}
83
84 Returns the margin between the text and the footer.
85
86 \membersection{wxRichTextHeaderFooterData::GetFooterText}\label{wxrichtextheaderfooterdatagetfootertext}
87
88 \constfunc{wxString}{GetFooterText}{\param{wxRichTextOddEvenPage }{page = wxRICHTEXT\_PAGE\_EVEN}, \param{wxRichTextPageLocation }{location = wxRICHTEXT\_PAGE\_CENTRE}}
89
90 Returns the footer text on odd or even pages, and at a given position on the page (left, centre or right).
91
92 \membersection{wxRichTextHeaderFooterData::GetHeaderMargin}\label{wxrichtextheaderfooterdatagetheadermargin}
93
94 \constfunc{int}{GetHeaderMargin}{\void}
95
96 Returns the margin between the text and the header.
97
98 \membersection{wxRichTextHeaderFooterData::GetHeaderText}\label{wxrichtextheaderfooterdatagetheadertext}
99
100 \constfunc{wxString}{GetHeaderText}{\param{wxRichTextOddEvenPage }{page = wxRICHTEXT\_PAGE\_EVEN}, \param{wxRichTextPageLocation }{location = wxRICHTEXT\_PAGE\_CENTRE}}
101
102 Returns the header text on odd or even pages, and at a given position on the page (left, centre or right).
103
104 \membersection{wxRichTextHeaderFooterData::GetShowOnFirstPage}\label{wxrichtextheaderfooterdatagetshowonfirstpage}
105
106 \constfunc{bool}{GetShowOnFirstPage}{\void}
107
108 Returns \true if the header and footer will be shown on the first page.
109
110 \membersection{wxRichTextHeaderFooterData::GetText}\label{wxrichtextheaderfooterdatagettext}
111
112 \constfunc{wxString}{GetText}{\param{int }{headerFooter}, \param{wxRichTextOddEvenPage }{page}, \param{wxRichTextPageLocation }{location}}
113
114 Helper function for getting the header or footer text, odd or even pages, and at a given position on the page (left, centre or right).
115
116 \membersection{wxRichTextHeaderFooterData::GetTextColour}\label{wxrichtextheaderfooterdatagettextcolour}
117
118 \constfunc{const wxColour\&}{GetTextColour}{\void}
119
120 Returns the text colour for drawing the header and footer.
121
122 \membersection{wxRichTextHeaderFooterData::Init}\label{wxrichtextheaderfooterdatainit}
123
124 \func{void}{Init}{\void}
125
126 Initialises the object.
127
128 \membersection{wxRichTextHeaderFooterData::SetFont}\label{wxrichtextheaderfooterdatasetfont}
129
130 \func{void}{SetFont}{\param{const wxFont\& }{font}}
131
132 Sets the font for drawing the header and footer.
133
134 \membersection{wxRichTextHeaderFooterData::SetFooterText}\label{wxrichtextheaderfooterdatasetfootertext}
135
136 \func{void}{SetFooterText}{\param{const wxString\& }{text}, \param{wxRichTextOddEvenPage }{page = wxRICHTEXT\_PAGE\_ALL}, \param{wxRichTextPageLocation }{location = wxRICHTEXT\_PAGE\_CENTRE}}
137
138 Sets the footer text on odd or even pages, and at a given position on the page (left, centre or right).
139
140 \membersection{wxRichTextHeaderFooterData::SetHeaderText}\label{wxrichtextheaderfooterdatasetheadertext}
141
142 \func{void}{SetHeaderText}{\param{const wxString\& }{text}, \param{wxRichTextOddEvenPage }{page = wxRICHTEXT\_PAGE\_ALL}, \param{wxRichTextPageLocation }{location = wxRICHTEXT\_PAGE\_CENTRE}}
143
144 Sets the header text on odd or even pages, and at a given position on the page (left, centre or right).
145
146 \membersection{wxRichTextHeaderFooterData::SetMargins}\label{wxrichtextheaderfooterdatasetmargins}
147
148 \func{void}{SetMargins}{\param{int }{headerMargin}, \param{int }{footerMargin}}
149
150 Sets the margins between text and header or footer, in tenths of a millimeter.
151
152 \membersection{wxRichTextHeaderFooterData::SetShowOnFirstPage}\label{wxrichtextheaderfooterdatasetshowonfirstpage}
153
154 \func{void}{SetShowOnFirstPage}{\param{bool }{showOnFirstPage}}
155
156 Pass \true to show the header or footer on first page (the default).
157
158 \membersection{wxRichTextHeaderFooterData::SetText}\label{wxrichtextheaderfooterdatasettext}
159
160 \func{void}{SetText}{\param{const wxString\& }{text}, \param{int }{headerFooter}, \param{wxRichTextOddEvenPage }{page}, \param{wxRichTextPageLocation }{location}}
161
162 Helper function for setting the header or footer text, odd or even pages, and at a given position on the page (left, centre or right).
163
164 \membersection{wxRichTextHeaderFooterData::SetTextColour}\label{wxrichtextheaderfooterdatasettextcolour}
165
166 \func{void}{SetTextColour}{\param{const wxColour\& }{col}}
167
168 Sets the text colour for drawing the header and footer.
169
170 \membersection{wxRichTextHeaderFooterData::operator=}\label{wxrichtextheaderfooterdataoperatorassign}
171
172 \func{void operator}{operator=}{\param{const wxRichTextHeaderFooterData\& }{data}}
173
174 Assignment operator.
175