Navigate between section in same file quickly using keyboard shortcuts
-
I wanted section in my text file so I defined a custom function list for .txt files. It checks for “===============” text and consider it as a function.
Now I have 25 functions in my text file. I can see them in functions list.
I want to jump to next/previous function using keyboard shortcut. How do I do it?
P.S. Any other solution that doesn’t involve functions is also acceptable. I just need sections that can be switched via keyboard shortcut
-
Record a macro that searches (e.g. Find Next) for your text of interest, save it, and assign it to run via a keycombo.
-
@VarunAgw said in Navigate between section in same file quickly using keyboard shortcuts:
I want to jump to next/previous function using keyboard shortcut. How do I do it?
My immediate thought would be that you would create a macro and save it with a keyboard shortcut.
The macro would use the “Find all in current document” which is in the “Find” tab. The string searched for would be your special “==========” string.
If you try it, it opens a search window (generally at the bottom of the Notepad++) screen. You can double click on any of the lines found and the actual file will adjust the lines being viewed so that the clicked on line appears, around the middle of the viewing window.
Terry
PS You may even want to add to the special string a title for each function so you would immediately know which search line to click on. Still use the “======” string but append it with a title, and just search on the “=====” portion. This can use “normal” as the search mode since the string doesn’t change.
-
Thanks a lot for the help. It solved my problem. I didn’t realize macros can be so powerful :)
-
@VarunAgw said in Navigate between section in same file quickly using keyboard shortcuts:
I didn’t realize macros can be so powerful
If you are keen on learning more there is the online manual (link under the ? menu). And if you get really keen on learning about regular expressions there are references to books in the FAQ section.
Good luck
TerryPS which solution did you go for?
-
@Terry-R Thanks.
I ended up using @Alan-Kilborn solution since it feels simpler and does the job.
-
@VarunAgw I have been looking for a notes app that implements something like this for at least 15 years. The ability to define custom “Section Headers” paired with a well designed “Section List” side panel to quickly jump between sections.
Feels like every Note app copies every other note app, so the best we get across most of the better note apps is this repurposed function list solution, or jumping into the deep-end with a markdown note app, although markdown feels too heavy for many of the simple, quick text files I find myself creating.
Glad to see I am not alone in this, even if it is just one other person.
-
@n3tcom said:
so the best we get across most of the better note apps is this repurposed function list solution
And so you yearn for something better?
I’m not sure what form that would take, as the function-list solution works reasonably.