tag:blogger.com,1999:blog-4147841314301981805.post5806621335772140380..comments2023-03-26T07:38:56.925-06:00Comments on Heisencoder: Fixing up the Mac Key Bindings for Windows UsersMatthew V Ballhttp://www.blogger.com/profile/04512577643269096659noreply@blogger.comBlogger27125tag:blogger.com,1999:blog-4147841314301981805.post-30087914276135334052013-07-12T04:32:07.082-06:002013-07-12T04:32:07.082-06:00Man I wish I had have seen this when I first bough...Man I wish I had have seen this when I first bought my Mac 2 years ago. Better late than never!mattyboyhttps://www.blogger.com/profile/10929937237720909344noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-9848234351797929802012-10-27T23:05:27.123-06:002012-10-27T23:05:27.123-06:00Thanks for this article.. very helpful. Just want...Thanks for this article.. very helpful. Just wanted to chime in about text editors that respect these bindings. I was disappointed to find that editors like TextWrangler, TextMate, and gedit (for Mac) do not respect these custom key bindings for keyboard text navigation. They mostly just use the Mac defaults, giving some limited options for changing a couple actions. The Mac built-in TextEdit does respect the bindings, which is nice, but I wanted something with syntax highlighting etc. Fortunately I found a free editor -- Fraise -- that does respect the key bindings and also has syntax highlighting and other features. Has anyone else found good text editors / IDEs that respect these key bindings for text navigation?<br />Kevin Gimpelhttps://www.blogger.com/profile/04410998793979747031noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-55364807889724703322012-03-13T06:45:39.429-06:002012-03-13T06:45:39.429-06:00I don't know all the possible problems, but yo...I don't know all the possible problems, but you might check whether the whole thing is enclosed with curly brackets and whether the filename is in the exact correct location with the correct name: ~/Library/KeyBindings/DefaultKeyBinding.dict<br /><br />The ~ is the location of your home directory (e.g., /Users/myusername)<br /><br />I don't know off-hand whether you can remap unshifted keys like "b". You may need to at least add a @ or something. Maybe try:<br /><br />{ "@b" = "insertText:"; }Matthew V Ballhttps://www.blogger.com/profile/04512577643269096659noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-89780064567342719402012-03-13T04:36:02.558-06:002012-03-13T04:36:02.558-06:00I couldn't even do it with as simple as "...I couldn't even do it with as simple as "b" = ("insertText:", "a");<br />logged out, restarted, nada.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-20985407889686868332011-03-27T19:33:32.008-06:002011-03-27T19:33:32.008-06:00Serenity Now! Just switched from 16 years of Win...Serenity Now! Just switched from 16 years of Windows to Mac and was going crazy. On top of just normal Mac usage, I use Citrix for work so I would have to use Ctrl-C in Citrix windows, then Command-C in my local Office apps....driving me crazy.<br /><br />I swapped the Ctrl and Command keys and used your key binding file...it's like being stranded in the desert and coming upon a cooler full of Sierra Nevada. Thanks!<br /><br />Now to figure out that Alt-Tab dilemma....Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-15008962201589744772010-11-12T08:22:05.742-07:002010-11-12T08:22:05.742-07:00Nathan: Interesting point! I typically run in a ...Nathan: Interesting point! I typically run in a mode where all the extensions are always shown, so I didn't notice the feature where TextEdit can silently append a .txt. I'll update the blog to mention this.Matthew V Ballhttps://www.blogger.com/profile/04512577643269096659noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-40988175908281077842010-11-12T06:43:21.992-07:002010-11-12T06:43:21.992-07:00OK, to save anyone else the hours of pain I've...OK, to save anyone else the hours of pain I've just endured trying to get this working, here's a little tip.<br />I'm a total Mac newbie, so you'll have to forgive me my ignorance here...<br /><br />I'd tried time and time again to get this working and the DefaultKeyBinding.dict file I'd created simply wasn't being picked up. No shortcuts were working, even ludicrous ones like mapping letters to other letters.<br /><br />The cause? The file I'd created using TextEdit had an invisible .txt extension on it. *facepalm*<br />I only realised this after I downloaded the KeyBindingsEditor utility (http://www.cocoabits.com/KeyBindingsEditor/) and it created the correct file for me, showing up the other file with the txt extension.<br /><br />Thinking about it now, I'm not surprised that OS X is hiding extensions, it's what Windows does by default too and I turned that off loooong ago :-) But what got me is that I had no idea that TextEdit would add its own extension if you'd specified one in the save dialog. Perhaps the instructions above can be modified to warn for this?<br /><br />Well you live and learn. I hope this helps anyone else who runs into a brick wall on this!Nathannoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-6214372172917921752010-10-23T06:29:33.133-06:002010-10-23T06:29:33.133-06:00Siva: Unfortunately, I never used Windows 7, and w...Siva: Unfortunately, I never used Windows 7, and won't be able to help in that regard.Matthew V Ballhttps://www.blogger.com/profile/04512577643269096659noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-2239575228038563342010-10-23T00:49:07.788-06:002010-10-23T00:49:07.788-06:00Hi Matthew V Ball, Thanks for your great, great he...Hi Matthew V Ball, Thanks for your great, great help I am looking for this change from so many years. I also tried in the way of keyboard keys power supply changes which was not a great IDEA. I need one more facility in Windows 7. I need every NEW FOLDER WITH NOTE PAD in single click. I strongly believe you are the correct person to do that. If you do this that would be great help for me.Unknownhttps://www.blogger.com/profile/04254099831529370248noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-7540513148184388042010-10-22T15:41:11.743-06:002010-10-22T15:41:11.743-06:00Siva: I've added new instructions for non-prog...Siva: I've added new instructions for non-programmers that should hopefully help. Look back at the main article, possibly pressing 'Refresh' on your browser, and you should see these instructions.Matthew V Ballhttps://www.blogger.com/profile/04512577643269096659noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-86306267621165498082010-10-22T09:48:01.259-06:002010-10-22T09:48:01.259-06:00Thanks for posting here I have switched the Contro...Thanks for posting here I have switched the Control and Command keys, what is the next step (where I have to past your code..?). Please explain me once. I am not familiar with programming. If it’s works for me it would great help for me…Unknownhttps://www.blogger.com/profile/04254099831529370248noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-11711634412484659502010-07-13T14:22:54.695-06:002010-07-13T14:22:54.695-06:00I ended up not switching the Control and Command k...I ended up not switching the Control and Command keys; instead I added Keyboard Shortcuts for All Applications, setting ^C for Copy, ^Z for Undo, etc. This way I can keep my precious Alt+Ta... oops, I mean Command+Tab :)Noahnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-74856237650903676872010-06-22T07:05:45.387-06:002010-06-22T07:05:45.387-06:00Noah: I haven't found a way to change ctrl+tab...Noah: I haven't found a way to change ctrl+tab to alt+tab for switching windows, so I've been having to re-learn that aspect of the windowing system. I would be interested if anyone else finds a way to change this... :)Matthew V Ballhttps://www.blogger.com/profile/04512577643269096659noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-60205708781920951382010-06-21T15:30:39.226-06:002010-06-21T15:30:39.226-06:00Awesome, thanks for this info!
I'd like to swi...Awesome, thanks for this info!<br />I'd like to switch my control and command keys like you mentioned but then I can't quite get used to pressing ctrl+tab to switch applications. Do you know if it's possible to change that shortcut?Noahnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-38575874168087210232010-05-20T13:03:56.142-06:002010-05-20T13:03:56.142-06:00@Anonymous: For Mac Terminal.app key bindings, I w...@Anonymous: For Mac Terminal.app key bindings, I wrote up a brief discussion here: http://mavaball.net/wiki/Changing_KeyBindings_on_Mac_Terminal<br /><br />This doesn't include ctrl and cmd, but will hopefully give enough information to get started... :)Matthew V Ballhttps://www.blogger.com/profile/04512577643269096659noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-20388849069904914362010-05-20T11:37:21.066-06:002010-05-20T11:37:21.066-06:00Thanks a lot for your post - it made my life a lot...Thanks a lot for your post - it made my life a lot easier.<br />However, I managed to switch command and control on the desktop applications as you suggested, but they don't switch in the terminal - do you know how to do that in the terminal as well?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-75277506467816511152010-02-17T12:00:50.690-07:002010-02-17T12:00:50.690-07:00Oops, I had a typo in my previous comment, I inten...Oops, I had a typo in my previous comment, I intended to write that on Windows backspace that deletes by word. -- Kevin GAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-59069462909581160992010-02-17T07:19:08.368-07:002010-02-17T07:19:08.368-07:00Cool, so in addition to swapping $ and @, I have a...Cool, so in addition to swapping $ and @, I have another binding suggestion for you. Many times I've hit delete to backspace by word which is the windows behaviour. On mac, it deletes the whole line! So, here's another binding to try:<br /><br />"@\U007F" = "deleteWordBackward:"; // cmd + delete left<br /><br />Kevin GAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-29264484689973605252010-02-09T06:15:31.474-07:002010-02-09T06:15:31.474-07:00Thanks for the suggestion to swap shift and cmd! ...Thanks for the suggestion to swap shift and cmd! I've confirmed that this works and have modified the code with this change.Matthew V Ballhttps://www.blogger.com/profile/04512577643269096659noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-7774247569662523682010-02-09T00:45:27.486-07:002010-02-09T00:45:27.486-07:00WRT moveWorkBackwardAndModifySelection not working...WRT moveWorkBackwardAndModifySelection not working, it seems Cocoa doesn't like the $ to be infront of the @<br /><br />I was able to make it work using this minor change:<br /><br />"@$\UF702" = "moveWordBackwardAndModifySelection:"; /* Shift + Cmd + Leftarrow */<br />"@$\UF703" = "moveWordForwardAndModifySelection:"; /* Shift + Cmd + Rightarrow */Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-13072887680835323672009-09-25T07:05:00.235-06:002009-09-25T07:05:00.235-06:00moveWordBackwardAndModifySelection doesn't wor...moveWordBackwardAndModifySelection doesn't work too:( // Dmitry KovbaAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-37106995146758753412009-03-20T17:18:00.000-06:002009-03-20T17:18:00.000-06:00Thanks a lot for your perfect work! It'll be cool ...Thanks a lot for your perfect work! It'll be cool if Shift + Insert became work too... Let's keep us informed! // Dmitry KovbaAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-30792056451092577402009-01-05T07:22:00.000-07:002009-01-05T07:22:00.000-07:00Aaron: This is a problem that I have in other non...Aaron: This is a problem that I have in other non-Cocoa applications as well. I really do miss the Shift-Insert paste option, because I use my left-hand for the mouse, and my right hand for cursor navigation and cut/copy/paste (at least on Windows systems). On Mac, having to use Ctrl/Cmd-V forces me to either take my hand off the mouse, or move my right hand to the left-side of the keyboard, either of which slows me down.<BR/><BR/>I suspect that the 'Insert' key is actually some kind of help key on Macs -- pressing Insert sometimes changes the mouse cursor to a question mark. A real Mac keyboard doesn't even have the Insert key, but has the 'fn' key in it's place (which is completely different than Insert).<BR/><BR/>I think that the bindings to the Insert key are at a higher level and have to be remapped using a different approach. Since this key is not on any standard mac keyboard, I suspect it may be a low-level hack. I would be very interested in finding this out too!Matthew V Ballhttps://www.blogger.com/profile/04512577643269096659noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-81827006149671552342009-01-05T07:00:00.000-07:002009-01-05T07:00:00.000-07:00Thanks for this post! They all seem to work for m...Thanks for this post! They all seem to work for me on Leopard 10.5.6, except for one. I am having trouble making Shift-Insert work for paste. Strangely, Shift-Delete works for cut just fine. Any ideas?Aaron Hhttps://www.blogger.com/profile/04101817671165926765noreply@blogger.comtag:blogger.com,1999:blog-4147841314301981805.post-39368543112676176472008-12-22T16:11:00.000-07:002008-12-22T16:11:00.000-07:00thank you so very very very much!thank you so very very very much!Anonymousnoreply@blogger.com