Bookmark Scrollbar display
-
as you said
Either on the line numbers or on the scrollbar?
and because line numbers would change while scrolling,
it makes me think you have uncheckedSettings->Preferences->Editing->Display Bookmarks
Could this be?
Cheers
Claudia -
@Claudia-Frank you are correct it makes more sense on the scrollbar than the line numbers. I do not have that setting turned off. The scrollbar shows you the whole document so it would make more sense to show them in the scrollbar like my screen shot above from Visual Studio.
When you have multiple bookmarks on the document it would be really nice to be able to see where you are at in relation to the bookmarks on the document. This is what Visual studio allows you to see. (am i above or below my bookmark.) I know you can do that with line numbers but when you have multiple its just hard to keep track.
-
I see https://notepad-plus-plus.org/community/topic/13401/feature-request-smart-scrollbar request for this feature, but there is a strange comment and that topic is inexplicably locked.
I feel sad because of lack of marks over scrollbar for bookmarks, search results and smart highlights.
I extremely like this feature in Chrome (for find in a page), in Delphi with installed cnPack, in Visual Studio, and it’s my vital need to have this in Notepad++!
-
I assume you will not be sharing the script which shows us how many bookmarks we have on our documents?
-
Similar request for document map panel: https://notepad-plus-plus.org/community/topic/14477/feature-requeset-show-highlighted-variables-in-document-map
But Document map did not represent the whole document, in contradistinction to a scrollbar. And I did not find a way to zoom off it.
-
@SalviaSage said:
I assume you will not be sharing the script which shows us how many bookmarks we have on our documents?
Correct. It uses one of the sections of the status bar that you complained about previously regarding excessive flickering. I don’t wanna go through that again. :-D
-
Yeah but, I have already learned how to put things into the 6 different locations in the statusbar, I am planning to put it next to my file name - date last modified area, the first category.
Give me the code?
pretty please? with a cherry on top ???
^__^
-
…cherry on top
Haha…well, here’s something to get you going with bookmarks:
NPP_BOOKMARK_MARKER_ID_NUMBER = 24 # from N++ source code: MARK_BOOKMARK = 24; NPP_BOOKMARK_MARKER_MASK = 1 << NPP_BOOKMARK_MARKER_ID_NUMBER line_nbr = editor.markerNext(0, NPP_BOOKMARK_MARKER_MASK) found_at_least_1 = False while line_nbr != -1: print 'bookmark found at line', str(line_nbr + 1) found_at_least_1 = True line_nbr = editor.markerNext(line_nbr + 1, NPP_BOOKMARK_MARKER_MASK) if not found_at_least_1: print 'no bookmarks found' if 0: print 'adding one at current line' editor.markerAdd(editor.lineFromPosition(editor.getCurrentPos()), NPP_BOOKMARK_MARKER_ID_NUMBER)
The code if the
if 0:
block isn’t enabled but it illustrates how to add a bookmark with PS code if you ever want to do that. Otherwise the code simply prints out what lines it finds previously set bookmarks at. -
Thanks for posting that code, I seriously need to learn the Scintilla API so I can make my own plugins and scripts. but I am pre-occupied by another scientific subject, so it’s been put on hold… : P
-
The marker ID used for bookmarks changed in Notepad++ 8.4.6 (and later). It is now 20, instead of 24. So, all references to 24 in this thread and/or its script(s), should be changed to 20.