Tmux: Search in copy mode doesn't find matches wrapped across lines

Created on 11 Oct 2019  路  3Comments  路  Source: tmux/tmux

Hey. I just got confused because searching in copy mode didn't find what I was expecting to be visible on screen. Turns out it was there, but visually broken into two parts by a line break because a long line gets wrapped.

Here's an example to reproduce. Type some characters to get close to the end of right border of the pane. Then start typing a long word so it gets wrapped. In my case it now looks like this:

Screenshot 2019-10-11 12 21 23

Now enter copy mode and search backwards for your word, bbbbbbbb in my case. It doesn't find it because it's visually split.

  • [ ] this match should still be found

For context, when I change the pane width so that the target word is no longer split, like this:

Screenshot 2019-10-11 12 21 45

If I enter copy mode now and search for bbbbbbbb it finds it now as expected.

  • tmux version (tmux -V). tmux 2.9a
  • Platform (uname -sp). Darwin i386
  • $TERM inside and outside of tmux (echo $TERM). screen-256color

Most helpful comment

Yes this is already known and on the todo list:
~~~~

  • Searching in copy mode should handle wrapping, so a search for "foobar" then
    it should be found even if wrapped into "foo\nbar" (that is, the
    GRID_LINE_WRAPPED flag is set on the line).

All 3 comments

I can confirm this behaviour on
tmux next-3.1 @ 7323ffee
macOs : 10.14.6
$TERM = xterm-256color (inside and out)

Yes this is already known and on the todo list:
~~~~

  • Searching in copy mode should handle wrapping, so a search for "foobar" then
    it should be found even if wrapped into "foo\nbar" (that is, the
    GRID_LINE_WRAPPED flag is set on the line).

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kevinhwang91 picture kevinhwang91  路  3Comments

sc0ty picture sc0ty  路  4Comments

reymonr picture reymonr  路  4Comments

nabn picture nabn  路  3Comments

atweiden picture atweiden  路  4Comments