Type:
Class

Description

The means by which to create and manage frames or windows. While there may be more than one window at a time, only one window will receive input.

Usage

require 'curses'

Curses.init_screen()

my_str = "LOOK! PONIES!"
win = Curses::Window.new( 8, (my_str.length + 10),
                          (Curses.lines - 8) / 2,
                          (Curses.cols - (my_str.length + 10)) / 2 )
win.box("|", "-")
win.setpos(2,3)
win.addstr(my_str)
# or even
win << "\nORLY"
win << "\nYES!! " + my_str
win.refresh
win.getch
win.close
subwin

subwin(height, width, top, left) Instance Public methods Contruct a new subwindow

2015-04-02 04:07:31
getbkgd

getbkgd() Instance Public methods Returns an Interer (ch) for the

2015-04-02 02:22:08
maxx

maxx() Instance Public methods A getter for the maximum columns for the window

2015-04-02 03:05:21
insertln

insertln() Instance Public methods Inserts a line above the cursor, and the

2015-04-02 02:50:23
attrset

attrset(attrs) Instance Public methods Sets the current attributes of the given

2015-04-02 01:26:13