def sub_selection_dialog_items(self, pos, i_pos, screen):
"""
Draw items in `Selection Dialog`.
:param pos: Index of selected item in `Configure Setting` frame.
:type pos: int
:param i_pos: Index of selected item in `Selection Dialog`.
:type i_pos: int
:param screen: A **WindowObject** which represents the selection
dialog.
:type screen: WindowObject
"""
# Set local variable
normal = curses.A_NORMAL
select = normal + curses.A_BOLD
for p, item in enumerate(self.settings[pos][2]):
item_str = item if pos else item["tag"]
screen.addstr(1 + p, 2, item_str,
select if p == i_pos else normal)
screen.refresh()
评论列表
文章目录