Class: Savage::Directions::CubicCurveTo

Inherits:
Object
  • Object
show all
Defined in:
lib/monkeypatchsavage.rb

Instance Method Summary collapse

Instance Method Details

#toAbsolute(fromPoint) ⇒ Object



63
64
65
66
67
68
69
70
71
72
73
74
75
76
# File 'lib/monkeypatchsavage.rb', line 63

def toAbsolute(fromPoint)
  if not @absolute
    @target.x += fromPoint.x
    @target.y += fromPoint.y
    @control.x += fromPoint.x
    @control.y += fromPoint.y
    if @control_1
      @control_1.x += fromPoint.x
      @control_1.y += fromPoint.y
    end
  end
  @absolute = true
  return Point.new(@target.x,@target.y)
end