module Sawaal::TTY

Constants for TTY and methods to read and write to terminal

@api private

Constants

ARROW
BEGINNING_OF_LINE
CLEAR_LINE
CONTROL_C
HIDE_CURSOR
MOVE_DOWN
MOVE_UP
ORIGINAL_PRINT
RESTORE_POSITION
RETURN
SAVE_POSITION
SHOW_CURSOR

Public Class Methods

ansii_escape(sequence) click to toggle source
# File lib/sawaal/tty.rb, line 9
def ansii_escape(sequence)
  "\033[#{sequence}"
end
print(str) click to toggle source
println(str) click to toggle source
# File lib/sawaal/tty.rb, line 19
def println(str)
  puts str
end