It is very easy to add a bookmark to a file in NetBeans. We simply press Ctrl+Shift+M and in the gutter we see the bookmark icon (a blue arrow):
We can navigate between bookmarks with the following key combinations:
- next bookmark via Ctrl+Shift+.
- and previous bookmark via Ctrl+Shift+,
Besides using the keyboard we can use the buttons on the editor toolbar:
These keyboard shortcuts work for Windows. On a Mac we have to use the command key.
We can also change the key mapping from the Tools | Options | Keymap section and then look under Edit actions.