Class: Wx::SpinEvent
- Inherits:
-
NotifyEvent
- Object
- Object
- Event
- CommandEvent
- NotifyEvent
- Wx::SpinEvent
- Defined in:
- lib/wx/doc/gen/spin_event.rb
Overview
This event class is used for the events generated by SpinButton and SpinCtrl.
Events using this class
The following event-handler methods redirect the events to member method or handler blocks for SpinEvent events. Event handler methods:
-
EvtHandler#evt_spin(id, meth = nil, &block): Generated whenever an arrow is pressed.
-
EvtHandler#evt_spin_up(id, meth = nil, &block): Generated when left/up arrow is pressed.
-
EvtHandler#evt_spin_down(id, meth = nil, &block): Generated when right/down arrow is pressed.
Note that if you handle both SPIN and UP or DOWN events, you will be notified about each of them twice: first the UP/DOWN event will be received and then, if it wasn’t vetoed, the SPIN event will be sent.
Category: Events
Instance Method Summary collapse
-
#get_position ⇒ Integer
(also: #position)
Retrieve the current spin button or control value.
-
#initialize(commandType = Wx::EVT_NULL, id = 0) ⇒ Wx::SpinEvent
constructor
The constructor is not normally used by the user code.
-
#set_position(pos) ⇒ void
(also: #position=)
Set the value associated with the event.
Methods inherited from NotifyEvent
Methods inherited from CommandEvent
#client_data, #client_data=, #get_client_data, #get_client_object, #get_int, #get_selection, #get_string, #is_checked, #is_selection, #set_client_data, #set_client_object, #set_extra_long, #set_int, #set_string
Methods inherited from Event
#clone, #get_event_category, #get_event_object, #get_event_type, #get_id, #get_skipped, #get_timestamp, #is_command_event, #resume_propagation, #set_event_object, #set_event_type, #set_id, #set_timestamp, #should_propagate, #skip, #stop_propagation
Methods inherited from Object
#clone, #dup, #is_same_as, #un_share
Constructor Details
#initialize(commandType = Wx::EVT_NULL, id = 0) ⇒ Wx::SpinEvent
The constructor is not normally used by the user code.
35 |
# File 'lib/wx/doc/gen/spin_event.rb', line 35 def initialize(commandType=Wx::EVT_NULL, id=0) end |
Instance Method Details
#get_position ⇒ Integer Also known as: position
Retrieve the current spin button or control value.
39 |
# File 'lib/wx/doc/gen/spin_event.rb', line 39 def get_position; end |
#set_position(pos) ⇒ void Also known as: position=
This method returns an undefined value.
Set the value associated with the event.
45 |
# File 'lib/wx/doc/gen/spin_event.rb', line 45 def set_position(pos) end |