How can I move through a notebook using only the keyboard?
If one tries to use the arrow keys, the cursor tends to get "trapped" in comments and error messages.
Mathematica Stack Exchange is a question and answer site for users of Wolfram Mathematica. It only takes a minute to sign up.Sign up to join this community
There are some known bugs where the caret can get, as you say, "trapped" when using the up/down arrow keys. I.e., further presses of the up/down key at certain points in typesetting cells can just do nothing. However, it has always been my experience that left/right arrow will continue to work, and that usually one or two presses will get you to a point that the up/down arrow keys begin working again.
Also, important to note, that you can traverse the notebook more quickly with the arrow keys by popping the selection out to the cell bracket. You can, of course, select the cell bracket using the mouse, but you can also select it from the keyboard by repeatedly pressing Ctrl+period (or Cmd+period on Mac) to move the structured selection outwards until it hits the cell bracket. At that point, using the up/down arrow keys will never get trapped, and it will also be very efficient if you're looking to skip through content cell by cell.
I do not see exactly what you mean by "get trapped by comments". Anyway, you can move fairly well in a notebook and inside a cell with a keyboard. 1-select a cell bracket 2- use the op-down arrow keys to move and select other cells. 3- once you are on the desired cell bracket, press the left arrow key to enter the cell. Then use the arrow keys to move to the desired point in the cell text.
You do not really need to execute point 1. If you are anywhere in a cell, just press the up-down keys until you get out of the cell and move betweeen cells or into other cells above or below.
You may also move faster inside a cell using the Ctrl (or Cmd)-left-right arrow key.