3

Can anyone please explain why left mouse triple-click is not selecting lines for me in urxvt ? To be specfic it sometimes works, but it depends on the nature of the text I'm selecting.

For example, if I triple-click on the output from ls -l (example below) it works as I'd expect and extends the selection to the whole line.

drwx------  2 john john 4.0K Apr 10 13:52 vFaheu1/
drwx------  2 john john 4.0K Apr  7 22:34 vgtsglC/
drwx------  2 john john 4.0K Apr 10 14:09 vKYxAOy/
drwx------  2 john john 4.0K Apr  9 15:13 vrnQIUR/

BUT if I triple-click on the output below I get different behaviour depending on where I click:

[GCC 4.8.5 20150623 (Red Hat 4.8.5-4)] on linux2

If I put the mouse locator over the e in Red hat I have to click 6 times (in close succession) to select the whole line. Here's the text I see selected after each click:

  1. no text selected
  2. Red
  3. (Red
  4. Red Hat 4.8.5-4
  5. GCC 4.8.5 20150623 (Red Hat 4.8.5-4)
  6. the whole line

Basically, it seems that rxvt is "intelligently" deciding how to extend the selection depending on the context around the text (e.g. parentheses or brackets).

I'd like to turn this feature off if possible and just have triple-click select the whole line.

I've tried the following, to no avail:

  • invoke urxvt with -pe "" to turn off perl extensions
  • +tcw & -tcw (i.e. without or with tripleclickwords)

Environment:

CentOS Linux release 7.2.1511
rxvt-unicode (urxvt) v9.21 - released: 2014-12-31
rxvt-unicode (urxvt256c) v9.21 - released: 2014-12-31
rxvt-unicode (urxvt256c) v9.21 - released: 2014-12-31
4

Fixed by disabling the selection Perl extension.

I was under the misapprehension that -pe "" would disable all extensions (I think I read this somewhere), but it doesn't.

In fact I'm not sure exactly how to disable all Perl extensions, but here's how to disable selection:

urxvt -pe "-selection"

And here's how I've done it via X resources:

URxvt.perl-ext: default,-selection

Now, triple-click always selects lines.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.