• Login
Community
  • Login

Clearing Marked Lines

Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
4 Posts 3 Posters 1.2k Views
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.
  • D
    Drake McCleary
    last edited by Aug 8, 2024, 3:44 PM

    In previous versions of Notepad ++ we were able to search for a keyword, mark all lines and clear the marks - in turn leaving us with only all the unmarked lines.

    The newer version is not seeming to clear the lines. Any insight on how to make this possible?

    A P 2 Replies Last reply Aug 8, 2024, 4:01 PM Reply Quote 0
    • A
      Alan Kilborn @Drake McCleary
      last edited by Aug 8, 2024, 4:01 PM

      @Drake-McCleary

      You’re comments are very vague, but try this:

      When you are clearing the bookmarks (i.e., pressing the button to clear), make sure the Bookmark Lines checkbox is checkmarked.

      1 Reply Last reply Reply Quote 2
      • P
        PeterJones @Drake McCleary
        last edited by Aug 8, 2024, 4:06 PM

        @Drake-McCleary ,

        Your use of “clear” is ambiguous. That might mean “clear the marks” as in remove the highlights or circles (like Alan interpreted). Or it might mean “delete the lines that had marked text” (which is how I’m interpreting it).

        In order to be able to do things with the lines of marked text, when you use the Mark dialog, you need to remember to checkmark ☑ Bookmark line as well.

        Then you can do the search to add the marks (highlights) and bookmarks (circles). Then use the Search > Bookmark > … commands (*) to delete the bookmarked or unbookmarked lines. (*: or right-click on the bookmark margin to access the same menu of commands)

        If I have a file with the words one to five on separate lines, and want to delete only the lines that contain the e character, I could:

        1. Mark and Bookmark those lines
          1d305b4a-3bcd-4a5b-92dc-4dfaee7a99ec-image.png
        2. Use the Bookmark menu to Remove the Bookmarked Lines
          8ab8fbd6-8de3-4156-b037-c1629fae6564-image.png
        3. End up with only the non-matching lines:
          bd99107c-f764-4b64-b31b-b94ff7f28d17-image.png

        Using the Remove Non-Bookmarked Lines would do the opposite, deleting two and four and leaving the other three words.

        Hopefully one of us interpreted you correctly.

        D 1 Reply Last reply Sep 4, 2024, 4:06 PM Reply Quote 2
        • D
          Drake McCleary @PeterJones
          last edited by Sep 4, 2024, 4:06 PM

          @PeterJones

          This is exactly what I was looking for - Sorry for the vague description!

          Thanks for the help.

          1 Reply Last reply Reply Quote 1
          • First post
            Last post
          The Community of users of the Notepad++ text editor.
          Powered by NodeBB | Contributors