* Which modifier to use?
@ 2020-12-05 11:28 Jean Louis
2020-12-05 11:48 ` Christopher Dimech
` (5 more replies)
0 siblings, 6 replies; 22+ messages in thread
From: Jean Louis @ 2020-12-05 11:28 UTC (permalink / raw)
To: Help GNU Emacs
I have too many keys on Hyper modifier and need a keys for many
functions. Emacs is mostly not modal and I am not using viper mode,
but as modal it would offer me quick access to key bindings such as:
- / a
- / s
Maybe CapsLk can be used as modifier or prefix key?
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 11:28 Which modifier to use? Jean Louis
@ 2020-12-05 11:48 ` Christopher Dimech
2020-12-05 12:55 ` Jean Louis
2020-12-05 12:25 ` Stefan Möding
` (4 subsequent siblings)
5 siblings, 1 reply; 22+ messages in thread
From: Christopher Dimech @ 2020-12-05 11:48 UTC (permalink / raw)
To: Jean Louis; +Cc: Help GNU Emacs
Or define the Super Key
> Sent: Saturday, December 05, 2020 at 12:28 PM
> From: "Jean Louis" <bugs@gnu.support>
> To: "Help GNU Emacs" <help-gnu-emacs@gnu.org>
> Subject: Which modifier to use?
>
> I have too many keys on Hyper modifier and need a keys for many
> functions. Emacs is mostly not modal and I am not using viper mode,
> but as modal it would offer me quick access to key bindings such as:
>
> - / a
> - / s
>
> Maybe CapsLk can be used as modifier or prefix key?
>
>
>
>
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 11:48 ` Christopher Dimech
@ 2020-12-05 12:55 ` Jean Louis
2020-12-05 15:03 ` Arthur Miller
0 siblings, 1 reply; 22+ messages in thread
From: Jean Louis @ 2020-12-05 12:55 UTC (permalink / raw)
To: Christopher Dimech; +Cc: Help GNU Emacs
* Christopher Dimech <dimech@gmx.com> [2020-12-05 14:48]:
> Or define the Super Key
I use too much Super key and it is not as convenient. For example I
cannot use upper case letters with super key. It would give me bunch
of new keys.
I do use it also in combination with Ctrl and Meta (Alt). That is one
great key for users to define their own key bindings.
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 12:55 ` Jean Louis
@ 2020-12-05 15:03 ` Arthur Miller
2020-12-05 17:55 ` Jean Louis
2020-12-05 21:29 ` TRS-80
0 siblings, 2 replies; 22+ messages in thread
From: Arthur Miller @ 2020-12-05 15:03 UTC (permalink / raw)
To: Jean Louis; +Cc: Christopher Dimech, Help GNU Emacs
Jean Louis <bugs@gnu.support> writes:
> * Christopher Dimech <dimech@gmx.com> [2020-12-05 14:48]:
>> Or define the Super Key
>
> I use too much Super key and it is not as convenient. For example I
> cannot use upper case letters with super key. It would give me bunch
> of new keys.
>
> I do use it also in combination with Ctrl and Meta (Alt). That is one
> great key for users to define their own key bindings.
I leave Super to my window manager and xbindkeys; and all other
modifiers go to applications. It is a rule. Makes life easier if you
switch between Windows and GNU/Linux as I did before when I consulted
and had to work with customers. I had same bindings in Emacs in both
OS:s. If I used Super, I would have to remap in Windows.
Pssst: Posted by u/ugurbolat 20 hours ago <-- Was that you? Feels like I
am answering same question in two different places :-).
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 15:03 ` Arthur Miller
@ 2020-12-05 17:55 ` Jean Louis
2020-12-05 21:29 ` TRS-80
1 sibling, 0 replies; 22+ messages in thread
From: Jean Louis @ 2020-12-05 17:55 UTC (permalink / raw)
To: Arthur Miller; +Cc: Christopher Dimech, Help GNU Emacs
* Arthur Miller <arthur.miller@live.com> [2020-12-05 18:32]:
> Jean Louis <bugs@gnu.support> writes:
>
> > * Christopher Dimech <dimech@gmx.com> [2020-12-05 14:48]:
> >> Or define the Super Key
> >
> > I use too much Super key and it is not as convenient. For example I
> > cannot use upper case letters with super key. It would give me bunch
> > of new keys.
> >
> > I do use it also in combination with Ctrl and Meta (Alt). That is one
> > great key for users to define their own key bindings.
> I leave Super to my window manager and xbindkeys; and all other
> modifiers go to applications. It is a rule. Makes life easier if you
> switch between Windows and GNU/Linux as I did before when I consulted
> and had to work with customers. I had same bindings in Emacs in both
> OS:s. If I used Super, I would have to remap in Windows.
>
> Pssst: Posted by u/ugurbolat 20 hours ago <-- Was that you? Feels like I
> am answering same question in two different places :-).
I am not that one.
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 15:03 ` Arthur Miller
2020-12-05 17:55 ` Jean Louis
@ 2020-12-05 21:29 ` TRS-80
2020-12-06 5:40 ` Jean Louis
1 sibling, 1 reply; 22+ messages in thread
From: TRS-80 @ 2020-12-05 21:29 UTC (permalink / raw)
To: help-gnu-emacs
> On 2020-12-05 10:03, Arthur Miller wrote:
>
> I leave Super to my window manager and xbindkeys; and all other
> modifiers go to applications. It is a rule. Makes life easier if you
> switch between Windows and GNU/Linux
Luckily I can avoid Windoze nearly 100% of the time nowadays, however I
still follow this rule and think it's a great idea, anyway.
I use i3 (wm) and have lots of custom keybindings at the OS/WM level,
they are all based on using Super as modifier. So, in my mind, Super
(aka "Win") has to do with window manager.
Inside Emacs, I also group related keybindings behind a sort of "leader"
key, for example (dk here is alias for define-key, stricty to shorten
these lines so I can keep nice formatting):
(dk global-map (kbd "C-c y") '("Yankpad" . nil))
(dk global-map (kbd "C-c y c") '("Capture" .
yankpad-capture-snippet))
(dk global-map (kbd "C-c y e") '("Edit" .
yankpad-edit))
(dk global-map (kbd "C-c y i") '("Insert" .
yankpad-insert))
(dk global-map (kbd "C-c y r") '("Reload" .
yankpad-reload))
(dk global-map (kbd "C-c y R") '("Repeat" .
yankpad-repeat))
(dk global-map (kbd "C-c y s") '("Set (local) category" .
yankpad-set-local-category))
(dk global-map (kbd "C-c y S") '("Set (global) category" .
yankpad-set-category))
I think it is little known that you can define keys in this way, I
learned it while setting up which-key. If you use that package, the car
of the alist will appear as the description, allowing you to create sort
of poor man's menu system. :)
Cheers,
TRS-80
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 21:29 ` TRS-80
@ 2020-12-06 5:40 ` Jean Louis
0 siblings, 0 replies; 22+ messages in thread
From: Jean Louis @ 2020-12-06 5:40 UTC (permalink / raw)
To: TRS-80; +Cc: help-gnu-emacs
* TRS-80 <lists.trs-80@isnotmyreal.name> [2020-12-06 00:30]:
> > On 2020-12-05 10:03, Arthur Miller wrote:
> >
> > I leave Super to my window manager and xbindkeys; and all other
> > modifiers go to applications. It is a rule. Makes life easier if you
> > switch between Windows and GNU/Linux
>
> Luckily I can avoid Windoze nearly 100% of the time nowadays, however I
> still follow this rule and think it's a great idea, anyway.
>
> I use i3 (wm) and have lots of custom keybindings at the OS/WM level,
> they are all based on using Super as modifier. So, in my mind, Super
> (aka "Win") has to do with window manager.
>
> Inside Emacs, I also group related keybindings behind a sort of "leader"
> key, for example (dk here is alias for define-key, stricty to shorten
> these lines so I can keep nice formatting):
>
> (dk global-map (kbd "C-c y") '("Yankpad" . nil))
> (dk global-map (kbd "C-c y c") '("Capture" .
I see it is better to describe keys.
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 11:28 Which modifier to use? Jean Louis
2020-12-05 11:48 ` Christopher Dimech
@ 2020-12-05 12:25 ` Stefan Möding
2020-12-05 12:59 ` Jean Louis
2020-12-05 14:55 ` Arthur Miller
` (3 subsequent siblings)
5 siblings, 1 reply; 22+ messages in thread
From: Stefan Möding @ 2020-12-05 12:25 UTC (permalink / raw)
To: help-gnu-emacs
Jean Louis <bugs@gnu.support> writes:
> I have too many keys on Hyper modifier and need a keys for many
> functions. Emacs is mostly not modal and I am not using viper mode,
> but as modal it would offer me quick access to key bindings such as:
> - / a
> - / s
> Maybe CapsLk can be used as modifier or prefix key?
I’m using a keybinding to switch to a new keymap which has many additional
commands (Sorry for not being able to give credit for the original code):
;; launch command keymap
(define-prefix-command 'stm-launcher-map)
(global-set-key (kbd "C-x l") 'stm-launcher-map)
(define-key stm-launcher-map (kbd "=") #'ipcalc-at-point)
(define-key stm-launcher-map (kbd "#") #'generate-password)
(define-key stm-launcher-map (kbd "c") #'calendar)
(define-key stm-launcher-map (kbd "d") #'ediff-buffers)
(define-key stm-launcher-map (kbd "g") #'lgrep)
(define-key stm-launcher-map (kbd "m") #'man)
(define-key stm-launcher-map (kbd "n") #'gnus)
I can press "C-x l n" to open Gnus from everywhere.
Is this what you want?
--
Stefan
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 12:25 ` Stefan Möding
@ 2020-12-05 12:59 ` Jean Louis
2020-12-05 15:52 ` Drew Adams
0 siblings, 1 reply; 22+ messages in thread
From: Jean Louis @ 2020-12-05 12:59 UTC (permalink / raw)
To: Stefan Möding; +Cc: help-gnu-emacs
* Stefan Möding <s.moeding@gmail.com> [2020-12-05 15:26]:
> I’m using a keybinding to switch to a new keymap which has many additional
> commands (Sorry for not being able to give credit for the original code):
>
> ;; launch command keymap
> (define-prefix-command 'stm-launcher-map)
>
> (global-set-key (kbd "s-z") 'stm-launcher-map)
Thank you. This is good and useful tip. Then I could do s-z for new
map and get plethora of other keys. I did not know it works that way
nicely.
> (define-key stm-launcher-map (kbd "=") #'ipcalc-at-point)
> (define-key stm-launcher-map (kbd "#") #'generate-password)
> (define-key stm-launcher-map (kbd "c") #'calendar)
> (define-key stm-launcher-map (kbd "d") #'ediff-buffers)
> (define-key stm-launcher-map (kbd "g") #'lgrep)
> (define-key stm-launcher-map (kbd "m") #'man)
> (define-key stm-launcher-map (kbd "n") #'gnus)
^ permalink raw reply [flat|nested] 22+ messages in thread
* RE: Which modifier to use?
2020-12-05 12:59 ` Jean Louis
@ 2020-12-05 15:52 ` Drew Adams
2020-12-05 16:08 ` Arthur Miller
2020-12-05 18:01 ` Jean Louis
0 siblings, 2 replies; 22+ messages in thread
From: Drew Adams @ 2020-12-05 15:52 UTC (permalink / raw)
To: Jean Louis, Stefan Möding; +Cc: help-gnu-emacs
> > (define-prefix-command 'stm-launcher-map)
> > (global-set-key (kbd "s-z") 'stm-launcher-map)
>
> Thank you. This is good and useful tip. Then I could do s-z for new
> map and get plethora of other keys. I did not know it works that way
> nicely.
>
> > (define-key stm-launcher-map (kbd "=") #'ipcalc-at-point)
...
In that case, you asked the wrong question.
That answer, which I guess is what you were
really looking for, is about using a _prefix
key_, not a modifier key. Completely
different animal.
___
And yes, prefix keys are wonderful. When
bound to keymaps they also let you easily move
whole sets of commands/keys around as units.
E.g.: A library can identify a set of commands
that belong together in UI terms, by putting
them on a keymap. And it can put that keymap
(optionally, i.e., under user control) on a
given prefix key by default. But a user can
easily move that whole set of commands and
their bindings from the default prefix key to
another prefix key.
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 15:52 ` Drew Adams
@ 2020-12-05 16:08 ` Arthur Miller
2020-12-05 18:01 ` Jean Louis
1 sibling, 0 replies; 22+ messages in thread
From: Arthur Miller @ 2020-12-05 16:08 UTC (permalink / raw)
To: Drew Adams; +Cc: Stefan Möding, help-gnu-emacs, Jean Louis
Drew Adams <drew.adams@oracle.com> writes:
> In that case, you asked the wrong question.
> That answer, which I guess is what you were
> really looking for, is about using a _prefix
> key_, not a modifier key. Completely
> different animal.
> ___
I don't think he asked the wrong question.
I understood implicitly he is asking how to "relieve" his Super key.
He was looking for "a solution", not "the solution"; so he couldn't
expressed himself in exactly precise terms either.
> And yes, prefix keys are wonderful. When
> bound to keymaps they also let you easily move
> whole sets of commands/keys around as units.
> E.g.: A library can identify a set of commands
> that belong together in UI terms, by putting
> them on a keymap. And it can put that keymap
> (optionally, i.e., under user control) on a
> given prefix key by default. But a user can
> easily move that whole set of commands and
> their bindings from the default prefix key to
> another prefix key.
Indeed, remapping keys is a very nice feature!
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 15:52 ` Drew Adams
2020-12-05 16:08 ` Arthur Miller
@ 2020-12-05 18:01 ` Jean Louis
1 sibling, 0 replies; 22+ messages in thread
From: Jean Louis @ 2020-12-05 18:01 UTC (permalink / raw)
To: Drew Adams; +Cc: Stefan Möding, help-gnu-emacs
* Drew Adams <drew.adams@oracle.com> [2020-12-05 18:53]:
> > > (define-prefix-command 'stm-launcher-map)
> > > (global-set-key (kbd "s-z") 'stm-launcher-map)
> >
> > Thank you. This is good and useful tip. Then I could do s-z for new
> > map and get plethora of other keys. I did not know it works that way
> > nicely.
> >
> > > (define-key stm-launcher-map (kbd "=") #'ipcalc-at-point)
> ...
>
> In that case, you asked the wrong question.
> That answer, which I guess is what you were
> really looking for, is about using a _prefix
> key_, not a modifier key. Completely
> different animal.
I am looking for shortest keys. If prefix or not I do not mind. Prefix
seem more useful as I have many functions that would not fit onto
keyboard. There are functions for people that are maybe 30-50 and I
wish to put it logically. So while modifier is more useful and
shorter, practically I have not get enough modifiers for all functions.
> And yes, prefix keys are wonderful. When
> bound to keymaps they also let you easily move
> whole sets of commands/keys around as units.
>
> E.g.: A library can identify a set of commands
> that belong together in UI terms, by putting
> them on a keymap. And it can put that keymap
> (optionally, i.e., under user control) on a
> given prefix key by default. But a user can
> easily move that whole set of commands and
> their bindings from the default prefix key to
> another prefix key.
That is good point for me to follow.
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 11:28 Which modifier to use? Jean Louis
2020-12-05 11:48 ` Christopher Dimech
2020-12-05 12:25 ` Stefan Möding
@ 2020-12-05 14:55 ` Arthur Miller
2020-12-05 17:54 ` Jean Louis
2020-12-06 9:14 ` Marcin Borkowski
` (2 subsequent siblings)
5 siblings, 1 reply; 22+ messages in thread
From: Arthur Miller @ 2020-12-05 14:55 UTC (permalink / raw)
To: Jean Louis; +Cc: Help GNU Emacs
Jean Louis <bugs@gnu.support> writes:
> I have too many keys on Hyper modifier and need a keys for many
> functions. Emacs is mostly not modal and I am not using viper mode,
> but as modal it would offer me quick access to key bindings such as:
>
> - / a
> - / s
>
> Maybe CapsLk can be used as modifier or prefix key?
Have you considering using your own prefix?
I am using C-z C-v and C-f as prefixes
(C-f is a bit questionable :-)):
(define-prefix-command 'C-z-map)
(global-set-key (kbd "C-z") 'C-z-map)
(define-prefix-command 'C-f-map)
(global-set-key (kbd "C-f") 'C-f-map)
(global-unset-key (kbd "C-v")
That gives me like 3 keyboards of extra keybindings to use, so I can
have my own bindings like this:
(with-hook after-init
(with-key-map global
("M-x" . helm-M-x)
("C-x C-b" . helm-buffers-list)
("C-z a" . helm-ag)
("C-z b" . helm-filtered-bookmarks)
("C-z c" . helm-company)
("C-z d" . helm-dabbrev)
("C-z e" . helm-calcul-expression)
("C-z g" . helm-google-suggest)
("C-z h" . helm-descbinds)
("C-z i" . helm-imenu-anywhere)
("C-z k" . helm-show-kill-ring)
("C-z f" . helm-find-files)
("C-z m" . helm-mini)
("C-z o" . helm-occur)
("C-z p" . helm-browse-project)
("C-z q" . helm-apropos)
("C-z r" . helm-recentf)
("C-z s" . helm-swoop)
("C-z C-c" . helm-colors)
("C-z x" . helm-M-x)
("C-z y" . helm-yas-complete)
("C-z C-g" . helm-ls-git-ls)
("C-z SPC" . helm-all-mark-rings)))
(with-key-map global
;; Window-buffer operations
([f1] . term-toggle)
([f2] . term-toggle-eshell)
([f9] . ispell-word)
([S-f10] . next-buffer)
([f10] . previous-buffer)
([f12] . kill-buffer-but-not-some)
([M-f12] . kill-buffer-other-window)
([C-M-f12] . only-current-buffer)
;; Emacs windows
("C-v <left>" . windmove-left)
("C-v <right>" . windmove-right)
("C-v <up>" . windmove-up)
("C-v <down>" . windmove-down)
("C-v o" . other-window)
("C-v s" . z-swap-windows)
("C-v l" . windmove-left)
("C-v r" . windmove-right)
("C-v u" . windmove-up)
("C-v d" . windmove-down)
("C-v C-+" . enlarge-window-horizontally)
("C-v C-," . enlarge-window-vertically)
("C-v C--" . shrink-window-horizontally)
("C-v C-." . shrink-window-vertically)
("C-v -" . winner-undo)
("C-v +" . winner-redo)
("C-v C-k" . delete-window)
("C-v C-l" . kill-window-left)
("C-v C-r" . kill-window-right)
("C-v C-a" . kill-window-above)
("C-v C-b" . kill-window-below)
("C-v <return>" . delete-other-windows)
("C-v ," . split-window-right)
("C-v ." . split-window-below)
;; cursor movement
("M-n" . scroll-up-line)
("M-N" . scroll-up-command)
("M-p" . scroll-down-line)
("M-P" . scroll-down-command)
("C-f n" . next-buffer)
("C-f p" . previous-buffer)
("C-f C-c" . org-capture)
;; emms
("C-v e SPC" . emms-pause)
("C-v e d" . emms-play-directory)
("C-v e l" . emms-play-list)
("C-v e n" . emms-next)
("C-v e p" . emms-previous)
("C-v e a" . emms-add-directory)
("C-v e A" . emms-add-directory-tree)
("C-v e +" . emms-volume-raise)
("C-v e -" . emms-volume-lower)
("C-v e +" . emms-volume-mode-plus)
("C-v e -" . emms-volume-mode-minus)
("C-v e r" . emms-start)
("C-v e s" . emms-stop)
("C-v e m" . emms-play-m3u-playlist)
;; some random stuff
("C-f f" . right-char)
("C-x C-j" . dired-jump)
("C-x 4 C-j" . dired-jump-other-window)
("C-f i" . (lambda()
(interactive)
(find-file (expand-file-name
"init.org" user-emacs-directory))))))
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 14:55 ` Arthur Miller
@ 2020-12-05 17:54 ` Jean Louis
0 siblings, 0 replies; 22+ messages in thread
From: Jean Louis @ 2020-12-05 17:54 UTC (permalink / raw)
To: Arthur Miller; +Cc: Help GNU Emacs
* Arthur Miller <arthur.miller@live.com> [2020-12-05 17:56]:
> Jean Louis <bugs@gnu.support> writes:
>
> > I have too many keys on Hyper modifier and need a keys for many
> > functions. Emacs is mostly not modal and I am not using viper mode,
> > but as modal it would offer me quick access to key bindings such as:
> >
> > - / a
> > - / s
> >
> > Maybe CapsLk can be used as modifier or prefix key?
> Have you considering using your own prefix?
>
> I am using C-z C-v and C-f as prefixes
> (C-f is a bit questionable :-)):
Thank you. Today I learned how people use it. Somehow by accident I
did define prefixes but now I know it should be done better.
Many self made functions I like to put on a key. I have defined now
s-p as prefix. before I used C-s-n to make "new people entry", now I
will do all with prefix to separate package from eventualy user's made
keys.
s-p p - will for example search for people.
I find it easier with two hands. Left hand Super key, right hand p and
p again to search for people. But then there is plethora of various
keys that are related to functions related to people.
In tabuluated-list-mode I use ' a to find all tasks assigned to other
people. Right hand ' and left hand a. I may change it to some prefix
so to make it available globally.
> (with-hook after-init
> (with-key-map global
> ("M-x" . helm-M-x)
That looks great. I see.
> ("C-v <left>" . windmove-left)
> ("C-v <right>" . windmove-right)
> ("C-v <up>" . windmove-up)
> ("C-v <down>" . windmove-down)
I placed those above on Super key and arrows. That way I need not
press more than one key. C-v is still 2 keys, plus arros. One key plus
arrow may be easier.
Jean
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 11:28 Which modifier to use? Jean Louis
` (2 preceding siblings ...)
2020-12-05 14:55 ` Arthur Miller
@ 2020-12-06 9:14 ` Marcin Borkowski
2020-12-07 6:57 ` Jean Louis
2020-12-06 23:33 ` Michael Heerdegen
2020-12-09 7:13 ` Philip K.
5 siblings, 1 reply; 22+ messages in thread
From: Marcin Borkowski @ 2020-12-06 9:14 UTC (permalink / raw)
To: Jean Louis; +Cc: Help GNU Emacs
On 2020-12-05, at 12:28, Jean Louis <bugs@gnu.support> wrote:
> I have too many keys on Hyper modifier and need a keys for many
> functions. Emacs is mostly not modal and I am not using viper mode,
> but as modal it would offer me quick access to key bindings such as:
>
> - / a
> - / s
>
> Maybe CapsLk can be used as modifier or prefix key?
Have you tried hydra?
Hth,
--
Marcin Borkowski
http://mbork.pl
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-06 9:14 ` Marcin Borkowski
@ 2020-12-07 6:57 ` Jean Louis
0 siblings, 0 replies; 22+ messages in thread
From: Jean Louis @ 2020-12-07 6:57 UTC (permalink / raw)
To: Marcin Borkowski; +Cc: Help GNU Emacs
* Marcin Borkowski <mbork@mbork.pl> [2020-12-06 12:14]:
>
> On 2020-12-05, at 12:28, Jean Louis <bugs@gnu.support> wrote:
>
> > I have too many keys on Hyper modifier and need a keys for many
> > functions. Emacs is mostly not modal and I am not using viper mode,
> > but as modal it would offer me quick access to key bindings such as:
> >
> > - / a
> > - / s
> >
> > Maybe CapsLk can be used as modifier or prefix key?
>
> Have you tried hydra?
I have seen description now, thank you.
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 11:28 Which modifier to use? Jean Louis
` (3 preceding siblings ...)
2020-12-06 9:14 ` Marcin Borkowski
@ 2020-12-06 23:33 ` Michael Heerdegen
2020-12-07 0:35 ` Christopher Dimech
2020-12-09 7:13 ` Philip K.
5 siblings, 1 reply; 22+ messages in thread
From: Michael Heerdegen @ 2020-12-06 23:33 UTC (permalink / raw)
To: Jean Louis; +Cc: Help GNU Emacs
Jean Louis <bugs@gnu.support> writes:
> Maybe CapsLk can be used as modifier or prefix key?
I think a lot of Emacs users do that. I made it the hyper modifier.
Modifiers can also be combined, so each modifier actually doubles the
set of keys, given that one can memorize all of the available modifier
combinations (I can't).
Michael.
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-06 23:33 ` Michael Heerdegen
@ 2020-12-07 0:35 ` Christopher Dimech
0 siblings, 0 replies; 22+ messages in thread
From: Christopher Dimech @ 2020-12-07 0:35 UTC (permalink / raw)
To: Michael Heerdegen; +Cc: Help GNU Emacs, Jean Louis
> Sent: Monday, December 07, 2020 at 12:33 AM
> From: "Michael Heerdegen" <michael_heerdegen@web.de>
> To: "Jean Louis" <bugs@gnu.support>
> Cc: "Help GNU Emacs" <help-gnu-emacs@gnu.org>
> Subject: Re: Which modifier to use?
>
> Jean Louis <bugs@gnu.support> writes:
>
> > Maybe CapsLk can be used as modifier or prefix key?
>
> I think a lot of Emacs users do that. I made it the hyper modifier.
>
> Modifiers can also be combined, so each modifier actually doubles the
> set of keys, given that one can memorize all of the available modifier
> combinations (I can't).
You can make a help function that summarises your keybindings. You can also
executing functions directly aiding your memory with icomplete.
> Michael.
>
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 11:28 Which modifier to use? Jean Louis
` (4 preceding siblings ...)
2020-12-06 23:33 ` Michael Heerdegen
@ 2020-12-09 7:13 ` Philip K.
5 siblings, 0 replies; 22+ messages in thread
From: Philip K. @ 2020-12-09 7:13 UTC (permalink / raw)
To: Jean Louis
Jean Louis <bugs@gnu.support> writes:
> I have too many keys on Hyper modifier and need a keys for many
> functions. Emacs is mostly not modal and I am not using viper mode,
> but as modal it would offer me quick access to key bindings such as:
>
> - / a
> - / s
>
> Maybe CapsLk can be used as modifier or prefix key?
I used to use C-x x, but have since just moved most custom global
commands to C-c, because I don't have that many.
--
Philip K.
^ permalink raw reply [flat|nested] 22+ messages in thread
* RE: Which modifier to use?
@ 2020-12-05 22:34 arthur miller
2020-12-05 22:58 ` TRS-80
0 siblings, 1 reply; 22+ messages in thread
From: arthur miller @ 2020-12-05 22:34 UTC (permalink / raw)
To: TRS-80, help-gnu-emacs@gnu.org
"I think it is little known that you can define keys in this way, I
learned it while setting up which-key. If you use that package, the car
of the alist will appear as the description, allowing you to create sort
of poor man's menu system. :)"
Thanks!
Yes, I use which-key, but I certainly didn't know I could define keys with descriptions. Not sure I have use for it immediately, but interesting indeed!
-------- Originalmeddelande --------
Från: TRS-80 <lists.trs-80@isnotmyreal.name>
Datum: 2020-12-05 22:30 (GMT+01:00)
Till: help-gnu-emacs@gnu.org
Ämne: Re: Which modifier to use?
> On 2020-12-05 10:03, Arthur Miller wrote:
>
> I leave Super to my window manager and xbindkeys; and all other
> modifiers go to applications. It is a rule. Makes life easier if you
> switch between Windows and GNU/Linux
Luckily I can avoid Windoze nearly 100% of the time nowadays, however I
still follow this rule and think it's a great idea, anyway.
I use i3 (wm) and have lots of custom keybindings at the OS/WM level,
they are all based on using Super as modifier. So, in my mind, Super
(aka "Win") has to do with window manager.
Inside Emacs, I also group related keybindings behind a sort of "leader"
key, for example (dk here is alias for define-key, stricty to shorten
these lines so I can keep nice formatting):
(dk global-map (kbd "C-c y") '("Yankpad" . nil))
(dk global-map (kbd "C-c y c") '("Capture" .
yankpad-capture-snippet))
(dk global-map (kbd "C-c y e") '("Edit" .
yankpad-edit))
(dk global-map (kbd "C-c y i") '("Insert" .
yankpad-insert))
(dk global-map (kbd "C-c y r") '("Reload" .
yankpad-reload))
(dk global-map (kbd "C-c y R") '("Repeat" .
yankpad-repeat))
(dk global-map (kbd "C-c y s") '("Set (local) category" .
yankpad-set-local-category))
(dk global-map (kbd "C-c y S") '("Set (global) category" .
yankpad-set-category))
I think it is little known that you can define keys in this way, I
learned it while setting up which-key. If you use that package, the car
of the alist will appear as the description, allowing you to create sort
of poor man's menu system. :)
Cheers,
TRS-80
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Which modifier to use?
2020-12-05 22:34 arthur miller
@ 2020-12-05 22:58 ` TRS-80
2020-12-06 0:58 ` arthur miller
0 siblings, 1 reply; 22+ messages in thread
From: TRS-80 @ 2020-12-05 22:58 UTC (permalink / raw)
To: help-gnu-emacs
> On 2020-12-05 17:34, arthur miller wrote:
>
>> TRS-80 wrote:
>>
>> I think it is little known that you can define keys in this way, I
>> learned it while setting up which-key. If you use that package, the
>> car of the alist will appear as the description, allowing you to
>> create sort of poor man's menu system. :)
>
> Thanks!
>
> Yes, I use which-key, but I certainly didn't know I could define keys
> with descriptions. Not sure I have use for it immediately, but
> interesting indeed!
Just be aware there is a specific order that things need to go[0]:
(setq which-key-enable-extended-define-key t)
(require 'which-key)
(define-key [...])
(which-key-mode)
Above is only for which-key purposes. Doing define-key in that alist
style as my first email is supported by vanilla define-key (or so I
learned).
Cheers,
TRS-80
[0] https://github.com/justbur/emacs-which-key/issues/263
^ permalink raw reply [flat|nested] 22+ messages in thread
* RE: Which modifier to use?
2020-12-05 22:58 ` TRS-80
@ 2020-12-06 0:58 ` arthur miller
0 siblings, 0 replies; 22+ messages in thread
From: arthur miller @ 2020-12-06 0:58 UTC (permalink / raw)
To: TRS-80, help-gnu-emacs@gnu.org
NP, THX!
-------- Originalmeddelande --------
Från: TRS-80 <lists.trs-80@isnotmyreal.name>
Datum: 2020-12-05 23:59 (GMT+01:00)
Till: help-gnu-emacs@gnu.org
Ämne: Re: Which modifier to use?
> On 2020-12-05 17:34, arthur miller wrote:
>
>> TRS-80 wrote:
>>
>> I think it is little known that you can define keys in this way, I
>> learned it while setting up which-key. If you use that package, the
>> car of the alist will appear as the description, allowing you to
>> create sort of poor man's menu system. :)
>
> Thanks!
>
> Yes, I use which-key, but I certainly didn't know I could define keys
> with descriptions. Not sure I have use for it immediately, but
> interesting indeed!
Just be aware there is a specific order that things need to go[0]:
(setq which-key-enable-extended-define-key t)
(require 'which-key)
(define-key [...])
(which-key-mode)
Above is only for which-key purposes. Doing define-key in that alist
style as my first email is supported by vanilla define-key (or so I
learned).
Cheers,
TRS-80
[0] https://github.com/justbur/emacs-which-key/issues/263
^ permalink raw reply [flat|nested] 22+ messages in thread
end of thread, other threads:[~2020-12-09 7:13 UTC | newest]
Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-12-05 11:28 Which modifier to use? Jean Louis
2020-12-05 11:48 ` Christopher Dimech
2020-12-05 12:55 ` Jean Louis
2020-12-05 15:03 ` Arthur Miller
2020-12-05 17:55 ` Jean Louis
2020-12-05 21:29 ` TRS-80
2020-12-06 5:40 ` Jean Louis
2020-12-05 12:25 ` Stefan Möding
2020-12-05 12:59 ` Jean Louis
2020-12-05 15:52 ` Drew Adams
2020-12-05 16:08 ` Arthur Miller
2020-12-05 18:01 ` Jean Louis
2020-12-05 14:55 ` Arthur Miller
2020-12-05 17:54 ` Jean Louis
2020-12-06 9:14 ` Marcin Borkowski
2020-12-07 6:57 ` Jean Louis
2020-12-06 23:33 ` Michael Heerdegen
2020-12-07 0:35 ` Christopher Dimech
2020-12-09 7:13 ` Philip K.
-- strict thread matches above, loose matches on Subject: below --
2020-12-05 22:34 arthur miller
2020-12-05 22:58 ` TRS-80
2020-12-06 0:58 ` arthur miller
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).