diff options
author | Nicholas Marriott <nicm@openbsd.org> | 2013-07-05 14:44:06 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@openbsd.org> | 2013-07-05 14:44:06 +0000 |
commit | 7af5fec0387008c71bf29ad1e394871873acaf40 (patch) | |
tree | 8f6de82da7890a99f23dcb53a2fccb5c47fade8c /window-copy.c | |
parent | f884fff8693de02cea0347f1c267dbd925e3b5f5 (diff) |
Whitespace nits, from Ben Boeckel.
Diffstat (limited to 'window-copy.c')
-rw-r--r-- | window-copy.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/window-copy.c b/window-copy.c index f5f78cf2..9d4ff20e 100644 --- a/window-copy.c +++ b/window-copy.c @@ -1116,7 +1116,7 @@ window_copy_write_line( struct options *oo = &wp->window->options; struct grid_cell gc; char hdr[32]; - size_t last, xoff = 0, size = 0; + size_t last, xoff = 0, size = 0; window_mode_attrs(&gc, oo); @@ -1894,6 +1894,7 @@ void window_copy_cursor_next_word_end(struct window_pane *wp, const char *separators) { struct window_copy_mode_data *data = wp->modedata; + struct options *oo = &wp->window->options; struct screen *back_s = data->backing; u_int px, py, xx, yy; int expected = 1; @@ -1927,6 +1928,10 @@ window_copy_cursor_next_word_end(struct window_pane *wp, const char *separators) expected = !expected; } while (expected == 0); + /* Back up to the end-of-word like vi. */ + if (options_get_number(oo, "status-keys") == MODEKEY_VI && px != 0) + px--; + window_copy_update_cursor(wp, px, data->cy); if (window_copy_update_selection(wp)) window_copy_redraw_lines(wp, data->cy, 1); |