Re: [dev] st mouse support beyond column 223

From: Christoph Lohmann <20h_AT_r-36.net>
Date: Sat, 26 Jan 2013 15:14:22 +0100

Greetings.

On Sat, 26 Jan 2013 15:14:22 +0100 Egmont Koblinger <egmont_AT_gmail.com> wrote:
> Hi guys,
>
> The original mouse protocol for terminals encodes the coordinates as a
> single byte (plus 32) hence only allows coordinates up to 223.
>
> Xterm's SGR 1006 extension changes to a different format which allows
> arbitrary coordinates. This extension is getting widely adopted across
> terminals (e.g. xterm, vte, konsole, iterm2, putty...), as well as
> applications (vim, emacs...). Tmux has a patch too:
> http://sourceforge.net/p/tmux/tickets/26/?page=1
>
> Please see my patch, it adds support for this extension. Furthermore, if
> the extension is turned off, it modifies the behavior of post-223 clicks:
> it makes it report nothing rather than bogus coordinates.
>
> (To make the story more complicated, there was a first extension (1005)
> made by xterm, which is terribly broken, then a second one (1015) by urxvt,
> which is kinda okay, and this is the third one. It looks pretty much that
> this is going to be the "winning" one. For the sake of simplicity I only
> added support for this latter, but it might be very easy to support 1015
> too. On the application front, currently Midnight Commander uses this 1015
> extension, but I will ask them (send them patch) to switch to the newer
> 1006 mode. Let me know if you'd prefer to support 1006 too, it can be
> added in practically no time.)
>
> I hope you like my patch, let me know if you have any questions.

Your patch is applied. But I had to modify it because your patch is
against 0.3, but git has moved fast.

What is your test case for this? A big htop window where you click in?

Please try out if it works for you in the latest st from the git reposiā€
tory.


Sincerely,

Christoph Lohmann
Received on Sat Jan 26 2013 - 15:14:22 CET

This archive was generated by hypermail 2.3.0 : Sat Jan 26 2013 - 15:24:07 CET