class wxHelpEvent : public wxCommandEvent
{
public:
+ // how was this help event generated?
+ enum Origin
+ {
+ Origin_Unknown, // unrecognized event source
+ Origin_Keyboard, // event generated from F1 key press
+ Origin_HelpButton // event from [?] button on the title bar (Windows)
+ };
+
DocCtorStr(
wxHelpEvent(wxEventType type = wxEVT_NULL,
wxWindowID winid = 0,
- const wxPoint& pt = wxDefaultPosition),
+ const wxPoint& pt = wxDefaultPosition,
+ Origin origin = Origin_Unknown ),
"", "");
DocDeclStr(
void , SetTarget(const wxString& target),
"Set an optional target to display help in. E.g. a window specification", "");
+
+ // optional indication of the event source
+ DocDeclStr(
+ Origin , GetOrigin() const,
+ "Optiononal indication of the source of the event.", "");
+ DocDeclStr(
+ void , SetOrigin(Origin origin),
+ "", "");
+
};
//---------------------------------------------------------------------------
:see: `wx.ContextHelpButton`
", "");
+MustHaveApp(wxContextHelp);
+
class wxContextHelp : public wxObject {
public:
DocCtorStr(
- wxContextHelp(wxWindow* window = NULL, bool doNow = True),
+ wxContextHelp(wxWindow* window = NULL, bool doNow = true),
"Constructs a context help object, calling BeginContextHelp if doNow is
true (the default).
:see: `wx.ContextHelp`, `wx.ContextHelpButton`
", "");
+MustHaveApp(wxContextHelpButton);
+
class wxContextHelpButton : public wxBitmapButton {
public:
%pythonAppend wxContextHelpButton "self._setOORInfo(self)"
class wxHelpProvider
{
public:
+
+ ~wxHelpProvider();
+
+
+ %disownarg( wxHelpProvider *helpProvider );
+ %newobject Set;
DocDeclStr(
static wxHelpProvider *, Set(wxHelpProvider *helpProvider),
"Sset the current, application-wide help provider. Returns the previous
one. Unlike some other classes, the help provider is not created on
demand. This must be explicitly done by the application.", "");
+ %cleardisown( wxHelpProvider *helpProvider );
DocDeclStr(
static wxHelpProvider *, Get(),
"Shows help for the given window. Uses GetHelp internally if
applicable. Returns True if it was done, or False if no help was
available for this window.", "");
+
+ DocDeclStr(
+ virtual bool , ShowHelpAtPoint(wxWindowBase *window,
+ const wxPoint& pt,
+ wxHelpEvent::Origin origin),
+ "Show help for the given window (uses window.GetHelpAtPoint()
+internally if applicable), return true if it was done or false if no
+help available for this window.", "");
+
+
DocDeclStr(
void , AddHelp(wxWindow *window, const wxString& text),
reused, the wrong help string will be found.", "");
+ %pythonAppend Destroy "args[0].thisown = 0"
%extend { void Destroy() { delete self; } }
};