Community

    • Login
    • Search
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Bookmarks list window

    Help wanted · · · – – – · · ·
    3
    7
    2225
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • EagleXK
      EagleXK last edited by

      Coding in Delphi IDE I’m often using bookmarks for code navigation, it’s Ctrl+Shift+1 to Ctrl+Shift+9 to toggle bookmark and Ctrl+1 to Ctrl+9 to go to bookmark number. I know N++ works in a different manner with bookmarks and I can have much more that 9 of them just pressing Ctrl+F2 to toggle on any row. My main problem is navigation: F2 and Shift+F2 is not enough. I would like to have some window with all bookmark lines with numbers and text (at least first 100 chars) when I can double click on a bookmark and be moved there. Something like “Find results” window (Ctrl+F, Find All in Current Document). Possible someone know how to achieve that or some plugin doing that? Thanks in advance!

      Alan Kilborn 1 Reply Last reply Reply Quote 1
      • Alan Kilborn
        Alan Kilborn @EagleXK last edited by

        @EagleXK

        Try Bookmark Manager plugin?

        1 Reply Last reply Reply Quote 3
        • EagleXK
          EagleXK last edited by

          @Alan Kilborn
          Thank you, but it is not doing what I want. Yes, it allows to use bookmarks similar to Delphi IDE but it still does not list all bookmarks in a single window. Can explain why: I have huge log file with hundred thousands lines and I want to mark some important lines to see only key ones in one list and then be able to navigate to key row to analyze log deeply. Something like that :)

          Eko palypse 1 Reply Last reply Reply Quote 2
          • Eko palypse
            Eko palypse @EagleXK last edited by Eko palypse

            @EagleXK

            by using pythonscript plugin and its internal console you could achieve it with a script like this

            console.clear()
            console.show()
            _filename = notepad.getCurrentFilename()
            markers = []
            bookmarker_id = 1<<24
            markerLine = editor1.markerNext(0, bookmarker_id)
            while markerLine > -1:
                markers.append(markerLine)
                markerLine = editor1.markerNext(markerLine+1, bookmarker_id)
                
            for line in markers:
                print '  File "{}", line {}     {}'.format(_filename, line, editor.getLine(line).strip()[:100])
            

            but don’t know if it is fast enough on large files as haven’t tested it.

            EagleXK 1 Reply Last reply Reply Quote 6
            • Eko palypse
              Eko palypse last edited by

              Little correction:

              print '  File "{}", line {:<10} {}'.format(_filename, line+1, editor.getLine(line).strip()[:100])
              
              1 Reply Last reply Reply Quote 2
              • Eko palypse
                Eko palypse last edited by

                just tested with a file > 5 million lines

                File "... big.txt", line 184        test some text ...
                File "... big.txt", line 2820230    test some text ...
                File "... big.txt", line 3355083    test some text ...
                File "... big.txt", line 4724326    test some text ...
                File "... big.txt", line 5012185    test some text ...
                File "... big.txt", line 5444997    test some text ...
                

                took 0.483000040054 seconds
                Note, output edited because of spam flagged … :-(

                1 Reply Last reply Reply Quote 1
                • EagleXK
                  EagleXK @Eko palypse last edited by

                  @Eko-palypse , that’s amazing! Many thanks, it works perfectly!

                  1 Reply Last reply Reply Quote 1
                  • First post
                    Last post
                  Copyright © 2014 NodeBB Forums | Contributors