Class: PFM::Message::Instructions::Text

Inherits:
Object
  • Object
show all
Defined in:
scripts/01450 Systems/00004 Message/00001 Logic/00003 Instructions.rb

Overview

Class that describe a text object

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(text, width) ⇒ Text

Create a new text object

Parameters:

  • text (String)

    text to show

  • width (Integer)

    width of the text to show



226
227
228
229
# File 'scripts/01450 Systems/00004 Message/00001 Logic/00003 Instructions.rb', line 226

def initialize(text, width)
  @text = text
  @width = width
end

Instance Attribute Details

#textString (readonly)

Get the text to show

Returns:



218
219
220
# File 'scripts/01450 Systems/00004 Message/00001 Logic/00003 Instructions.rb', line 218

def text
  @text
end

#widthInteger (readonly)

Get the width of the text

Returns:



221
222
223
# File 'scripts/01450 Systems/00004 Message/00001 Logic/00003 Instructions.rb', line 221

def width
  @width
end