diff options
author | andmarti1424 <andmarti@gmail.com> | 2017-04-28 19:02:23 -0300 |
---|---|---|
committer | andmarti1424 <andmarti@gmail.com> | 2017-04-28 19:02:23 -0300 |
commit | 2a883e94dd75b0d40eae11a08d3df6951e5c6758 (patch) | |
tree | 2c2ae99b95b6d1725f294ace44df2e312b93fc5a /src/tui.c | |
parent | c00342ef22c3155611bcc28ddef33e341aa990c8 (diff) |
Renamed plot files. Fix when pausing and resuming ncurses ui.
Diffstat (limited to 'src/tui.c')
-rw-r--r-- | src/tui.c | 18 |
1 files changed, 17 insertions, 1 deletions
@@ -27,6 +27,8 @@ * ui_clr_header // functions that clears a line in header bar * ui_print_mode // function that shows current mode in top right of screen * ui_get_formated_value // function used for exporting spreadsheet to plain text + * ui_pause + * ui_resume * * these are local functions that might not be needed to reimplement if writing another ui: * ui_set_ucolor // function called internally for setting a color @@ -78,7 +80,6 @@ SCREEN * sstdout; srange * ranges; void ui_start_screen() { - //def_shell_mode(); sstderr = newterm(NULL, stderr, NULL); noecho(); sstdout = newterm(NULL, stdout, stdin); @@ -1106,3 +1107,18 @@ void ui_start_colors() { for (j=0; j < 9; j++) // bg init_pair( i*9+j+1, i-1, j-1); // i is fg and j is bg } + +void ui_pause() { + def_prog_mode(); + set_term(sstderr); + endwin(); + return; +} + +void ui_resume() { + set_term(sstdout); + reset_prog_mode(); + refresh(); + return; +} + |