Class: Wx::SetCursorEvent
- Defined in:
- lib/wx/doc/gen/events.rb
Overview
A SetCursorEvent is generated from Window when the mouse cursor is about to be set as a result of mouse motion.
This event gives the application the chance to perform specific mouse cursor processing based on the current position of the mouse within the window. Use #set_cursor to specify the cursor you want to be displayed.
Events using this class
The following event-handler methods redirect the events to member method or handler blocks for SetCursorEvent events. Event handler methods:
-
EvtHandler#evt_set_cursor(meth = nil, &block): Process a EVT_SET_CURSOR event.
Category: Events
Instance Method Summary collapse
-
#get_cursor ⇒ Wx::Cursor
(also: #cursor)
Returns a reference to the cursor specified by this event.
-
#get_x ⇒ Integer
(also: #x)
Returns the X coordinate of the mouse in client coordinates.
-
#get_y ⇒ Integer
(also: #y)
Returns the Y coordinate of the mouse in client coordinates.
-
#has_cursor ⇒ Boolean
(also: #has_cursor?)
Returns true if the cursor specified by this event is a valid cursor.
-
#initialize(x = 0, y = 0) ⇒ Wx::SetCursorEvent
constructor
Constructor, used by the library itself internally to initialize the event object.
-
#set_cursor(cursor) ⇒ void
(also: #cursor=)
Sets the cursor associated with this event.
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(x = 0, y = 0) ⇒ Wx::SetCursorEvent
Constructor, used by the library itself internally to initialize the event object.
795 |
# File 'lib/wx/doc/gen/events.rb', line 795 def initialize(x=0, y=0) end |
Instance Method Details
#get_cursor ⇒ Wx::Cursor Also known as: cursor
Returns a reference to the cursor specified by this event.
799 |
# File 'lib/wx/doc/gen/events.rb', line 799 def get_cursor; end |
#get_x ⇒ Integer Also known as: x
Returns the X coordinate of the mouse in client coordinates.
804 |
# File 'lib/wx/doc/gen/events.rb', line 804 def get_x; end |
#get_y ⇒ Integer Also known as: y
Returns the Y coordinate of the mouse in client coordinates.
809 |
# File 'lib/wx/doc/gen/events.rb', line 809 def get_y; end |
#has_cursor ⇒ Boolean Also known as: has_cursor?
Returns true if the cursor specified by this event is a valid cursor.
You cannot specify NULL_CURSOR with this event, as it is not considered a valid cursor.
820 |
# File 'lib/wx/doc/gen/events.rb', line 820 def has_cursor; end |
#set_cursor(cursor) ⇒ void Also known as: cursor=
This method returns an undefined value.
Sets the cursor associated with this event.
826 |
# File 'lib/wx/doc/gen/events.rb', line 826 def set_cursor(cursor) end |