4

I'm just wondering if something can be done with the effect presented below:

tmux

As you can see, I divided the window into 3 panes. When it comes to copying, everything is fine except double click on a word that is near the vertical border. When I try to select that word, you can see the border is also highlighted (if there were something in the left pane, for instance, a long line of text, that would also be highlighted). When I copy and paste this, it also paste a small part of the border. This applies only to the vertical lines because the horizontal one has some space. I thought of setting inner margins so that could set a small space and thus separate a text from the border, but unfortunately I have no idea how to do it if, of course, it's possible at all.

4
  • I am not sure what your terminal emulator considers "word characters," but typically the | bar symbol is not considered a word character and is excluded from selection by double clicking. In your case, it seems to be selecting everything between spaces. Is this the desired behavior? If not, perhaps your terminal emulator may have a setting to configure this. An example using x-terminal. Dec 27, 2013 at 9:02
  • It's urxvt, and in order to use double click (in tmux) I have to press Lshift first, only then I can select something using double click. This only happens when the border is near a word. When there's a word with | it wont select it. Dec 27, 2013 at 21:48
  • I'm sorry, I don't have experience with urxvt. I suggest you also post this to the tmux mailing list too. I suggest also mentioning the change in double click behavior. Dec 29, 2013 at 2:02
  • I asked about this on tmux mailing list. As you can see │ is a little bit longer that | . So I have to add the utf-8 line │ so that it won't be considered as a part of a word in my terminal. Dec 29, 2013 at 3:14

1 Answer 1

1

This thread is kind of old, but if anyone is interested, the way to fix word selection in tmux when the word is close to the border is to tell rxvt which characters to split by, e.g.

URxvt*.cutchars: "()*,;<>[]{}|`\"'#│"'`"
2
  • My urxvt (version 9.21) man page listed the default for cutchars as \\ `"'&()*,;<=>?@[]^{|}. I.e., the above doesn't include all of the defaults.
    – ntc2
    Apr 28, 2016 at 20:16
  • This one will not cut it because tmux uses a the unicode character '\xe2\x94\x82' as pane separator. Others also struggle including this character in cutchars: lists.schmorp.de/pipermail/rxvt-unicode/2014q1/001961.html
    – buherator
    Apr 11, 2018 at 8:48

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .