Lines Matching refs:p
10 static void __tui_progress__init(struct ui_progress *p) in __tui_progress__init() argument
12 p->next = p->step = p->total / (SLtt_Screen_Cols - 2) ?: 1; in __tui_progress__init()
15 static int get_title(struct ui_progress *p, char *buf, size_t size) in get_title() argument
21 ret = unit_number__scnprintf(buf_cur, sizeof(buf_cur), p->curr); in get_title()
22 ret += unit_number__scnprintf(buf_tot, sizeof(buf_tot), p->total); in get_title()
25 p->title, buf_cur, buf_tot); in get_title()
28 static void tui_progress__update(struct ui_progress *p) in tui_progress__update() argument
30 char buf[100], *title = (char *) p->title; in tui_progress__update()
39 if (p->total == 0) in tui_progress__update()
42 if (p->size) { in tui_progress__update()
43 get_title(p, buf, sizeof(buf)); in tui_progress__update()
56 bar = ((SLtt_Screen_Cols - 2) * p->curr) / p->total; in tui_progress__update()