]> git.saurik.com Git - wxWidgets.git/blobdiff - docs/latex/wx/tevent.tex
test indeterminate wxGauge mode (part of patch 1551409)
[wxWidgets.git] / docs / latex / wx / tevent.tex
index 0d0ae34d0b47ace45360697cafd72e6629901b26..b86612c155e023a5e861ef56adcf2dd469f3d03b 100644 (file)
@@ -211,7 +211,6 @@ here is a list of system events which will NOT get sent to the parent's event ha
 \twocolitem{\helpref{wxSizeEvent}{wxsizeevent}}{A size event}
 \twocolitem{\helpref{wxScrollWinEvent}{wxscrollwinevent}}{A scroll event sent by a scrolled window (not a scroll bar)}
 \twocolitem{\helpref{wxSysColourChangedEvent}{wxsyscolourchangedevent}}{A system colour change event}
 \twocolitem{\helpref{wxSizeEvent}{wxsizeevent}}{A size event}
 \twocolitem{\helpref{wxScrollWinEvent}{wxscrollwinevent}}{A scroll event sent by a scrolled window (not a scroll bar)}
 \twocolitem{\helpref{wxSysColourChangedEvent}{wxsyscolourchangedevent}}{A system colour change event}
-\twocolitem{\helpref{wxUpdateUIEvent}{wxupdateuievent}}{A user interface update event}
 \end{twocollist}
 
 In some cases, it might be desired by the programmer to get a certain number
 \end{twocollist}
 
 In some cases, it might be desired by the programmer to get a certain number
@@ -220,6 +219,30 @@ used by, the native controls in a dialog. In this case, a special event handler
 will have to be written that will override ProcessEvent() in order to pass
 all events (or any selection of them) to the parent window.
 
 will have to be written that will override ProcessEvent() in order to pass
 all events (or any selection of them) to the parent window.
 
+
+\subsection{Events generated by the user vs programmatically generated events}\label{progevent}
+
+While generically \helpref{wxEvents}{wxevent} can be generated both by user
+actions (e.g. resize of a \helpref{wxWindow}{wxwindow}) and by calls to functions
+(e.g. \helpref{wxWindow::SetSize}{wxwindowsetsize}), wxWidgets controls
+normally send \helpref{wxCommandEvent}{wxcommandevent}-derived events only for
+the user-generated events. The only {\bf exceptions} to this rule are:
+
+\begin{twocollist}\itemsep=0pt
+\twocolitem{\helpref{wxNotebook::AddPage}{wxnotebookaddpage}}{No event-free alternatives}
+\twocolitem{\helpref{wxNotebook::AdvanceSelection}{wxnotebookadvanceselection}}{No event-free alternatives}
+\twocolitem{\helpref{wxNotebook::DeletePage}{wxnotebookdeletepage}}{No event-free alternatives}
+\twocolitem{\helpref{wxNotebook::SetSelection}{wxnotebooksetselection}}{Use \helpref{wxNotebook::ChangeSelection}{wxnotebookchangeselection} instead, as \helpref{wxNotebook::SetSelection}{wxnotebooksetselection} is deprecated}
+\twocolitem{\helpref{wxTreeCtrl::Delete}{wxtreectrldelete}}{No event-free alternatives}
+\twocolitem{\helpref{wxTreeCtrl::DeleteAllItems}{wxtreectrldeleteallitems}}{No event-free alternatives}
+\twocolitem{\helpref{wxTreeCtrl::EditLabel}{wxtreectrleditlabel}}{No event-free alternatives}
+\twocolitem{All \helpref{wxTextCtrl}{wxtextctrl} methods}{\helpref{wxTextCtrl::ChangeValue}{wxtextctrlchangevalue} can be used instead
+of \helpref{wxTextCtrl::SetValue}{wxtextctrlsetvalue} but the other functions,
+such as \helpref{Replace}{wxtextctrlreplace} or \helpref{WriteText}{wxtextctrlwritetext} 
+don't have event-free equivalents}
+\end{twocollist}
+
+
 % VZ: it doesn't work like this, but just in case we ever reenable this
 %     behaviour, I leave it here
 %
 % VZ: it doesn't work like this, but just in case we ever reenable this
 %     behaviour, I leave it here
 %
@@ -447,7 +470,7 @@ DEFINE_EVENT_TYPE(wxEVT_MY_EVENT)
 BEGIN_EVENT_TABLE(MyFrame, wxFrame)
   EVT_MENU    (wxID_EXIT, MyFrame::OnExit)
   // ....
 BEGIN_EVENT_TABLE(MyFrame, wxFrame)
   EVT_MENU    (wxID_EXIT, MyFrame::OnExit)
   // ....
-  EVT_COMMAND  (wxEVT_MY_EVENT, ID_MY_WINDOW,  MyFrame::OnMyEvent)
+  EVT_COMMAND  (ID_MY_WINDOW, wxEVT_MY_EVENT, MyFrame::OnMyEvent)
 END_EVENT_TABLE()
 
 void MyFrame::OnMyEvent( wxCommandEvent &event )
 END_EVENT_TABLE()
 
 void MyFrame::OnMyEvent( wxCommandEvent &event )