]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/tipprov.tex
better documentation for wxWindow::SetSizerAndFit()
[wxWidgets.git] / docs / latex / wx / tipprov.tex
CommitLineData
c50f1fb9
VZ
1\section{\class{wxTipProvider}}\label{wxtipprovider}
2
3This is the class used together with \helpref{wxShowTip}{wxshowtip} function.
4It must implement \helpref{GetTip}{wxtipprovidergettip} function and return the
5current tip from it (different tip each time it is called).
6
7You will never use this class yourself, but you need it to show startup tips
8with wxShowTip. Also, if you want to get the tips text from elsewhere than a
9simple text file, you will want to derive a new class from wxTipProvider and
d7cb14ce 10use it instead of the one returned by \helpref{wxCreateFileTipProvider}{wxcreatefiletipprovider}.
c50f1fb9
VZ
11
12\wxheading{Derived from}
13
14None.
15
16\wxheading{Include files}
17
18<wx/tipdlg.h>
19
a7af285d
VZ
20\wxheading{Library}
21
22\helpref{wxAdv}{librarieslist}
23
c50f1fb9
VZ
24\wxheading{See also}
25
26\helpref{Startup tips overview}{tipsoverview}, \helpref{::wxShowTip}{wxshowtip}
27
28\latexignore{\rtfignore{\wxheading{Members}}}
29
30\membersection{wxTipProvider::wxTipProvider}\label{wxtipproviderctor}
31
32\func{}{wxTipProvider}{\param{size\_t }{currentTip}}
33
34Constructor.
35
36\docparam{currentTip}{The starting tip index.}
37
d7cb14ce 38\membersection{wxTipProvider::GetTip}\label{wxtipprovidergettip}
c50f1fb9
VZ
39
40\func{wxString}{GetTip}{\void}
41
42Return the text of the current tip and pass to the next one. This function is
43pure virtual, it should be implemented in the derived classes.
44
70373b5a 45\membersection{wxTipProvider::PreprocessTip}\label{wxtipproviderpreprocesstip}
0b0625e9
JS
46
47\func{virtual wxString}{PreProcessTip}{\param{const wxString\&}{tip}}
70373b5a
JS
48
49Returns a modified tip. This function will be called immediately after read,
50and before being check whether it is a comment, an empty string or a string
51to translate. You can optionally override this in your custom user-derived class
52to optionally to modify the tip as soon as it is read. You can return any
53modification to the string. If you return wxEmptyString, then this tip is
54skipped, and the next one is read.
55
d7cb14ce 56\membersection{wxCurrentTipProvider::GetCurrentTip}\label{wxtipprovidergetcurrenttip}
c50f1fb9
VZ
57
58\constfunc{size\_t}{GetCurrentTip}{\void}
59
70373b5a 60Returns the index of the current tip (i.e. the one which would be returned by
c50f1fb9
VZ
61GetTip).
62
63The program usually remembers the value returned by this function after calling
64\helpref{wxShowTip}{wxshowtip}. Note that it is not the same as the value which
65was passed to wxShowTip $+ 1$ because the user might have pressed the "Next"
66button in the tip dialog.
0b0625e9 67