[ZeroBrane Studio] Re: Copy/move line keyboard shortcuts

  • From: Paul K <paul@xxxxxxxxxxxxx>
  • To: "zerobrane@xxxxxxxxxxxxx" <zerobrane@xxxxxxxxxxxxx>
  • Date: Mon, 27 Oct 2014 22:22:52 -0700

Hi Albert-Jan,

> It may be worth a mention there that the key modifiers can be combined with + 
> (probably bit-wise-or would be more accurate, but Lua does not have it).

Good point; I'll add that.

> Feature request: allow, in addition to a single keyboard command, a table 
> containing a sequence of keyboard commands to be bound to a key.

It's not possible for editor key mapping as it's fully handled by
Scintilla; I've been thinking about adding this for global/menu
shortcuts, but there are two issues: (1) it's not easy to do this
without global key even handlers and they work slightly differently
across platforms and with different widgets, and (2) the
discoverability is bad as I can't add something like "Ctrl-K, K" to
the menu (it works on Windows, but not on OSX). As one option I
considering opening a pop-up menu after the first combination (for
example, Ctrl-K), showing the available options and the associated
command (even if there is only one), but there were still challenges
with that approach.

As the result, I decided against spending time on this for now.
Patches welcome though if someone can overcome those issues ;). There
may need to be changes done to ZBS API to handle AcceleratorTable
updates to support this, but I'm okay with making those changes as
long as this approach can be shown to work.

Paul.

Other related posts: