Notepad++ permanent line marking?

7

I need to mark certain lines in Notepad++ permanently.
They offer a line marking (blue dots in the picture below), but I can't save the marked state. What are my options?

Enter image description here

Manumit

Posted 2015-06-04T18:12:51.407

Reputation: 239

Answers

9

They offer a line marking (blue dots in the picture below), but I can't save the marked state.

The "blue dots" are called bookmarks.

To save the bookmarks you need to enable sessions.

To enable sessions:

  • menu SettingsPreferences
  • select Backup
  • enable Remember current session for next launch

enter image description here


Notepad++ doesn't even give me the option to save when I add bookmarks.

Use menu FileSave Session...


Changes not automatically saved

Here are a few ways changes may not get saved to the session file.

  • If you change bookmarks or folded lines via the menu or a keyboard shortcut then terminate Notepad++ without doing anything that would cause the session to be saved. This is because a plugin cannot detect those events. Clicking in the bookmark or fold margins is detected.
  • If you close a file then immediately terminate Notepad++ (see sessionSaveDelay in Manual Settings).
  • If you do anything that results in a change to one of the following then immediately terminate Notepad++ (see settingsSavePoll in Manual Settings).

    • bookmarks
    • folded lines
    • filters
    • favorites
    • sort order
    • dialog window sizes
    • default session name

Source Session Manager help

DavidPostill

Posted 2015-06-04T18:12:51.407

Reputation: 118 938

It works, but only if I exit Notepad without exiting the relevant tab. If I exit the tab for the file everything is wiped. I need a more sturdy solution for permament line marking. – Manumit – 2015-06-04T18:44:41.897

I just tested. Closed all tabs. Closed and restarted notepad++. Reopened a file. The bookmarks are still present. – DavidPostill – 2015-06-04T18:45:35.943

1As a matter of fact notepad doesn't even give me the option to save when I add bookmarks. It's as if nothing was changed in data. – Manumit – 2015-06-04T18:48:15.340

1Use file > save session – DavidPostill – 2015-06-04T18:53:06.823

Thank you! I saved the session to a new file, unfortunately I have to load the session every time I X out the tab. Is there a way to way automate this? – Manumit – 2015-06-04T18:57:17.973

@Manumit I don't know of any way to automate this. I don't normally close my tabs :/ – DavidPostill – 2015-06-04T20:06:24.480