Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I've plugged a basic UK Windows keyboard into my MacBook. I keep hitting Home & End but they don't work as I expect, they jump to the top/bottom of the document/page rather than the start/end of the line. It's very annoying since I am doing this automatically as I type!

Is there a way to make them work as I expect, i.e. why don't they map to CMD+LEFT/RIGHT?

share|improve this question
add comment

1 Answer 1

Create ~/Library/KeyBindings/ and save this as DefaultKeyBinding.dict:

{
    "\UF729"  = moveToBeginningOfLine:;
    "\UF72B"  = moveToEndOfLine:;
    "$\UF729" = moveToBeginningOfLineAndModifySelection:;
    "$\UF72B" = moveToEndOfLineAndModifySelection:;
}

See TextMate Blog » Key bindings for switchers. pageUp: and pageDown: don't work in Safari, Chrome, or iWork applications.

It doesn't work in all applications or text views though. Another option would be to use KeyRemap4MacBook:

You can customize the setting by copying it from here and adding it to private.xml.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.