File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ ---
2+ title : Transient help popup
3+ weight : -30
4+ ---
5+
6+ A transient is a text pop-up window, displaying at the bottom of the
7+ screen, that shows keybindings and their associated commands.
8+
9+ The pop-up can stay in place when the user presses a key, which allows
10+ to always show help on-screen.
11+
12+ ## Simple example
13+
14+ ``` lisp
15+ (define-command example-command () ()
16+ (message "example message"))
17+
18+ (lem/transient:define-transient *demo-keymap-simple*
19+ :description "my demo keymap"
20+ (:key "a" :suffix 'example-command :description "demo prefix 1")
21+ (:key "b" :suffix 'example-command :description "demo prefix 2" :active-p nil))
22+
23+ (define-key *global-keymap* "C-c t" *demo-keymap-simple*)
24+ ```
25+
26+ <div style =" text-align : center ;" > <img src =" https://raw.githubusercontent.com/lem-project/lem/main/extensions/transient/transient-simple.png " /> </div >
27+
28+ ## Show all current keybindings
29+
30+ Setting ` lem/transient:*transient-always-show* ` to ` t ` makes it show
31+ all available keybindings for the current mode(s):
32+
33+ ``` lisp
34+ (setf lem/transient::*transient-always-show* t)
35+ ```
36+
37+ <div style =" text-align : center ;" > <img src =" https://raw.githubusercontent.com/lem-project/lem/main/extensions/transient/transient-simple.png " /> </div >
You can’t perform that action at this time.
0 commit comments