1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-03-03 04:21:28 -08:00
Commit graph

453 commits

Author SHA1 Message Date
justbur
e7a9ebf15f Refactor create-pages and show-page 2016-02-03 15:14:26 -05:00
justbur
a87e6212f8 Improve some function names 2016-02-03 15:13:24 -05:00
justbur
d24c12f563 Don't pass window-width around 2016-02-03 12:40:35 -05:00
justbur
e1f2e6be99 Fix problems with operator keymap function
1. Introduce using-show-keymap and using-show-operator-keymap vars to
make it clear how we are entering which-key

2. Add inhibit-next-operator-keymap for keys in the operator maps that
are bound to commands that read the next key "manually"

3. Fix problem where the next page hint was only being shown sometimes
in the operator maps. Need to distinguish between show-operator-keymap
and the possibility that an operator is active but the usual which-key
popup is showing.
2016-02-03 08:27:40 -05:00
justbur
dce72aa134 Simplify page turning function 2016-02-03 08:24:54 -05:00
justbur
f6f4aee340 Use keyboard-quit in abort key sequence
Need to do this for the operator keymap function. Otherwise the operator
state doesn't exit properly
2016-02-03 08:23:55 -05:00
justbur
6ddebba30c Comment out window var and add new func
The window var is not being used.
2016-02-03 08:22:53 -05:00
justbur
094136858f Don't listify key sequence repeatedly
This function is not idempotent it turns out.
2016-01-29 21:08:12 -05:00
justbur
9c93581566 Interpret ESC in operator popup
See #99
2016-01-29 20:41:15 -05:00
justbur
d9bb55cd00 Improve previous commit
Filter out keys with :suppress-keymap property, which seem to be the
primary ones ignored in operator state
2016-01-28 15:42:33 -05:00
justbur
456053cd70 Merge branch 'master' of https://github.com/justbur/emacs-which-key 2016-01-28 15:04:05 -05:00
justbur
f3681e93c5 Initial try at addressing #99 2016-01-28 15:03:27 -05:00
Justin Burkett
f69f694d8a Merge pull request #100 from yatesco/patch-1
Trivial fix correcting SpacEmacs
2016-01-26 07:55:58 -05:00
Colin Yates
5909fb2fc3 Trivial fix correcting SpacEmacs 2016-01-26 12:47:58 +00:00
justbur
f1d3d1b5e5 Add which-key-idle-secondary-delay
Allows the delay time to be different for popups that follow an initial
popup within the same key sequence.
2016-01-17 20:57:44 -05:00
justbur
9bb70c8cdd Fix problem with side-window dimension calculation
The fringes were not being included in version 24. This makes the
calculation consistent with the left/right side-window calculation and
fixes #97.
2016-01-11 09:56:49 -05:00
justbur
f4a1b4283b Fix C-h prompt for show-keymap commands 2015-12-21 12:12:29 -05:00
justbur
92dc5871f0 Fix undo for show-keymap 2015-12-20 19:43:16 -05:00
justbur
c1e82229ad Distinguish using-show-keymap 2015-12-20 17:18:22 -05:00
justbur
38811018fb Allow traversal of keymaps in new commands 2015-12-20 15:54:53 -05:00
justbur
aa06530d06 Filter out empty keymaps in new functions 2015-12-20 15:38:38 -05:00
justbur
6702c2ed98 Add which-key-show-minor-mode-keymap
Version of which-key-show-keymap that only looks in minor-mode-map-alist
2015-12-20 15:31:57 -05:00
justbur
4a10ab2128 Add which-key-show-keymap
Basic version of this command that only shows the top-level of a keymap.
Waiting for feedback on how this should work.
2015-12-20 13:19:16 -05:00
justbur
ad60a6c720 New stable version 2015-12-17 09:27:22 -05:00
justbur
14a11c6d69 Ignore evil-state bindings
These are the fake keys that evil uses to store maps under
2015-12-11 15:29:59 -05:00
justbur
2932f8a353 Merge branch 'master' of https://github.com/justbur/emacs-which-key 2015-12-10 20:03:48 -05:00
justbur
47ef300b85 Add which-key-init-buffer-hook 2015-12-10 20:02:58 -05:00
Justin Burkett
8ff27a120f Merge pull request #91 from Amorymeltzer/prefix-prefix-doc
Document which-key-prefix-prefix
2015-12-09 16:23:48 -05:00
Amory Meltzer
06c312b4d5 Document which-key-prefix-prefix
30bc0c224b
2015-12-09 13:19:23 -08:00
justbur
30bc0c224b Allow custom prefix-prefix
Suggested in #90. Thanks @Amorymeltzer
2015-12-08 20:24:23 -05:00
justbur
37f28136dd Tweak display of key sequence in one case
This is for the C-h commands when the which-key message is not shown in
the echo area but the echo-keystrokes prefix is
2015-12-06 13:29:25 -05:00
justbur
dd77323e9e echo-keystrokes should never be nil
The correct test is to test if it's 0.
2015-12-06 13:16:05 -05:00
justbur
583416fda4 Preserve prefx-arg when paging 2015-12-05 12:37:29 -05:00
justbur
0e87f61d72 Work on handling prefix args better 2015-12-04 15:34:17 -05:00
justbur
b3b41792e8 Make C-h command hint respect C-h-map commands 2015-12-04 14:21:17 -05:00
justbur
2c5bb54b58 Merge branch 'master' of https://github.com/justbur/emacs-which-key 2015-12-03 20:51:52 -05:00
justbur
4fb75fa6ef Don't abort key seq after unbound key in C-h-map
Allows to recover from accidentally pressing C-h.

