Class: Wx::HelpProvider
- Inherits:
-
Object
- Object
- Wx::HelpProvider
- Defined in:
- lib/wx/doc/gen/help_provider.rb
Overview
HelpProvider is an abstract class used by a program implementing context-sensitive help to show the help text for the given window.
The current help provider must be explicitly set by the application using HelpProvider.set.
Category: HELP
Class Method Summary collapse
-
.get ⇒ Wx::HelpProvider
Returns pointer to help provider instance.
-
.set(helpProvider) ⇒ Wx::HelpProvider
Set the current, application-wide help provider.
Instance Method Summary collapse
- #add_help(*args) ⇒ Object
-
#get_help(window) ⇒ String
(also: #help)
This version associates the given text with all windows with this id.
-
#remove_help(window) ⇒ void
Removes the association between the window pointer and the help text.
-
#show_help(window) ⇒ Boolean
Shows help for the given window.
-
#show_help_at_point(window, point, origin) ⇒ Boolean
This function may be overridden to show help for the window when it should depend on the position inside the window, By default this method forwards to #show_help, so it is enough to only implement the latter if the help doesn’t depend on the position.
Class Method Details
.get ⇒ Wx::HelpProvider
Returns pointer to help provider instance.
Unlike some other classes, the help provider is not created on demand. This must be explicitly done by the application using set.
86 |
# File 'lib/wx/doc/gen/help_provider.rb', line 86 def self.get; end |
.set(helpProvider) ⇒ Wx::HelpProvider
Set the current, application-wide help provider.
Pointer to previous help provider or NULL if there wasn’t any.
93 |
# File 'lib/wx/doc/gen/help_provider.rb', line 93 def self.set(helpProvider) end |
Instance Method Details
#add_help(window, text) ⇒ void #add_help(id, text) ⇒ void
49 |
# File 'lib/wx/doc/gen/help_provider.rb', line 49 def add_help(*args) end |
#get_help(window) ⇒ String Also known as: help
This version associates the given text with all windows with this id.
May be used to set the same help string for all Cancel buttons in the application, for example.
56 |
# File 'lib/wx/doc/gen/help_provider.rb', line 56 def get_help(window) end |
#remove_help(window) ⇒ void
This method returns an undefined value.
Removes the association between the window pointer and the help text.
This is called by the Window destructor. Without this, the table of help strings will fill up and when window pointers are reused, the wrong help string will be found.
64 |
# File 'lib/wx/doc/gen/help_provider.rb', line 64 def remove_help(window) end |
#show_help(window) ⇒ Boolean
Shows help for the given window.
Override this function if the help doesn’t depend on the exact position inside the window, otherwise you need to override #show_help_at_point. Returns true if help was shown, or false if no help was available for this window.
71 |
# File 'lib/wx/doc/gen/help_provider.rb', line 71 def show_help(window) end |
#show_help_at_point(window, point, origin) ⇒ Boolean
This function may be overridden to show help for the window when it should depend on the position inside the window, By default this method forwards to #show_help, so it is enough to only implement the latter if the help doesn’t depend on the position.
true if help was shown, or false if no help was available for this window.
80 |
# File 'lib/wx/doc/gen/help_provider.rb', line 80 def show_help_at_point(window, point, origin) end |