Class: Soundcloud9000::UI::Canvas

Inherits:
Object
  • Object
show all
Defined in:
lib/soundcloud9000/ui/canvas.rb

Overview

initializes our Curses canvas for drawing on

Instance Method Summary collapse

Constructor Details

#initializeCanvas

Returns a new instance of Canvas.



9
10
11
12
13
14
# File 'lib/soundcloud9000/ui/canvas.rb', line 9

def initialize
  Curses.noecho # do not show typed keys
  Curses.stdscr.keypad(true) # enable arrow keys
  Curses.init_screen
  Color.init
end

Instance Method Details

#closeObject



16
17
18
# File 'lib/soundcloud9000/ui/canvas.rb', line 16

def close
  Curses.close_screen
end