This commit also fixes some echo area problems that become apprent after
introducing the C-h-map stuff
2015-12-03 20:49:43 -05:00
Justin Burkett
baee0db96e Clarify C-h commands description in readme 2015-12-03 12:10:47 -05:00
justbur
318f9de6a9 Fix top-level note and satisfy compiler 2015-12-03 11:15:19 -05:00
justbur
388c00736a Add C-h commands to what's new in readme
Still need to update the rest of the content
2015-12-03 08:44:14 -05:00
justbur
5ebbe69cfb Fix note on right and add abort keys 2015-12-03 08:36:13 -05:00
justbur
9846929ddf Fix undo and timer usage 2015-12-03 08:10:50 -05:00
justbur
b5ec6f8f8d Introduce C-h command dispatch function
Replace role of show-next-page with C-h-dispatch which immediately reads
a key and calls a command from C-h-map, which may be one of several
paging commands, a command to undo the last keypress, or a command to
directly access describe-prefix-bindings.

This commit does not include documenting these changes in the readme.

Note that several options become deprecated here as they no longer have
the same (if any effect).
2015-12-02 22:42:02 -05:00
justbur
3327e9cdf2 Remove dependencies from README 2015-12-01 11:53:02 -05:00
justbur
db97a29be5 Cleanup make-text-button call 2015-11-30 20:58:48 -05:00
justbur
7a30f4d443 Fix return value problem for make-text-button
Apparently in versions before 24.5 the return value was not always the
button itself when a string was used as the argument
2015-11-30 18:43:09 -05:00
justbur
d4b4bad88a Merge branch 'grammati' 2015-11-30 13:47:27 -05:00
justbur
70a4716879 Use safe version of string-width 2015-11-30 13:30:37 -05:00
justbur
2f4c5d8609 Use key-description for canonical keys
This takes the idea in the previous commit and translates the
representations of keys in the alists to be the output of
key-description. The issue is that `M-x` for example has two
representations with listify-key-sequence, but only one (it seems) from
key-description.
2015-11-30 11:23:50 -05:00
Chris Perkins
ead6b70fd0 Display prefix names in terminal-mode
When running emacs in a terminal (or at least, in iTerm), keys are not
passed through to emacs the same way that they are in graphical mode.

For example, M-m (important in spacemacs) is the key-sequence
`[134217837]` in graphical emacs, but `[27 109]` ("ESC m") in terminal.

The variable `which-key-prefix-name-alst` only has a mapping for the
former (the 134217837), and so the names of submenus all show up as
"+prefix", limiting discoverability.

This commit converts the key sequence into a canonical form (eg:
converts `[27 109]` into `[134217837]`) in
`which-key--maybe-replace-prefix-name`, so that the prefixes are found.

I think some work is probably needed for
`which-key-prefix-title-alist` too, but I'm not entirely sure what
that's used for, so I didn't mess with it.
2015-11-28 11:15:21 -07:00