New To Mac-Forums?

Welcome to our community! Join the discussion today by registering your FREE account. If you have any problems with the registration process, please contact us!

Get your questions answered by community gurus Advice and insight from world-class Apple enthusiasts Exclusive access to members-only contests, giveaways and deals

Join today!

 
Start a Discussion
 

Mac-Forums Brief

Subscribe to Mac-Forums Brief to receive special offers from Mac-Forums partners and sponsors

Join the conversation RSS
Switcher Hangout The place for switchers to discuss their new machines, and how to work with OS X. General support can be had here for newbie stuff, like "How do I restart my new iMac?" :)

Both Shifts Pressed as a Keybinding


Post Reply New Thread Subscribe

 
Thread Tools
Arthenik

 
Member Since: Jun 28, 2011
Posts: 3
Arthenik is an unknown at this point

Arthenik is offline
Hello, I'm considering moving to Mac OS X from Linux. I use two separate keyboard layouts. I switch between them by pressing both my Shift keys. It is my understanding that replicating this behaviour is not easily done on a Mac. My question is, can it be done at all?

Coming from Linux, I'm not afraid of modifying config files if necessary.
QUOTE Thanks
Lifeisabeach

 
Lifeisabeach's Avatar
 
Member Since: Sep 30, 2007
Location: Wilmington, NC
Posts: 6,892
Lifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond repute
Mac Specs: iMac i3 (mid-2010) + OS 10.9; TV 3; iPhone 5S; iPad 4

Lifeisabeach is offline
Quote:
Originally Posted by Arthenik View Post
Hello, I'm considering moving to Mac OS X from Linux. I use two separate keyboard layouts. I switch between them by pressing both my Shift keys. It is my understanding that replicating this behaviour is not easily done on a Mac. My question is, can it be done at all?

Coming from Linux, I'm not afraid of modifying config files if necessary.
If you mean like changing the language, yes it's very easy. You can do it from a drop down menu in the menubar listing the languages you pre-selected in the preferences, and you can assign a keyboard shortcut of your choosing to go to the "Next" and the "Previous" input source. Piece of cake.


Please verify and include the exact model/year of your Mac and OS X version number (available from "About This Mac", then "More Info" on the Apple menu).
------
Links: Onyx | EasyFind | Apple Hardware Test | How to test your hard drive | The Safe Mac Adware Removal Guide | Uninstall MacKeeper
------
Lifeisabeach - Mac-Forums Member of the Month June 2009, Feb 2012, and March 2013.
QUOTE Thanks
Arthenik

 
Member Since: Jun 28, 2011
Posts: 3
Arthenik is an unknown at this point

Arthenik is offline
That's not what I was asking.

I want the languages switch specifically when both Shift keys are pressed, both left and right Shift.
QUOTE Thanks
Lifeisabeach

 
Lifeisabeach's Avatar
 
Member Since: Sep 30, 2007
Location: Wilmington, NC
Posts: 6,892
Lifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond repute
Mac Specs: iMac i3 (mid-2010) + OS 10.9; TV 3; iPhone 5S; iPad 4

Lifeisabeach is offline
Quote:
Originally Posted by Arthenik View Post
That's not what I was asking.

I want the languages switch specifically when both Shift keys are pressed, both left and right Shift.
No. It works exactly as I described. If you only have 2 languages, then the key combo that you pre-set will go from one to the other. The pop-up menu is merely a convenience if you have more than two and need to keep selecting down the list. It's only there briefly while pressing the keys and goes away on its own. And no, pressing both shift keys isn't an option. System-wide shortcuts like these typically require a combo of the CONTROL, OPTION, and/or COMMAND key with a letter or pretty much any other character really. The only difference as far as you would be concerned is adjusting to a different keyboard shortcut.

EDIT: Actually if you do it fast enough, you won't even see the on-screen display. And in addition to characters with the modifier keys, you can use the spacebar. For ex: OPTION-SPACEBAR works.

Additional edit: Just to be clear… you can stick to using just one keyboard shortcut, either PREVIOUS or NEXT, since with just two languages you'd effectively have a toggle. Using NEXT for example… if you had several languages and were at the bottom of the list already, hitting NEXT would simply go back to the top.


Please verify and include the exact model/year of your Mac and OS X version number (available from "About This Mac", then "More Info" on the Apple menu).
------
Links: Onyx | EasyFind | Apple Hardware Test | How to test your hard drive | The Safe Mac Adware Removal Guide | Uninstall MacKeeper
------
Lifeisabeach - Mac-Forums Member of the Month June 2009, Feb 2012, and March 2013.
QUOTE Thanks
EvenStranger

 
EvenStranger's Avatar
 
Member Since: Dec 09, 2010
Location: Virginia
Posts: 845
EvenStranger is just really niceEvenStranger is just really niceEvenStranger is just really niceEvenStranger is just really niceEvenStranger is just really nice
Mac Specs: Currently 13" Late 2010 MBA, 4GB/128GB; Early 2011 13" MBP, dual core i7 2.7ghz, 4gb ram, 500gb hd

EvenStranger is offline
I think the question is less about changing language layouts and more along the lines of "Does the Mac recognize the difference between the left and right shift, or are they treated the same?" As I understand it, pressing either left or right shift would just register a "shift" command, and I don't think the system differentiates between them.
QUOTE Thanks
Lifeisabeach

 
Lifeisabeach's Avatar
 
Member Since: Sep 30, 2007
Location: Wilmington, NC
Posts: 6,892
Lifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond repute
Mac Specs: iMac i3 (mid-2010) + OS 10.9; TV 3; iPhone 5S; iPad 4

