Class: Wx::SashEvent

Inherits:
CommandEvent show all
Defined in:
lib/wx/doc/gen/sash_event.rb

Overview

A sash event is sent when the sash of a SashWindow has been dragged by the user.

Remark:

When a sash belonging to a sash window is dragged by the user, and then released, this event is sent to the window, where it may be processed by an event table entry in a derived class, a plug-in event handler or an ancestor class. Note that the SashWindow doesn't change the window's size itself. It relies on the application's event handler to do that. This is because the application may have to handle other consequences of the resize, or it may wish to veto it altogether. The event handler should look at the drag rectangle: see #get_drag_rect to see what the new size of the window would be if the resize were to be applied. It should also call #get_drag_status to see whether the drag was OK or out of the current allowed range.

Events using this class

The following event-handler methods redirect the events to member method or handler blocks for SashEvent events. Event handler methods:

Category: Events

See Also:

Requires:

  • USE_SASH

Instance Method Summary collapse

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(id = 0, edge = Wx::SashEdgePosition::SASH_NONE) ⇒ Wx::SashEvent

Constructor.

Parameters:

  • id (Integer) (defaults to: 0)
  • edge (Wx::SashEdgePosition) (defaults to: Wx::SashEdgePosition::SASH_NONE)


106
# File 'lib/wx/doc/gen/sash_event.rb', line 106

def initialize(id=0, edge=Wx::SashEdgePosition::SASH_NONE) end

Instance Method Details

#get_drag_rectWx::Rect Also known as: drag_rect

Returns the rectangle representing the new size the window would be if the resize was applied.

It is up to the application to set the window size if required.

Returns:



112
# File 'lib/wx/doc/gen/sash_event.rb', line 112

def get_drag_rect; end

#get_drag_statusWx::SashDragStatus Also known as: drag_status

Returns the status of the sash: one of Wx::SashDragStatus::SASH_STATUS_OK, Wx::SashDragStatus::SASH_STATUS_OUT_OF_RANGE.

If the drag caused the notional bounding box of the window to flip over, for example, the drag will be out of rage.

Returns:



119
# File 'lib/wx/doc/gen/sash_event.rb', line 119

def get_drag_status; end

#get_edgeWx::SashEdgePosition Also known as: edge



126
# File 'lib/wx/doc/gen/sash_event.rb', line 126

def get_edge; end

#set_drag_rect(rect) ⇒ void Also known as: drag_rect=

This method returns an undefined value.

Parameters:



136
# File 'lib/wx/doc/gen/sash_event.rb', line 136

def set_drag_rect(rect) end

#set_drag_status(status) ⇒ void Also known as: drag_status=

This method returns an undefined value.

Parameters:



141
# File 'lib/wx/doc/gen/sash_event.rb', line 141

def set_drag_status(status) end

#set_edge(edge) ⇒ void Also known as: edge=

This method returns an undefined value.

Parameters:



131
# File 'lib/wx/doc/gen/sash_event.rb', line 131

def set_edge(edge) end