- // setup header
- if(bar_top) {
- line = deck->header;
- offset = next_blank(line->text, 0) + 1;
- // add text to header
- mvwprintw(stdscr,
- 0, (COLS - line->length + offset) / 2,
- "%s", &line->text->text[offset]);
- }
-
- // setup footer
- //TODO display slide number in footer
- if(bar_bottom) {
- line = deck->header->next;
- offset = next_blank(line->text, 0) + 1;
- // add text to left footer
- mvwprintw(stdscr,
- LINES - 1, 3,
- "%s", &line->text->text[offset]);
-
- if(deck->headers > 2) {
- line = deck->header->next->next;
- offset = next_blank(line->text, 0) + 1;
- // add text to right footer
- mvwprintw(stdscr,
- LINES - 1, COLS - line->length + offset - 3,
- "%s", &line->text->text[offset]);
- }
- }
-
- // make header + fooder visible
- wrefresh(stdscr);
-