Class: Geometry::Text

Inherits:
Object
  • Object
show all
Defined in:
lib/aurora-geometry/text.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(position, content) ⇒ Text

Returns a new instance of Text.



14
15
16
17
# File 'lib/aurora-geometry/text.rb', line 14

def initialize(position, content)
	@position = Point[position]
	@content = content
end

Instance Attribute Details

#contentString (readonly)

Returns The Geometry::Text‘s textual content.

Returns:



12
13
14
# File 'lib/aurora-geometry/text.rb', line 12

def content
  @content
end

#positionPoint (readonly)

bounding box

Returns:



9
10
11
# File 'lib/aurora-geometry/text.rb', line 9

def position
  @position
end

Instance Method Details

#eql?(other) ⇒ Boolean Also known as: ==

Returns:

  • (Boolean)


19
20
21
# File 'lib/aurora-geometry/text.rb', line 19

def eql?(other)
	self.content == other.content
end