view finch/libgnt/test/key.c @ 15979:2c81ebc7bf0b

Add a way to get a list of bindings for a widget. This can be used by, eg, a window-manager to show helpful messages to the user.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Wed, 04 Apr 2007 03:47:13 +0000
parents 0e3a8505ebbe
children f104e1d45d85
line wrap: on
line source

#include <ncurses.h>

int main()
{
	int ch;
	initscr();

	noecho();

	while ((ch = getch())) {
		printw("%d ", ch);
		refresh();
	}

	endwin();
	return 0;
}