Rearranged status bar a bit

This commit is contained in:
luxferre
2023-07-29 08:43:08 +03:00
parent df633e073b
commit 5d1008256c
2 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -71,7 +71,7 @@ Invoking `nne` without arguments just creates a new buffer. You can specify a fi
### Status bar ### Status bar
The status bar in nne is the last line of the terminal. Some operations may change its contents, but normally it consists of the following elements: `[state] [filename] [row],[col] [file%] [W]x[H]`, where: The status bar in nne is the last line of the terminal. Some operations may change its contents, but normally it consists of the following elements: `[state] [row],[col] [file%] [W]x[H] | [filename]`, where:
- `[state]` can be `-` (normal/insertion) or `C` (modal command), - `[state]` can be `-` (normal/insertion) or `C` (modal command),
- `[filename]` refers to the file currently being edited, - `[filename]` refers to the file currently being edited,
+3 -3
View File
@@ -528,10 +528,10 @@ void render() { /* main screen rendering function */
scrbuf_append(nne_msgbuf); scrbuf_append(nne_msgbuf);
nne_status_override = 0; nne_status_override = 0;
} }
else scrbuf_append(nnmsg(0, CURSET "%c %s %u,%u %02u%% %ux%u | %s", nne_termh, 1, else scrbuf_append(nnmsg(0, CURSET "%c %u,%u %02u%% %ux%u | %s | %s", nne_termh, 1,
(nne_mode == NNE_CMD) ? 'C' : '-', nne_fname, nne_row, nne_col, (nne_mode == NNE_CMD) ? 'C' : '-', nne_row, nne_col,
(100*nne_pos/(nne_real_len <= 2 ? 2 : nne_real_len - 2)), (100*nne_pos/(nne_real_len <= 2 ? 2 : nne_real_len - 2)),
nne_termw, nne_termh, "Press Esc Esc h to get help")); nne_termw, nne_termh, nne_fname, "Press Esc Esc h to get help"));
scrbuf_append(nnmsg(0, CURSET CURSHOW "\0", nne_scry, nne_scrx)); scrbuf_append(nnmsg(0, CURSET CURSHOW "\0", nne_scry, nne_scrx));
/* actually draw the screen buffer until the first zero byte */ /* actually draw the screen buffer until the first zero byte */
nnputs(nne_scrbuf); nnputs(nne_scrbuf);