Module: WindowIO
- Defined in:
- lib/output.rb
Instance Method Summary collapse
-
#getch ⇒ Object
FIXME These don’t/can’t honor @started flag…
-
#gets ⇒ Object
still needs improvement.
- #p(*args) ⇒ Object
- #print(*args) ⇒ Object
- #putch(ch, r: nil, c: nil, fx: nil) ⇒ Object
-
#puts(*args) ⇒ Object
Doesn’t affect STDOUT.puts, etc.
- #rcprint(r, c, *args) ⇒ Object
Instance Method Details
#getch ⇒ Object
FIXME These don’t/can’t honor @started flag…
275 276 277 |
# File 'lib/output.rb', line 275 def getch X.getch end |
#gets ⇒ Object
still needs improvement
279 280 281 282 |
# File 'lib/output.rb', line 279 def gets # still needs improvement recv = RubyText.started ? $stdscr : Kernel recv.gets end |
#p(*args) ⇒ Object
263 264 265 266 |
# File 'lib/output.rb', line 263 def p(*args) recv = RubyText.started ? $stdscr : Kernel recv.p(*args) end |
#print(*args) ⇒ Object
258 259 260 261 |
# File 'lib/output.rb', line 258 def print(*args) recv = RubyText.started ? $stdscr : Kernel recv.print(*args) end |
#putch(ch, r: nil, c: nil, fx: nil) ⇒ Object
284 285 286 287 288 289 |
# File 'lib/output.rb', line 284 def putch(ch, r: nil, c: nil, fx: nil) r, c = STDSCR.rc r ||= r0 c ||= c0 STDSCR.putch(ch, r: r, c: c, fx: fx) end |