Rearranged status bar a bit
This commit is contained in:
@@ -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,
|
||||||
|
|||||||
@@ -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);
|
||||||
|
|||||||
Reference in New Issue
Block a user