Class: Shoes::Shape

Inherits:
ShapeBase show all
Defined in:
lib/shoes/basic.rb

Instance Attribute Summary

Attributes inherited from Basic

#args, #dps, #initials, #ln, #parent, #pl

Attributes included from Mod

#margin_bottom, #margin_left, #margin_right, #margin_top

Instance Method Summary collapse

Methods inherited from Basic

#clear, #fix_size, #hide, #hided, #initialize, #move, #move2, #positioning, #set_args, #show, #style, #toggle

Methods included from Mod

#click, #release, #set_margin

Constructor Details

This class inherits a constructor from Shoes::Basic

Instance Method Details

#line_to(x, y) ⇒ Object



181
182
183
# File 'lib/shoes/basic.rb', line 181

def line_to x, y
  real.lineTo x + left, y + top
end

#move3(x, y) ⇒ Object



172
173
174
175
176
177
# File 'lib/shoes/basic.rb', line 172

def move3 x, y
  unless @app.cs.isDisposed
    real.dispose
  end
  @left, @top = x, y
end

#move_to(x, y) ⇒ Object



178
179
180
# File 'lib/shoes/basic.rb', line 178

def move_to x, y
  real.moveTo x + left, y + top
end

#quad_to(cx, cy, x, y) ⇒ Object



184
185
186
# File 'lib/shoes/basic.rb', line 184

def quad_to cx, cy, x, y
  real.quadTo cx + left, cy + top, x + left, y + top
end