document GetPickerCtrl() method and provide an example of how to use it to change the default 'Browse' label for wxFilePickerCtrl
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57159 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -50,15 +50,35 @@ public:
|
|||||||
@c wxPB_USE_TEXTCTRL style was not specified when this control was created.
|
@c wxPB_USE_TEXTCTRL style was not specified when this control was created.
|
||||||
|
|
||||||
@remarks
|
@remarks
|
||||||
The contents of the text control could be containing an invalid
|
The contents of the text control could be an invalid representation of
|
||||||
representation of the entity which can be chosen through the picker
|
the entity which can be chosen through the picker
|
||||||
(e.g. the user entered an invalid colour syntax because of a typo).
|
(e.g. when the user enters an invalid colour syntax because of a typo).
|
||||||
Thus you should never parse the content of the textctrl to get the
|
Thus you should never parse the content of the textctrl to get the
|
||||||
user's input; rather use the derived-class getter
|
user's input; rather use the derived-class getter
|
||||||
(e.g. wxColourPickerCtrl::GetColour(), wxFilePickerCtrl::GetPath(), etc).
|
(e.g. wxColourPickerCtrl::GetColour(), wxFilePickerCtrl::GetPath(), etc).
|
||||||
*/
|
*/
|
||||||
wxTextCtrl* GetTextCtrl();
|
wxTextCtrl* GetTextCtrl();
|
||||||
|
|
||||||
|
/**
|
||||||
|
Returns the native implementation of the real picker control.
|
||||||
|
|
||||||
|
@note
|
||||||
|
The returned control in the generic implementation of wxFilePickerCtrl,
|
||||||
|
wxDirPickerCtrl, wxFontPickerCtrl and wxColourPickerCtrl is a specialized
|
||||||
|
wxButton class so that you can change its label doing, e.g.:
|
||||||
|
@code
|
||||||
|
#ifdef __WXMSW__
|
||||||
|
// wxMSW is one of the platforms where the generic implementation
|
||||||
|
// of wxFilePickerCtrl is used...
|
||||||
|
|
||||||
|
wxButton *pButt = wx_static_cast(wxButton*, myFilePickerCtrl->GetPickerCtrl());
|
||||||
|
if (pButt)
|
||||||
|
pButt->SetLabel("Custom browse string");
|
||||||
|
#endif
|
||||||
|
@endcode
|
||||||
|
*/
|
||||||
|
wxControl* GetPickerCtrl();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Returns the proportion value of the text control.
|
Returns the proportion value of the text control.
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user