3

I really enjoy structuring Mathematica Notebook with different part & sub-parts, however, I have not yet found the shortcuts to navigate it efficiently.

For example, how can I use keyboard shortcuts to:

  • Go from one paragraph to another?
  • From one cell to another?
  • "Open" or "Expend"?
nhinkle
  • 37,661
500
  • 139

3 Answers3

2

To open and close cell groups you want Shift+Ctrl+{ and Shift+Ctrl+} respectively.

There are heaps of shortcut keys listed in the documentation:
NotebookShortcuts and KeyboardShortcutListing

If you want anything extra, you need to combine the appropriate command or FrontEndToken and put it into the KeyEventTranslations.tr file. This file can be found in

FileNameJoin[{$InstallationDirectory, "SystemFiles", "FrontEnd", 
              "TextResources", "X", "KeyEventTranslations.tr"}]

where you replace "X" by the platform you have, either "X", "Windows" or "OSX".

For example, a shortcut for moving to the next cell can be implemented by adding

Item[KeyEvent["g", Modifiers -> {Control}], 
     FrontEndExecute[SelectionMove[InputNotebook[], Next, Cell]]]

to the KeyEventTranslations.tr.

For more info, here's a SO question on customizing mathematica shortcuts (with good links) and one on adding a key to (un)comment code in Mathematica 7.

Simon
  • 675
2

One thing that you can do to skip past cells quickly is to hold Shift and press up/down to highlight the cell(s) you want to skip. Then let go of Shift and press the same direction to advance to the space just above/below the last highlighted cell.

Chris
  • 21
1

There are no ways to do this in Mathematica, other than the arrow keys (which I'm sure you already knew about). I don't know why, but they never seem to have developed a navigational like you can find in many different programs. Sorry.

soandos
  • 24,600
  • 29
  • 105
  • 136