Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

alejandrouy

macrumors newbie
Original poster
Sep 1, 2023
2
0
Is there a possibility in macOS Catalina 10.15 to set a keyboard shortcut for a particular key, for example the "r" key?
 
Can you explain how you would need a keyboard shortcut for a key that is literally already on the keyboard.
 
Thanks,

The "R" key on the physical keyboard of the MacBook pro does not work, it is broken. Is it possible to configure a keyboard shortcut to type the letter "R", either natively in macOS, or by installing an app?
For example: Command (or Cmd) ⌘ + Option (or Alt) ⌥ + <any shortcut combination>
 
Thanks,

The "R" key on the physical keyboard of the MacBook pro does not work, it is broken. Is it possible to configure a keyboard shortcut to type the letter "R", either natively in macOS, or by installing an app?
For example: Command (or Cmd) ⌘ + Option (or Alt) ⌥ + <any shortcut combination>

try Keyboard Maestro https://www.keyboardmaestro.com/main/ or similar macro utilities. they should allow you to do this.
 
It could be achieved without third-party apps by using a QuickAction created with Automator, running AppleScript when pressing a shortcut. But it might be a nightmare to give permissions for sending keystrokes in every app you want to type into.

For r
Code:
tell application "System Events" to keystroke "r"

for R
Code:
tell application "System Events" to keystroke "r" using shift down

QuickAction.jpg
shortcuts.jpg
 
Yikes, my muscle memory would freak out if I had to press multiple keys (or even remap an existing key to a lesser used key) to press a standard and frequently used alpha key.

If fixing the keyboard isn’t an option, I’d much rather buy a cheap, portable keyboard than go with key remapping.

However, if you’re set on this, Keyboard Shortcuts might be the way to go. Similar to how you can type “omw” and have it replace with “On my way!”, you could set one up for typing the letter (eg “eee” = “r” and “EEE” = “R”). Since that’s baked into the keyboard shortcut, you won’t have to muck with permissions and it should work universally.
 
  • Like
Reactions: theorist9
However, if you’re set on this, Keyboard Shortcuts might be the way to go. Similar to how you can type “omw” and have it replace with “On my way!”, you could set one up for typing the letter (eg “eee” = “r” and “EEE” = “R”).

I wonder if you're referring to Text Replacements in System Settings > Keyboard settings?

They are, unfortunately, next to useless as they don't work in all apps (only selected ones, and not even in all Apple apps). Plus, this feature won't even type anything automatically - just show a popup from which the replacement should be chosen.

The solution of text replacement you describe is a good one in theory - it's just he'd need a more robust tool for this such as TextExpander (or a similar utility). This will type the desired text automatically and work everywhere.

Also, I totally agree that an external keyboard would be a much better option.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.