all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* macOS keybindings (alt in emacs vs alt in macOS)
@ 2023-04-19  6:09 l@tlo
  2023-04-19 12:59 ` Daniel Martín
  0 siblings, 1 reply; 5+ messages in thread
From: l@tlo @ 2023-04-19  6:09 UTC (permalink / raw)
  To: help-gnu-emacs

I'm trying to set cursor/point navigation in emacs is a way that's similar to the standard macOS settings.

I'm stuck at using alt/option + left-right as "left-word" / "right-word".

I have (ns-alternate-modifier 'none), because I need access to access special non ascii characters, but that means that alt/option is then ignored by Emacs, when I need A-<right> and A-<left> (and a few others) for my setting.

Is there a way to have Emacs accept Alt as a modifier key in some defined contexts only and ignore it otherwise?

-- 
Jean-Christophe Helary @jchelary@emacs.ch
https://traductaire-libre.org
https://mac4translators.blogspot.com
https://sr.ht/~brandelune/omegat-as-a-book/




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: macOS keybindings (alt in emacs vs alt in macOS)
  2023-04-19  6:09 macOS keybindings (alt in emacs vs alt in macOS) l@tlo
@ 2023-04-19 12:59 ` Daniel Martín
  2023-04-19 15:10   ` l@tlo
  2023-04-19 19:03   ` Martin Stepanek
  0 siblings, 2 replies; 5+ messages in thread
From: Daniel Martín @ 2023-04-19 12:59 UTC (permalink / raw)
  To: l@tlo; +Cc: help-gnu-emacs

"l@tlo" <lists@traduction-libre.org> writes:

> I'm trying to set cursor/point navigation in emacs is a way that's similar to the standard macOS settings.
>
> I'm stuck at using alt/option + left-right as "left-word" / "right-word".
>
> I have (ns-alternate-modifier 'none), because I need access to access
> special non ascii characters, but that means that alt/option is then
> ignored by Emacs, when I need A-<right> and A-<left> (and a few
> others) for my setting.
>
> Is there a way to have Emacs accept Alt as a modifier key in some defined contexts only and ignore it otherwise?

Could you set ns-right-alternate-modifier to 'none?  That'd free the
right Option key to enter non-ASCII characters, while you could use the
left one to navigate by words.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: macOS keybindings (alt in emacs vs alt in macOS)
  2023-04-19 12:59 ` Daniel Martín
@ 2023-04-19 15:10   ` l@tlo
  2023-04-20  6:11     ` Eli Zaretskii
  2023-04-19 19:03   ` Martin Stepanek
  1 sibling, 1 reply; 5+ messages in thread
From: l@tlo @ 2023-04-19 15:10 UTC (permalink / raw)
  To: Daniel Martín; +Cc: help-gnu-emacs



> On Apr 19, 2023, at 21:59, Daniel Martín <mardani29@yahoo.es> wrote:
> 
> "l@tlo" <lists@traduction-libre.org> writes:
> 
>> I'm trying to set cursor/point navigation in emacs is a way that's similar to the standard macOS settings.
>> 
>> I'm stuck at using alt/option + left-right as "left-word" / "right-word".
>> 
>> I have (ns-alternate-modifier 'none), because I need access to access
>> special non ascii characters, but that means that alt/option is then
>> ignored by Emacs, when I need A-<right> and A-<left> (and a few
>> others) for my setting.
>> 
>> Is there a way to have Emacs accept Alt as a modifier key in some defined contexts only and ignore it otherwise?
> 
> Could you set ns-right-alternate-modifier to 'none?  That'd free the
> right Option key to enter non-ASCII characters, while you could use the
> left one to navigate by words.

Thank you Daniel,

There never was a right option key on (my) mac laptops.

-- 
Jean-Christophe Helary @jchelary@emacs.ch
https://traductaire-libre.org
https://mac4translators.blogspot.com
https://sr.ht/~brandelune/omegat-as-a-book/




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: macOS keybindings (alt in emacs vs alt in macOS)
  2023-04-19 12:59 ` Daniel Martín
  2023-04-19 15:10   ` l@tlo
@ 2023-04-19 19:03   ` Martin Stepanek
  1 sibling, 0 replies; 5+ messages in thread
From: Martin Stepanek @ 2023-04-19 19:03 UTC (permalink / raw)
  To: help-gnu-emacs

hello,

this is what i-m using:

(setq mac-option-modifier 'none) ;; use the left option-key for typing 
|, ­~, etc.
(setq mac-right-option-modifier 'meta) ;; right option-key is meta, 
option-<left>/right moves one word left or right
(setq mac-command-modifier 'meta) ;; so there is also a meta-key for the 
left hand (left cmd-key)
(setq mac-right-command-modifier 'super) ;; the usual 
macos-cmd-keybindings work with the right cmd-key.

Am 19.04.23 um 14:59 schrieb Daniel Martín:
> "l@tlo" <lists@traduction-libre.org> writes:
>
>> I'm trying to set cursor/point navigation in emacs is a way that's similar to the standard macOS settings.
>>
>> I'm stuck at using alt/option + left-right as "left-word" / "right-word".
>>
>> I have (ns-alternate-modifier 'none), because I need access to access
>> special non ascii characters, but that means that alt/option is then
>> ignored by Emacs, when I need A-<right> and A-<left> (and a few
>> others) for my setting.
>>
>> Is there a way to have Emacs accept Alt as a modifier key in some defined contexts only and ignore it otherwise?
> Could you set ns-right-alternate-modifier to 'none?  That'd free the
> right Option key to enter non-ASCII characters, while you could use the
> left one to navigate by words.
>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: macOS keybindings (alt in emacs vs alt in macOS)
  2023-04-19 15:10   ` l@tlo
@ 2023-04-20  6:11     ` Eli Zaretskii
  0 siblings, 0 replies; 5+ messages in thread
From: Eli Zaretskii @ 2023-04-20  6:11 UTC (permalink / raw)
  To: help-gnu-emacs

> From: "l@tlo" <lists@traduction-libre.org>
> Date: Thu, 20 Apr 2023 00:10:53 +0900
> Cc: help-gnu-emacs@gnu.org
> 
> > On Apr 19, 2023, at 21:59, Daniel Martín <mardani29@yahoo.es> wrote:
> > 
> > "l@tlo" <lists@traduction-libre.org> writes:
> > 
> >> I'm trying to set cursor/point navigation in emacs is a way that's similar to the standard macOS settings.
> >> 
> >> I'm stuck at using alt/option + left-right as "left-word" / "right-word".
> >> 
> >> I have (ns-alternate-modifier 'none), because I need access to access
> >> special non ascii characters, but that means that alt/option is then
> >> ignored by Emacs, when I need A-<right> and A-<left> (and a few
> >> others) for my setting.
> >> 
> >> Is there a way to have Emacs accept Alt as a modifier key in some defined contexts only and ignore it otherwise?
> > 
> > Could you set ns-right-alternate-modifier to 'none?  That'd free the
> > right Option key to enter non-ASCII characters, while you could use the
> > left one to navigate by words.
> 
> Thank you Daniel,
> 
> There never was a right option key on (my) mac laptops.

Since this variable is described in the Emacs manual, where I assume
you looked in your search for the solution, I wonder if something
there should be clarified/augmented/improved to make the solution of
this problem more obvious?  Would you care to take a look and suggest
any such improvements for the manual?



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-04-20  6:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-19  6:09 macOS keybindings (alt in emacs vs alt in macOS) l@tlo
2023-04-19 12:59 ` Daniel Martín
2023-04-19 15:10   ` l@tlo
2023-04-20  6:11     ` Eli Zaretskii
2023-04-19 19:03   ` Martin Stepanek

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.