Lifeisabeach is offline
Quote:
Originally Posted by EvenStranger View Post
I think the question is less about changing language layouts and more along the lines of "Does the Mac recognize the difference between the left and right shift, or are they treated the same?"
You may be right about that. I took it as "can you do this with a simple shortcut". If he's going to be so rigid as to want to do it that way and only that way, then he may as well stick with Linux. Changing from any OS to any other OS requires adjustments to one's habits and expectations, and if something like this is going to be a hangup, then he'll find fault with every little difference.


Please verify and include the exact model/year of your Mac and OS X version number (available from "About This Mac", then "More Info" on the Apple menu).
------
Links: Onyx | EasyFind | Apple Hardware Test | How to test your hard drive | The Safe Mac Adware Removal Guide | Uninstall MacKeeper
------
Lifeisabeach - Mac-Forums Member of the Month June 2009, Feb 2012, and March 2013.
QUOTE Thanks
Lifeisabeach

 
Lifeisabeach's Avatar
 
Member Since: Sep 30, 2007
Location: Wilmington, NC
Posts: 6,892
Lifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond repute
Mac Specs: iMac i3 (mid-2010) + OS 10.9; TV 3; iPhone 5S; iPad 4

Lifeisabeach is offline
Heh. I'm playing with this some more… any arrow key on its own can be set to do this, or with a modifier like SHIFT-ARROW.


Please verify and include the exact model/year of your Mac and OS X version number (available from "About This Mac", then "More Info" on the Apple menu).
------
Links: Onyx | EasyFind | Apple Hardware Test | How to test your hard drive | The Safe Mac Adware Removal Guide | Uninstall MacKeeper
------
Lifeisabeach - Mac-Forums Member of the Month June 2009, Feb 2012, and March 2013.
QUOTE Thanks
Arthenik

 
Member Since: Jun 28, 2011
Posts: 3
Arthenik is an unknown at this point

Arthenik is offline
Being unable to use a Shift-Shift shortcut would hardly be a reason for me to change my attitude towards Macs. It's just that I find it one of the most pleasant shortcuts to use while touch typing and if I could retain it, that would be, well, nice.

I saw on a different forum that the two Shift keys generate unique keypress signals. I might investigate whether defining the shortcut is possible when I have my MacBook.
QUOTE Thanks
Lifeisabeach

 
Lifeisabeach's Avatar
 
Member Since: Sep 30, 2007
Location: Wilmington, NC
Posts: 6,892
Lifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond reputeLifeisabeach has a reputation beyond repute
Mac Specs: iMac i3 (mid-2010) + OS 10.9; TV 3; iPhone 5S; iPad 4

Lifeisabeach is offline
Quote:
Originally Posted by Arthenik View Post
Being unable to use a Shift-Shift shortcut would hardly be a reason for me to change my attitude towards Macs. It's just that I find it one of the most pleasant shortcuts to use while touch typing and if I could retain it, that would be, well, nice.
Agreed… it would be nice. We do periodically get people through here who are highly rigid with their routines and moan when OS X doesn't work exactly the same way they are used to. OS X is far more flexible than most people realize, but there are limits.

Quote:
I saw on a different forum that the two Shift keys generate unique keypress signals. I might investigate whether defining the shortcut is possible when I have my MacBook.
I'm continuing to dig into this, and I'll just go ahead and list the 2 files that should have the relevant strings. All are found in ~/Library/Preferences:
  • com.apple.universalaccess.plist
  • com.apple.symbolichotkeys.plist

Those two files are preference files, and both get modified when I use System Preferences to modify the keyboard shortcut for switching inputs. The string needed should be in one or the other, though I am having difficulty find the exact one.

EDIT: Bleah… i got sloppy. Nevermind the .conf file mentioned beforehand. That belonged to a DOS emulator.

EDIT 2: Ok, the exact string is in com.apple.symbolichotkeys.plist and the Property Key is 60. With "Select the previous input source" set to SHIFT-COMMAND-L, the parameters for fields 0, 1, and 2, are 108, 37, and 1179648. Fields 0 and 1 appear to both belong to the L because they both change if I use a different letter (107 and 40 for K). The 3rd parameter changes with each combination of the modifier keys I try. Anywho, that is as far as I can take it. If you can take it further when you get your MacBook, please do report back.


Please verify and include the exact model/year of your Mac and OS X version number (available from "About This Mac", then "More Info" on the Apple menu).
------
Links: Onyx | EasyFind | Apple Hardware Test | How to test your hard drive | The Safe Mac Adware Removal Guide | Uninstall MacKeeper
------
Lifeisabeach - Mac-Forums Member of the Month June 2009, Feb 2012, and March 2013.
QUOTE Thanks

Post Reply New Thread Subscribe


« Outlook 2007 (PC) -> Outlook 2011 (Mac) | Sync Outlook between Mac and PC »
Thread Tools

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread
Thread Starter
Forum
Replies
Last Post
Keyboard shortcuts always beep when Pressed smith7391 OS X - Operating System 10 02-28-2011 04:44 PM
uMBP 17" matt - may keyboard leave traces on screen surface when MBP's pressed? mrcn Apple Notebooks 1 07-29-2010 08:30 AM
Cmd key seems to always be pressed down nestea Apple Notebooks 1 03-04-2010 03:10 PM
iPhone - pressed on "Erase all Data and all settings" now won't turn on samuelduque iOS and Apps 3 12-19-2009 08:52 PM
How to simulate a key pressed event fgrasset OS X - Development and Darwin 0 02-19-2009 01:12 PM

All times are GMT -4. The time now is 03:26 PM.

Powered by vBulletin
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
X

Welcome to Mac-Forums.com

Create your username to jump into the discussion!

New members like you have made this community the ultimate source for your Mac since 2003!


(4 digit year)

Already a member?