Lazy Hacker Babble

Just some random babblings from a lazy hacker…

Archive for August, 2009

Consola Font Pack

Posted by hsin on 31st August 2009

Microsoft’s mono-spaced font:

http://www.microsoft.com/downloads/details.aspx?familyid=22e69ae4-7e40-4807-8a86-b3d36fab68d3&displaylang=en

Posted in Main, Programming | No Comments »

Using ctrl-c/v/x on OSX for copy/paste/cut

Posted by hsin on 30th August 2009

Three very common keyboard function that I use is to copy/paste/cut. For my hands, I found it more comfortable to use the CTRL key instead of the COMMAND (apple) key along with c/v/x. To change the key binding:

create/modify the file: ~/Library/KeyBindings/DefaultKeyBinding.dict

with the following:

/* ~/Library/KeyBindings/DefaultKeyBinding.dict */
{
"^z" = "undo:";
"^x" = "cut:";
"^v" = "paste:";
"^c" = "copy:";
"^a" = "selectAll:";
"\UF729" = "moveToBeginningOfLine:"; /* Home */
"\UF72B" = "moveToEndOfLine:"; /* End */
"\UF72C" = "pageUp:"; /* PageUp */
"\UF72D" = "pageDown:"; /* PageDown */

}

Applications that uses the Cocoa AppKit text edit objects (i.e. TextEdit). However, not every application will necessarily support this. I noticed that Firefox does not which is very annoying.

For more details, http://xahlee.org/emacs/osx_keybinding.html is very useful.

To swap ctrl and command in Firefox/Thunderbird edit ‘ui.key.accelKey’ to 17 (about:config in Firefox, advance config in Thunderbird). Specifically, you can use one of the following:

17 Control (windows style)
18 Alt (unix style)
224 Meta (Mac OS command).

Posted in Firefox, OSX | No Comments »