⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sngchdlg.tex

📁 很牛的GUI源码wxWidgets-2.8.0.zip 可在多种平台下运行.
💻 TEX
字号:
\section{\class{wxSingleChoiceDialog}}\label{wxsinglechoicedialog}This class represents a dialog that shows a list of strings, and allows theuser to select one. Double-clicking on a list item is equivalent tosingle-clicking and then pressing OK.\wxheading{Derived from}\helpref{wxDialog}{wxdialog}\\\helpref{wxWindow}{wxwindow}\\\helpref{wxEvtHandler}{wxevthandler}\\\helpref{wxObject}{wxobject}\wxheading{Include files}<wx/choicdlg.h>\wxheading{See also}\helpref{wxSingleChoiceDialog overview}{wxsinglechoicedialogoverview},\helpref{wxMultiChoiceDialog}{wxmultichoicedialog}\latexignore{\rtfignore{\wxheading{Members}}}\membersection{wxSingleChoiceDialog::wxSingleChoiceDialog}\label{wxsinglechoicedialogctor}\func{}{wxSingleChoiceDialog}{\param{wxWindow* }{parent}, \param{const wxString\& }{message},\rtfsp\param{const wxString\& }{caption}, \param{int }{n}, \param{const wxString* }{choices},\rtfsp\param{void**}{ clientData = NULL}, \param{long }{style = wxCHOICEDLG\_STYLE},\rtfsp\param{const wxPoint\& }{pos = wxDefaultPosition}}\func{}{wxSingleChoiceDialog}{\param{wxWindow* }{parent}, \param{const wxString\& }{message},\rtfsp\param{const wxString\& }{caption}, \param{const wxArrayString\& }{choices},\rtfsp\param{void**}{ clientData = NULL}, \param{long }{style = wxCHOICEDLG\_STYLE},\rtfsp\param{const wxPoint\& }{pos = wxDefaultPosition}}Constructor, taking an array of wxString choices and optional client data.\wxheading{Parameters}\docparam{parent}{Parent window.}\docparam{message}{Message to show on the dialog.}\docparam{caption}{The dialog caption.}\docparam{n}{The number of choices.}\docparam{choices}{An array of strings, or a string list, containing the choices.}\docparam{clientData}{An array of client data to be associated with the items.See \helpref{GetSelectionClientData}{wxsinglechoicedialoggetselectionclientdata}.}\docparam{style}{A dialog style (bitlist) containing flags chosen from standarddialog styles and the following:\twocolwidtha{5cm}\begin{twocollist}\twocolitem{{\bf wxOK}}{Show an OK button.}\twocolitem{{\bf wxCANCEL}}{Show a Cancel button.}\twocolitem{{\bf wxCENTRE}}{Centre the message. Not Windows.}\end{twocollist}The default value is equivalent to {\bf wxDEFAULT\_DIALOG\_STYLE \pipe wxRESIZE\_BORDER \pipe wxOK \pipe wxCANCEL \pipe wxCENTRE}.}\docparam{pos}{Dialog position. Not Windows.}\wxheading{Remarks}Use \helpref{wxSingleChoiceDialog::ShowModal}{wxsinglechoicedialogshowmodal} to show the dialog.\pythonnote{For Python the two parameters {\tt n} and {\tt choices} are collapsedinto a single parameter {\tt choices} which is expected to be a Pythonlist of strings.}\perlnote{In wxPerl there is just an array reference in place of {\tt n}and {\tt choices}, and the client data array, if present, must have thesame length as the choices array.}\membersection{wxSingleChoiceDialog::GetSelection}\label{wxsinglechoicedialoggetselection}\constfunc{int}{GetSelection}{\void}Returns the index of selected item.\membersection{wxSingleChoiceDialog::GetSelectionClientData}\label{wxsinglechoicedialoggetselectionclientdata}\constfunc{char*}{GetSelectionClientData}{\void}Returns the client data associated with the selection.\membersection{wxSingleChoiceDialog::GetStringSelection}\label{wxsinglechoicedialoggetstringselection}\constfunc{wxString}{GetStringSelection}{\void}Returns the selected string.\membersection{wxSingleChoiceDialog::SetSelection}\label{wxsinglechoicedialogsetselection}\constfunc{void}{SetSelection}{\param{int}{ selection}}Sets the index of the initially selected item.\membersection{wxSingleChoiceDialog::ShowModal}\label{wxsinglechoicedialogshowmodal}\func{int}{ShowModal}{\void}Shows the dialog, returning either wxID\_OK or wxID\_CANCEL.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -