qulogic/libgnt
Clone
Summary
Browse
Changes
Graph
Merged in strangeways/main/trac-16764 (pull request #268)
release-2.x.y
2017-09-26, Gary Kramlich
f5832b936b02
Merged in strangeways/main/trac-16764 (pull request #268)
Use accessors when accessing ncurses structures
Approved-by: Eion Robb
Approved-by: Gary Kramlich
Approved-by: Elliott Sales de Andrade
Approved-by: dx
#include
<ncurses.h>
int
main
()
{
int
ch
;
initscr
();
noecho
();
cbreak
();
refresh
();
WINDOW
*
win
=
newpad
(
20
,
30
);
box
(
win
,
0
,
0
);
prefresh
(
win
,
0
,
0
,
0
,
0
,
19
,
29
);
doupdate
();
while
((
ch
=
getch
()))
{
printw
(
"%d "
,
ch
);
refresh
();
}
endwin
();
return
0
;
}