Changing composer shortcut

107 views
Skip to first unread message

Jackie Meese

unread,
Jun 22, 2021, 2:46:50 PM6/22/21
to iterm2-discuss
Is it possible to change the composer shortcut? It's cmd+shift-. and I've got a long standing service that is mapped to that already (macOS has it as a selectable for googling selected text, but I've got a variant that uses the default browser instead of Safari). I've worked around it for so long, that I'm used to it, but I thought I'd ask. I'm at the point to recompiling it if someone can point me to where it is in the code. I'm not a knowledgeable programmer, but I can edit something I'm pointed to and recompile it.

Better would be if it's mappable in the preferences.

Thanks,
j.

George Nachman

unread,
Jun 23, 2021, 12:14:18 PM6/23/21
to iterm2-...@googlegroups.com
The shortcut is for the menu item View > Composer. You can change the mapping system prefs > keys > shortcuts > app shortcuts. Or you can use iTerm2’s prefs > keys > key bindings like this:



--
You received this message because you are subscribed to the Google Groups "iterm2-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to iterm2-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/iterm2-discuss/0fe6dcd8-a4e6-4a34-8f4a-9d4c09e89199n%40googlegroups.com.

Jackie Meese

unread,
Jun 23, 2021, 1:08:56 PM6/23/21
to iterm2-...@googlegroups.com
Using the item keyboard remapping in iTerm2 I can:
1. Choose to "Ignore" cmd+shift+. This causes the keystroke to do
nothing. The system set of cmd+shift+. does not get called. The
keystroke is "eaten" by iTerm2, and isn't really ignored. It's just
ignored by the shell.
2. Set a mapping to Composer. This doesn't remove the binding of
cmd+shift+. It just adds another bind to composer.

As for changing the mapping in the Keyboard System Preference, that's
what I'm trying to avoid, since it's really ingrained in my habits.

I can be resigned to my choices being that I can continue to live with
it, or learn to change my habit to a different system wide keystroke.

j.

On 6/23/2021 12:14 PM, George Nachman wrote:
> The shortcut is for the menu item View > Composer. You can change the
> mapping system prefs > keys > shortcuts > app shortcuts. Or you can use
> iTerm2’s prefs > keys > key bindings like this:
>
>
>
> On Jun 22, 2021 at 11:46:50 AM, Jackie Meese <jme...@vt.edu
> <mailto:jme...@vt.edu>> wrote:
>
> Is it possible to change the composer shortcut? It's cmd+shift-. and
> I've got a long standing service that is mapped to that already
> (macOS has it as a selectable for googling selected text, but I've
> got a variant that uses the default browser instead of Safari). I've
> worked around it for so long, that I'm used to it, but I thought I'd
> ask. I'm at the point to recompiling it if someone can point me to
> where it is in the code. I'm not a knowledgeable programmer, but I
> can edit something I'm pointed to and recompile it.
>
> Better would be if it's mappable in the preferences.
>
> Thanks,
> j.
>
> --
> You received this message because you are subscribed to the Google
> Groups "iterm2-discuss" group.
> To unsubscribe from this group and stop receiving emails from it,
> send an email to iterm2-discus...@googlegroups.com
> <mailto:iterm2-discus...@googlegroups.com>.
> <https://groups.google.com/d/msgid/iterm2-discuss/0fe6dcd8-a4e6-4a34-8f4a-9d4c09e89199n%40googlegroups.com?utm_medium=email&utm_source=footer>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "iterm2-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to iterm2-discus...@googlegroups.com
> <mailto:iterm2-discus...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/iterm2-discuss/CAB5Rqo%3DCDKbTQRsKofwD3S0U1dpqdhOvvA5iDtWLhh9JHwDWxg%40mail.gmail.com
> <https://groups.google.com/d/msgid/iterm2-discuss/CAB5Rqo%3DCDKbTQRsKofwD3S0U1dpqdhOvvA5iDtWLhh9JHwDWxg%40mail.gmail.com?utm_medium=email&utm_source=footer>.

--
I am, and always will be, an idiot.
Jackie Meese, TLOS
801 University City Blvd, Suite 21; Office 2101R
Blacksburg, VA 24060-0292
jack...@vt.edu
540-231-6801

George Nachman

unread,
Jun 24, 2021, 1:50:34 AM6/24/21
to iterm2-...@googlegroups.com
> Choose to "Ignore" cmd+shift+. This causes the keystroke to do 
nothing. The system set of cmd+shift+. does not get called. The 
keystroke is "eaten" by iTerm2, and isn't really ignored. It's just 
ignored by the shell

This is somewhat surprising. When you set the key to be ignored, it gets dropped very early on. But it’s possible that whatever magic macOS is doing sees that it’s a shortcut for the menu item and ignores it anyway.

> As for changing the mapping in the Keyboard System Preference, that's 
what I'm trying to avoid, since it's really ingrained in my habits

I mean you can change the Composer shortcut to something that won’t get in the way of your other shortcut. Like:



Which causes this:




To unsubscribe from this group and stop receiving emails from it, send an email to iterm2-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/iterm2-discuss/6a1f5092-5709-36a7-cf99-389e85e3b392%40vt.edu.
Reply all
Reply to author
Forward
0 new messages