Lines Matching refs:win

1067         for win in _top_sep_win, _menu_win, _bot_sep_win, _help_win:
1068 win.mvwin(0, 0)
1076 def _height(win): argument
1079 return win.getmaxyx()[0]
1082 def _width(win): argument
1085 return win.getmaxyx()[1]
1714 win = _styled_win("body")
1715 win.keypad(True)
1720 _resize_input_dialog(win, title, info_lines)
1731 return _width(win) - 4
1741 _draw_input_dialog(win, title, info_lines, s, i, hscroll)
1745 c = _getch_compat(win)
1750 _resize_input_dialog(win, title, info_lines)
1764 def _resize_input_dialog(win, title, info_lines): argument
1779 win.resize(win_height, win_width)
1780 win.mvwin((screen_height - win_height)//2,
1784 def _draw_input_dialog(win, title, info_lines, s, i, hscroll): argument
1785 edit_width = _width(win) - 4
1787 win.erase()
1791 _safe_addstr(win, 2, 2, visible_s + " "*(edit_width - len(visible_s)),
1795 _safe_addstr(win, 4 + linenr, 2, line)
1798 _draw_frame(win, title)
1800 _safe_move(win, 2, 2 + i - hscroll)
1802 win.noutrefresh()
1937 win = _styled_win("body")
1938 win.keypad(True)
1940 _resize_key_dialog(win, text)
1945 _draw_key_dialog(win, title, text)
1949 c = _getch_compat(win)
1954 _resize_key_dialog(win, text)
1965 def _resize_key_dialog(win, text): argument
1975 win.resize(win_height, win_width)
1976 win.mvwin((screen_height - win_height)//2,
1980 def _draw_key_dialog(win, title, text): argument
1981 win.erase()
1984 _safe_addstr(win, 2 + i, 2, line)
1987 _draw_frame(win, title)
1989 win.noutrefresh()
1992 def _draw_frame(win, title): argument
1995 win_height, win_width = win.getmaxyx()
1997 win.attron(_style["frame"])
2000 _safe_hline(win, 0, 0, " ", win_width)
2001 _safe_hline(win, win_height - 1, 0, " ", win_width)
2004 _safe_vline(win, 0, 0, " ", win_height)
2005 _safe_vline(win, 0, win_width - 1, " ", win_height)
2008 _safe_addstr(win, 0, max((win_width - len(title))//2, 0), title)
2010 win.attroff(_style["frame"])
2275 for win in matches_win, bot_sep_win, help_win:
2276 win.mvwin(0, 0)
2474 for win in text_win, bot_sep_win, help_win:
2475 win.mvwin(0, 0)
2842 win = curses.newwin(1, 1)
2843 _set_style(win, style)
2844 return win
2847 def _set_style(win, style): argument
2850 win.bkgdset(" ", _style[style])
2853 def _max_scroll(lst, win): argument
2858 return max(0, len(lst) - _height(win))
3139 def _getch_compat(win): argument
3149 c = win.get_wch()
3151 c = win.getch()
3192 def _safe_addstr(win, *args): argument
3199 y, x = win.getyx()
3208 maxlen = _width(win) - x
3216 win.addnstr(y, x, s, maxlen)
3218 win.addnstr(y, x, s, maxlen, attr)
3223 def _safe_addch(win, *args): argument
3225 win.addch(*args)
3230 def _safe_hline(win, *args): argument
3232 win.hline(*args)
3237 def _safe_vline(win, *args): argument
3239 win.vline(*args)
3244 def _safe_move(win, *args): argument
3246 win.move(*args)