Class: Tui::SegmentWriter::FillSegment
- Inherits:
-
Object
- Object
- Tui::SegmentWriter::FillSegment
- Defined in:
- lib/tui.rb
Instance Attribute Summary collapse
-
#char ⇒ Object
readonly
Returns the value of attribute char.
-
#style ⇒ Object
readonly
Returns the value of attribute style.
Instance Method Summary collapse
-
#initialize(char, style: nil) ⇒ FillSegment
constructor
A new instance of FillSegment.
- #with_style(style) ⇒ Object
Constructor Details
#initialize(char, style: nil) ⇒ FillSegment
Returns a new instance of FillSegment.
642 643 644 645 |
# File 'lib/tui.rb', line 642 def initialize(char, style: nil) @char = char.to_s @style = style end |
Instance Attribute Details
#char ⇒ Object (readonly)
Returns the value of attribute char.
640 641 642 |
# File 'lib/tui.rb', line 640 def char @char end |
#style ⇒ Object (readonly)
Returns the value of attribute style.
640 641 642 |
# File 'lib/tui.rb', line 640 def style @style end |
Instance Method Details
#with_style(style) ⇒ Object
647 648 649 |
# File 'lib/tui.rb', line 647 def with_style(style) self.class.new(char, style: style) end |