git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Pratyush Yadav <me@yadavpratyush.com>
To: Birger Skogeng Pedersen <birger.sp@gmail.com>
Cc: Git List <git@vger.kernel.org>, Johannes Sixt <j6t@kdbg.org>,
	davvid@gmail.com, Bert Wesarg <bert.wesarg@googlemail.com>
Subject: Re: [PATCH v5] git-gui: Add hotkeys to set widget focus
Date: Wed, 11 Sep 2019 23:18:13 +0530	[thread overview]
Message-ID: <20190911174813.3v2f4s7wxolkkyef@yadavpratyush.com> (raw)
In-Reply-To: <CAGr--=+9t1m-8LdVnnhkUFS0LMss0WecUjjtR=s_b98qB9qKeA@mail.gmail.com>

On 11/09/19 08:49AM, Birger Skogeng Pedersen wrote:
> Hi Pratyush,
> 
> On Tue, Sep 10, 2019 at 9:12 PM Pratyush Yadav <me@yadavpratyush.com> wrote:
> > This patch LGTM, but I'm not sure how to resolve the keybindings
> > problem. Junio suggested we have configurable keybindings, and I agree
> > with him, but until we do, something has to be agreed upon. And we also
> > need to come up with a reasonable default.
> >
> > So, I don't have any preferences for either using Alt+3 for the commit
> > message buffer, or Alt+4. Unless someone has objections, I'll go with
> > Alt+3 for the commit message buffer, and Alt+4 for the diff.
> 
> I honestly don't quite follow the argumentation to use Alt+3 for the
> commit message widget. Is Alt+4 (really) too awkward? And if it is,
> how is Alt+3 better?

It isn't really much more than personal preference.

> If you want to see it merged now (which I do, too), I propose we leave
> it at Alt+3 for the diff, and Alt+4 for the commit message buffer.

Since this entire debate essentially boils down to personal preference, 
there is no clear answer. So I'll just go with the author's 
implementation.

Do note that I fixed a small nitpick locally. Changed the subject from 
"git-gui: Add..." to "git-gui: add...".
 
> As David A. mentioned in his email[1], git-cola utilizes CTRL+J/K/L
> for navigation, maybe we should consider(?):
> Alt+i: focus unstaged
> Alt+j: focus staged
> Alt+k: focus commit widget
> Alt+l: focus diff view

David's suggestion was to try to use the vim keys, which are h,j,k,l, 
and not i,j,k,l. Also, in git-cola (I learned this from reading his 
email, I don't use git-cola myself), Ctrl+j is for focussing on the 
lower part of the UI, which is their diff viewer. j is used for moving 
down in vim. Ctrl+k focusses on the status widget, which is in the upper 
part of the UI. k is used for moving up in vim.

But we can't do something similar with git-gui. Why would Alt+k make 
more sense when bound to diff instead of the unstaged changes widget? 
Both are in the upper part of the UI. Similar argument for why Alt+j 
would make more sense bound to commit message buffer instead of the 
staged changes widget? Both are in the lower part of the UI. And you 
can't fit h or l in this similar analogy, because they don't make sense 
to me at all.

I realise that the bindings I mentioned are not what you proposed, but 
they are more in line with the vim keys.

My point being, it is not simple to bind our 4 widgets to 4 directional 
keys, unlike in git-cola where you only have an up and down.

So I don't see any reasonable bindings what would work with the 4 vim 
directional keys: h,j,k,l. Maybe I'm missing something?

-- 
Regards,
Pratyush Yadav

  reply	other threads:[~2019-09-11 17:48 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-20 13:32 git-gui, feature request: add hotkeys to focus different widgets Birger Skogeng Pedersen
2018-02-23 10:22 ` [PATCH] git-gui: Add hotkeys to change focus between ui widgets Birger Skogeng Pedersen
2018-02-23 16:42   ` Birger Skogeng Pedersen
2018-02-28 12:10 ` Birger Skogeng Pedersen
2018-03-05 16:55   ` Johannes Schindelin
2018-03-06 14:35     ` Birger Skogeng Pedersen
2018-03-06 19:28       ` Junio C Hamano
2019-08-31 12:23         ` [PATCH] git-gui: Add hotkeys to set widget focus Birger Skogeng Pedersen
2019-08-31 12:27           ` Birger Skogeng Pedersen
2019-09-01 11:32           ` Pratyush Yadav
2019-09-01 16:21             ` Junio C Hamano
2019-09-01 18:24             ` Birger Skogeng Pedersen
2019-09-01 19:01             ` Bert Wesarg
2019-09-01 19:36               ` [PATCH] " Birger Skogeng Pedersen
2019-09-02 18:19                 ` Pratyush Yadav
2019-09-02 18:35                   ` Birger Skogeng Pedersen
2019-09-02 18:53                     ` Pratyush Yadav
2019-09-02 19:05                       ` Birger Skogeng Pedersen
2019-09-02 19:42                 ` Bert Wesarg
2019-09-03 14:21                   ` Birger Skogeng Pedersen
2019-09-03 14:22                   ` Pratyush Yadav
2019-09-03 14:45                     ` [PATCH] git-gui: use path name instead of list index to track last clicked file Pratyush Yadav
2019-09-03 18:07                       ` [PATCH v4] git-gui: Add hotkeys to set widget focus Birger Skogeng Pedersen
2019-09-03 18:13                         ` Birger Skogeng Pedersen
2019-09-03 19:30                           ` Birger Skogeng Pedersen
2019-09-03 21:49                         ` Pratyush Yadav
2019-09-04 14:30                           ` [PATCH v5] " Birger Skogeng Pedersen
2019-09-04 18:59                             ` Johannes Sixt
2019-09-04 19:20                               ` Birger Skogeng Pedersen
2019-09-04 21:39                                 ` Johannes Sixt
2019-09-04 22:31                                   ` Pratyush Yadav
2019-09-04 23:38                                     ` Junio C Hamano
2019-09-05 12:33                                       ` Pratyush Yadav
2019-09-04 19:55                               ` Bert Wesarg
2019-09-04 21:45                                 ` Johannes Sixt
2019-09-10 19:12                             ` Pratyush Yadav
2019-09-11  6:49                               ` Birger Skogeng Pedersen
2019-09-11 17:48                                 ` Pratyush Yadav [this message]
2019-09-11 18:11                                   ` Johannes Sixt
2019-09-03 16:06                     ` [PATCH] [PATCH] " Bert Wesarg
2019-09-01 22:27             ` Philip Oakley
2019-09-02 12:25               ` Pratyush Yadav
2019-09-02 17:23                 ` Philip Oakley
2019-09-03 22:18                   ` Pratyush Yadav
2019-09-01 18:58           ` Bert Wesarg
2019-09-01 19:25             ` Birger Skogeng Pedersen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190911174813.3v2f4s7wxolkkyef@yadavpratyush.com \
    --to=me@yadavpratyush.com \
    --cc=bert.wesarg@googlemail.com \
    --cc=birger.sp@gmail.com \
    --cc=davvid@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=j6t@kdbg.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).