Re: Keyboard Shortcuts in 1.8.3



On 25 December 2013 22:02, Yuri Astrakhan <yastrakhan wikimedia org> wrote:
Hi, I recently started using meld (amazing, thanks!), migrating from
WinMerge, but noticed that the documentation page misses tons of the
shortcuts (I stumbled upon some of them in the Changes menu.

Yeah the shortcuts page is definitely not complete. We could probably
just auto-generate it, but in the meantime I'll happily apply patches
for anything important that you think is missing.

I would like to discuss a few issues I noticed, but since I am coming from
WinMerge, please take them with a grain of salt:

* Ctrl+Escape for cycle through documents is a reserved shortcut in windows
(start menu), so it doesn't work.

* There is no shortcut for switching cursor between panes (or at least its
not documented/not in the menu) - F6 in Winmerge.

Unless you mean something different, these are the same problem. I had
no idea that Windows reserved Ctrl+Escape, so I think we should just
fix this by changing the shortcut. A simple alternative would be Ctrl
+ `, or more interestingly the GNOME-ish Ctrl + <whatever is above Tab
on your keyboard>.

Another option would be to come up with something totally different to
do pane cycling. It's hard to come up with easy keyboard shortcuts
that don't conflict with anything predefined...

Either way, could I ask you file a bug for this?

* The behavior of alt+left/right, alt+shift+left/right, and alt+delete IMHO
seems a bit over-complicated -- when comparing two files, i think WinMerge
model is much simpler - alt+up/down selects the change (same in Meld),
alt+left/right copies the change from left to right (alt+right), or
right->left (alt+left). The "change" in this case could be both copying if
text is different, or deleting/inserting  - if there are lines only on one
of the sides. This operation is consistent regardless of which side has the
cursor, thus greatly simplifying the thought process.

For example, having these shortcuts would allow someone to quickly copy
changes from left to right by simply holding down alt  and hitting down,
right, down, right, down down down right (copied 1st, 2nd, and 5th change).

With the current shortcut model, this is severely limited -- I can only do
it if the cursor is in the left pane (being in the right pane confusingly
changes the shortcuts to alt+shift+right), and it will not work at all if
the right pane has extra text that wasn't in the left - i must be ONLY in
the right pane and use a different shortcut alt+delete. Hence, lots of extra
thoughts that get in the way of quickly merging a file.

So I agree with you on some of this, but other bits I don't think are
workable. One of the biggest considerations here is that any shortcut
scheme must work for *both* two and three-way comparison. I think this
pretty much eliminates your idea of allowing Alt+Left/Right actually
pulling changes like Alt+Shift+Left/Right currently do. I can't think
of a way to make that work consistently across different comparions
types.

On the other hand, I agree that having to switch panes in order to
push a delete is a pain... for two-pane comparisons it would be nice
if you almost never had to switch panes, and we break that.

I haven't tried it, but my suggestion based on your idea is that we
could just change the behaviour of Alt+L/R and Alt+Shift+L/R to also
push/pull chunk deletions. In this case you still need to know what
pane you're in, but you should rarely need to change panes (unless
you're copying or changing chunks rather than just push/pull/delete).

Does this sound like it would fix your use case?

cheers,
Kai


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]