summaryrefslogtreecommitdiffhomepage
path: root/contrib/luacurses/src/test/getyx.lua
blob: 4600236bb1995106698ccca65ba6bb23c23cc94c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13

require("curses");

curses.initscr();
while (true) do
    local s = curses.getnstr(1000);
    curses.addstr(s);
    curses.addstr(":" .. table.concat({curses.getyx(curses.stdscr())}, ' ') .. "\n");
    if (s == "exit") then break; end
end

curses.endwin();