Module: Tui::Helpers

Included in:
Screen, SegmentWriter
Defined in:
lib/tui.rb

Instance Method Summary collapse

Instance Method Details

#accent(text) ⇒ Object



295
296
297
# File 'lib/tui.rb', line 295

def accent(text)
  Text.accent(text)
end

#bold(text) ⇒ Object



283
284
285
# File 'lib/tui.rb', line 283

def bold(text)
  Text.bold(text)
end

#dim(text) ⇒ Object



287
288
289
# File 'lib/tui.rb', line 287

def dim(text)
  Text.dim(text)
end

#emoji(char) ⇒ Object

Use for emoji characters - precomputes width and enables fast-path



304
305
306
# File 'lib/tui.rb', line 304

def emoji(char)
  SegmentWriter::EmojiSegment.new(char)
end

#fill(char = " ") ⇒ Object



299
300
301
# File 'lib/tui.rb', line 299

def fill(char = " ")
  SegmentWriter::FillSegment.new(char.to_s)
end

#highlight(text) ⇒ Object



291
292
293
# File 'lib/tui.rb', line 291

def highlight(text)
  Text.highlight(text)
end