Class: Wx::SF::ShapeHandleEvent

Inherits:
Event
  • Object
show all
Defined in:
lib/wx/shapes/events.rb

Overview

Class encapsulates Wx::SF shape handle related event.

Instance Method Summary collapse

Constructor Details

#initialize(evt_type = Wx::EVT_NULL, id = 0) ⇒ ShapeHandleEvent

Constructor

Parameters:

  • evt_type (Integer) (defaults to: Wx::EVT_NULL)
  • id (Integer) (defaults to: 0)


169
170
171
172
173
# File 'lib/wx/shapes/events.rb', line 169

def initialize(evt_type = Wx::EVT_NULL, id = 0)
  super(evt_type, id.to_i)
  @shape = nil
  @handle = nil
end

Instance Method Details

#get_handleWx::SF::Shape::Handle Also known as: handle

Get shape handle

Returns:



198
199
200
# File 'lib/wx/shapes/events.rb', line 198

def get_handle
  @handle
end

#get_shapeWx::SF::Shape? Also known as: shape

Get a shape object from the event object.

Returns:



184
185
186
# File 'lib/wx/shapes/events.rb', line 184

def get_shape
  @shape
end

#set_handle(handle) ⇒ Object Also known as: handle=

Set dragged shape handle

Parameters:

  • handle (Wx::Shape::Handle)

    shape handle



191
192
193
# File 'lib/wx/shapes/events.rb', line 191

def set_handle(handle)
  @handle = handle
end

#set_shape(shape) ⇒ Object Also known as: shape=

Insert a shape object to the event object.

Parameters:



177
178
179
# File 'lib/wx/shapes/events.rb', line 177

def set_shape(shape)
  @shape = shape
end