All bookmarks list view
-
I don’t use them much, mainly because I can’t mentally keep track of them.
I still don’t use Bookmarks all that often
The only times I use Bookmarks are for the temporary search-and-select benefits that the Search > Bookmark menu gives you. I do not remember leaving multiple bookmarks active beyond my memory’s ability to track them. About the only thing that a “long-term” bookmark would help me with is getting back to the particular function I was editing: since I said the word “function”, it’s obviously easier to get there with the Function List panel for me. I just don’t have enough non-code text files that are big enough to benefit from bookmarks… and when I do, I usually make a UDL+FunctionList for them anyway, so they are effectively code with some pattern that gets me to the right ballpark. I cannot think of any truly random, non-patterened places that I would ever have a need to mark.
But I know that my Notepad++ usage model is different from many (as has been evidenced time and again in this Community), and I do agree that if someone did have a need for more than one or two long-term bookmarks, having a Manager for that would likely be helpful. I somehow doubt that TPTB would find much use in that, so it will probably be relegated to Plugin land. At which point, I would probably hit up Bookmarks@Dook to see if Dook was willing to add a way to track/show all tabs’ bookmarks in one view. Oh, issue #11 starts with “all bookmarks of all opened files” request, and that was more than six months ago – and Dook rejected the multi-tab portion of that request because “NPP does not provide API to retrieve information from open tabs withouts switching to them”. (Unfortunately, that plugin hides the source code; otherwise, someone could learn from the way it was implemented, or suggest a PR to the author.)
I am tempted to suggest a workaround to Dook. I probably will, actually. (Addendum: added my comment there)
-
@peterjones said in All bookmarks list view:
Dook
To me, “Dook” doesn’t seem like much of a “team player”. Not posting your source code for such an item is in bad taste. Personally, I’d not count on Dook for anything.
@peterjones said in All bookmarks list view:
I am tempted to suggest a workaround to Dook. I probably will, actually.
Curious as to what this might be.
-
@peterjones said in All bookmarks list view:
I do not remember leaving multiple bookmarks active beyond my memory’s ability to track them
This is my “problem” too, as I said.
But, I wonder if I might feel differently and use this feature more if it had a nice “manager”. I guess I won’t get this answered until there IS a real manager. :-)
-
Curious as to what this might be.
I don’t know that it’s all that brilliant: but since bookmarks don’t change except when a given tab is active anyway, just do a single scan of all files during plugin initialization, and then have the plugin behave normally for tracking the changes on the active tab’s bookmarks. But maybe I’m missing something obvious why that wouldn’t work.
-
@alan-kilborn said in All bookmarks list view:
@peterjones said in All bookmarks list view:
I do not remember leaving multiple bookmarks active beyond my memory’s ability to track them
This is my “problem” too, as I said.
I think I phrased that poorly. My “I do not remember” portion meant more, “I cannot now think of a time when I left multiple bookmarks active beyond my memory’s ability to track them”. Or said another way, “I’ve never run into the situation where I needed to manage a bookmark long-term”
-
@alan-kilborn well these bookmarks are saved collectively of all notes. i think its not good approach to save them collectively. because in situation like me where you have 70+ notes open in notepad++ and if am currently working in note # 3 and this bookmark file will open with a lot of other bookmarks and you have to switch between bookmark tab and your note tab back and forth. this approach is good for normal users but not for developers. if jump points for single note is maintain within its CTRL + G modal then will be good and when note is close it should be destroyed with it.
-
@alan-kilborn
For me this is very useful script. Thank you!
But I’m very beginner in Python and can’t think out how to add a possibility to “Go back to previous location”? In case I decide not to go to any bookmark, or if I see that I haven’t set bookmark to right place.
I would be very thankful if you find time to help with this. -
@andi-kiissel said in All bookmarks list view:
“Go back to previous location”? In case I decide not to go to any bookmark
For this case you would simply close the the “new X” (X is a digit) tab; you should be returned to the point where you were editing when you invoked the script.
But it maybe feels like I’m misunderstanding something…?
-
@alan-kilborn
Perhaps I have missed or misunderstod some setting?
By default new tab opens as last rightmost tab. If I close it, then activates new last rightmost tab. If I have 10 tabs and run script from 3rd tab, then after closing this 11th tab I will be in 10th tab, not in 3rd. -
@andi-kiissel said in All bookmarks list view:
By default new tab opens as last rightmost tab. If I close it, then activates new last rightmost tab
Ah, you must have changed this setting away from the default; default shown here:
I find that if I create a new file, do something to it, then close it, it makes the most sense to then be left editing the file I “most-recently-used”, instead of whatever happens to be the right-most existing tab.
The script is meant to be a simple demo, but if you do not want to tick the option I show (for some reason), I could see what I can do about “fixing” the script.
-
@alan-kilborn
I’m sorry! I don’t like this Document Switcher.
But now I think I found a bug: without Enable Document Switcher
sometimes Enable MRU is greyed out:
and sometimes not:
If I enable MRU then yes, last edited tab will be activated. -
@andi-kiissel said in All bookmarks list view:
I don’t like this Document Switcher.
I’m not sure what you mean by this.
If you don’t like the Ctrl+Tab feature, don’t use it.now I think I found a bug
If you can provide some steps to reproduce, an actual bug report can be created.
-
@alan-kilborn said in All bookmarks list view:
If you don’t like the Ctrl+Tab feature, don’t use it.
I do like Ctrl+Tab feature, but don’t like table like this:
Ctrl+Tab feature works fine without Document Switcher been enabled!If you can provide some steps to reproduce, an actual bug report can be created.
Well, starting position:
Switch off first “Enable”, “Enable MRU…” switches off too and stays grey:
Restart N++, both are available:
And I can switch “Enable MRU…” on alone:
I’m not sure that I can describe this good enough for official bug report. And perhaps there is some logic.Anyway, now I got things work how I like.
Thank you! -
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.