Class: ImgToScript::AbstractToken::MovePointToAbsCoords

Inherits:
AbstractToken
  • Object
show all
Defined in:
lib/img_to_script/abstract_token/move_point_to_abs_coords.rb

Overview

Move point to the (x, y) position (in the absolute coordinates).

Instance Attribute Summary collapse

Attributes inherited from AbstractToken

#require_nl, #type

Instance Method Summary collapse

Constructor Details

#initialize(x:, y:) ⇒ MovePointToAbsCoords

Returns a new instance of MovePointToAbsCoords.



11
12
13
14
15
16
17
# File 'lib/img_to_script/abstract_token/move_point_to_abs_coords.rb', line 11

def initialize(x:, y:, **)
  @x = x
  @y = y
  @type = AbsTokenType::MOVE_POINT_TO_ABS_COORDS

  super
end

Instance Attribute Details

#xObject (readonly)

Returns the value of attribute x.



9
10
11
# File 'lib/img_to_script/abstract_token/move_point_to_abs_coords.rb', line 9

def x
  @x
end

#yObject (readonly)

Returns the value of attribute y.



9
10
11
# File 'lib/img_to_script/abstract_token/move_point_to_abs_coords.rb', line 9

def y
  @y
end