Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'One way to use Home and End to jump to line start/end' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
One way to use Home and End to jump to line start/end
Authored by: bhas on Nov 25, '09 08:02:57AM

Another way is to make a ~/Library/KeyBindings/DefaultKeyBindings.dict containing

{
/* home Shift+home*/
"\UF729" = "moveToBeginningOfLine:";
"$\UF729" = "moveToBeginningOfLineAndModifySelection:";

/* end Shift+end*/
"\UF72B" = "moveToEndOfLine:";
"$\UF72B" = "moveToEndOfLineAndModifySelection:";
}

These keybindings will work in all Cocoa applications (and can get you into trouble with some applications which don't like these redefinitions; it seems that Numbers is one of them).

More information can be found at Jacob Rus' pages: http://www.hcs.harvard.edu/~jrus/site/cocoa-text.html

I have also mapped PgUp and PgDn to move the caret/insertion point in order to keep the current line onscreen.

You can do lots more with the keybindings.dict



[ Reply to This | # ]