Re: [PATCH] Allow custom key tables for e.g. multiple keystroke?bindings.

2015-04-20 Thread Nicholas Marriott
I applied this to OpenBSD now; it'll be in SF later sometime. On Mon, Apr 13, 2015 at 03:21:52PM +, Ross Hadden wrote: > Keith Amling palantir.com> writes: > > > > > > > > Or are you thinking of creating the table after running the set > command? > > > > > This shouldn't work - you should

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke?bindings.

2015-04-20 Thread Ross Hadden
Would you mind making a merge request for it? I could, but it wouldn't really be right to make a merge request with someone else's hard work! Your name should be on this. Thanks, ~Ross On Mon, Apr 13, 2015 at 5:30 PM Nicholas Marriott < nicholas.marri...@gmail.com> wrote: > Here's the latest d

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke?bindings.

2015-04-19 Thread Nicholas Marriott
It needs a bit of love again after the mouse keys stuff that just went in so it may not be for a while... On Sun, Apr 19, 2015 at 10:45:38PM +0100, Nicholas Marriott wrote: > We don't need a merge request, I'll commit it when I'm happy with it. Thanks > > > On Sun, Apr 19, 2015 at 06:49:30PM +0

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke?bindings.

2015-04-19 Thread Nicholas Marriott
We don't need a merge request, I'll commit it when I'm happy with it. Thanks On Sun, Apr 19, 2015 at 06:49:30PM +, Ross Hadden wrote: >Would you mind making a merge request for it?** I could, but it wouldn't >really be right to make a merge request with someone else's hard work!** >

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke?bindings.

2015-04-13 Thread Nicholas Marriott
Here's the latest diff. It actually seems to work fine, although I haven't done a lot of testing. IIRC I wasn't wild about the cmd-list-keys.c and cmd-bind-key.c changes; certainly lsk -T should error on an unknown table, same as bind -T. I think the manpage bits could do with some improvement to

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2015-04-13 Thread Nicholas Marriott
riginal message From: Ross Hadden Date:13/04/2015 16:21 (GMT+00:00) To: tmux-users@lists.sourceforge.net Subject: Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings. Keith Amling palantir.com> writes: > > > > > Or are you thi

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2015-04-13 Thread Ross Hadden
Keith Amling palantir.com> writes: > > > > > Or are you thinking of creating the table after running the set command? > > > > This shouldn't work - you shouldn't be able to set a client to a > > > > nonexistent table. > > > > > > I guess I don't super care what happens since I won't personally

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-14 Thread Keith Amling
> > > Or are you thinking of creating the table after running the set command? > > > This shouldn't work - you shouldn't be able to set a client to a > > > nonexistent table. > > > > I guess I don't super care what happens since I won't personally be > > writing any switch-client -T into an empty

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-14 Thread Keith Amling
Uh, as you wish although I'm not sure I understand the subtext. Just for my curiosity is it just that you prefer "for (;;)"? Keith Thus spake Nicholas Marriott, at Tue, May 13, 2014 at 02:04:42AM +0100: > Date: Tue, 13 May 2014 02:04:42 +0100 > From: Nicholas Marriott > To: Ke

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-14 Thread Keith Amling
> > Well, I agree it needs to be destroyed eventually but the issue is that > > if a user thinks of the client as being set to [read from] a keytable > > with a name then they will likely think binding a key into a keytable of > > that name will be the same table even if the bind happens after the

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-14 Thread Keith Amling
The various things I didn't quote are all straight-forward and will be my pleasure to fix. > I don't think it'd be that much compatibility code. > > We could just maintain a flag for the "option-set" prefix in the root > table, and that can be used for prefix/send-prefix. The root table can > nev

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-13 Thread Nicholas Marriott
On Tue, May 13, 2014 at 03:42:05PM -0700, Keith Amling wrote: > > > Well, I agree it needs to be destroyed eventually but the issue is that > > > if a user thinks of the client as being set to [read from] a keytable > > > with a name then they will likely think binding a key into a keytable of > >

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-13 Thread Nicholas Marriott
Hi On Tue, May 13, 2014 at 01:41:07PM -0700, Keith Amling wrote: > The various things I didn't quote are all straight-forward and will be > my pleasure to fix. > > > I don't think it'd be that much compatibility code. > > > > We could just maintain a flag for the "option-set" prefix in the root

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-13 Thread Nicholas Marriott
ted, things like "bind x bind x lsk" would cause a use-after-free. > > > - You will save me a little time if you use "for (;;)" instead of "while > > (1)". > > Uh, as you wish although I'm not sure I understand the subtext. Just > for my

Re: [PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-12 Thread Nicholas Marriott
Thanks - I think this is the right idea, but not quite there. There should be no need for a prefix key anymore. Instead, the default root table should have a binding for C-b to change the key table. That way the prefix table is not special, the only special table is the root table. (Although we'

[PATCH] Allow custom key tables for e.g. multiple keystroke bindings.

2014-05-12 Thread Keith Amling
Sorry if this isn't formatted as expected, I'm not at all familiar with the operation of git's e-mail tools. Keith --- Makefile.am| 1 + cmd-bind-key.c | 52 - cmd-list-keys.c| 80 +++--- cmd-set-keytable.c | 44 +++