1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2 %% Name: pickerbase.tex
3 %% Purpose: wxPickerBase documentation
4 %% Author: Francesco Montorsi
7 %% Copyright: (c) 2006 Francesco Montorsi
8 %% License: wxWindows license
9 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
11 \section{\class{wxPickerBase
}}\label{wxpickerbase
}
13 Base abstract class for all pickers which support an auxiliary text control.
14 This class handles all positioning and sizing of the text control like a
15 an horizontal
\helpref{wxBoxSizer
}{wxboxsizer
} would do, with the text control on
16 the left of the picker button and the proportion of the picker fixed to value
1.
18 \wxheading{Derived from
}
20 \helpref{wxControl
}{wxcontrol
}\\
21 \helpref{wxWindow
}{wxwindow
}\\
22 \helpref{wxEvtHandler
}{wxevthandler
}\\
23 \helpref{wxObject
}{wxobject
}
25 \wxheading{Include files
}
29 \wxheading{Window styles
}
32 \begin{twocollist
}\itemsep=
0pt
33 \twocolitem{\windowstyle{wxPB
\_USE\_TEXTCTRL}}{Creates a text control to the left of the
34 picker which is completely managed by this
\helpref{wxPickerBase
}{wxpickerbase
}
40 \helpref{wxColourPickerCtrl
}{wxcolourpickerctrl
}
43 \latexignore{\rtfignore{\wxheading{Members
}}}
45 \membersection{wxPickerBase::SetInternalMargin
}\label{wxpickerbasesetinternalmargin
}
47 \func{void
}{SetInternalMargin
}{\param{int
}{margin
}}
49 Sets the margin (in pixel) between the picker and the text control.
50 This function can be used only when
\helpref{HasTextCtrl
}{wxpickerbasehastextctrl
} returns
\true.
53 \membersection{wxPickerBase::GetInternalMargin
}\label{wxpickerbasegetinternalmargin
}
55 \constfunc{int
}{GetInternalMargin
}{}
57 Returns the margin (in pixel) between the picker and the text control.
58 This function can be used only when
\helpref{HasTextCtrl
}{wxpickerbasehastextctrl
} returns
\true.
61 \membersection{wxPickerBase::SetTextCtrlProportion
}\label{wxpickerbasesettextctrlproportion
}
63 \func{void
}{SetTextCtrlProportion
}{\param{int
}{prop
}}
65 Sets the proportion between the text control and the picker.
66 Look at the overview of wxPickerBase for more details about this.
67 This function can be used only when
\helpref{HasTextCtrl
}{wxpickerbasehastextctrl
} returns
\true.
70 \membersection{wxPickerBase::GetTextCtrlProportion
}\label{wxpickerbasegettextctrlproportion
}
72 \constfunc{int
}{GetTextCtrlProportion
}{}
74 Returns the proportion between the text control and the picker.
75 This function can be used only when
\helpref{HasTextCtrl
}{wxpickerbasehastextctrl
} returns
\true.
79 \membersection{wxPickerBase::HasTextCtrl
}\label{wxpickerbasehastextctrl
}
81 \constfunc{bool
}{HasTextCtrl
}{}
83 Returns true if this window has a valid text control (i.e. if the
\windowstyle{wxPB
\_USE\_TEXTCTRL} style was
84 given when creating this control).
87 \membersection{wxPickerBase::GetTextCtrl
}\label{wxpickerbasegetextctrl
}
89 \func{wxTextCtrl *
}{GetTextCtrl
}{}
91 Returns a pointer to the text control handled by this window or
\texttt{NULL
} if the
\windowstyle{wxPB
\_USE\_TEXTCTRL} style was not specified when this control was created.
92 Very important: the contents of the text control could be containing an invalid representation of the entity which can be chosen through the picker (e.g. the user entered an invalid colour syntax because of a typo). Thus you should never parse the content of the textctrl to get the user's input; rather use the derived-class getter (e.g.
\helpref{wxColourPickerCtrl::GetColour
}{wxcolourpickerctrlgetcolour
},
\helpref{wxFilePickerCtrl::GetPath
}{wxfilepickerctrlgetpath
}, etc).
95 \membersection{wxPickerBase::IsTextCtrlGrowable
}\label{wxpickerbaseistextctrlgrowable
}
97 \constfunc{bool
}{IsTextCtrlGrowable
}{}
99 Returns
\true if the text control is growable.
100 This function can be used only when
\helpref{HasTextCtrl
}{wxpickerbasehastextctrl
} returns
\true.
103 \membersection{wxPickerBase::SetTextCtrlGrowable
}\label{wxpickerbasesettextctrlgrowable
}
105 \func{void
}{SetTextCtrlGrowable
}{\param{bool
}{ grow = true
}}
107 Sets the text control as growable when
{\tt grow
} is
\true.
108 This function can be used only when
\helpref{HasTextCtrl
}{wxpickerbasehastextctrl
} returns
\true.
112 \membersection{wxPickerBase::IsPickerCtrlGrowable
}\label{wxpickerbaseispickerctrlgrowable
}
114 \constfunc{bool
}{IsPickerCtrlGrowable
}{}
116 Returns
\true if the picker control is growable.
119 \membersection{wxPickerBase::SetPickerCtrlGrowable
}\label{wxpickerbasesetpickerctrlgrowable
}
121 \func{void
}{SetPickerCtrlGrowable
}{\param{bool
}{ grow = true
}}
123 Sets the picker control as growable when
{\tt grow
} is
\true.
124 This function has effects only when
\helpref{HasTextCtrl
}{wxpickerbasehastextctrl
} returns
\true.