Community
    • Login

    Duplicate phrases

    Scheduled Pinned Locked Moved Notepad++ & Plugin Development
    9 Posts 2 Posters 5.5k 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.
    • Peter XP
      Peter X
      last edited by

      Hello,

      Is there a plugin that highlight duplicated phrases in a text file? I mean if the row will contain some different text and also words in duplicated order as on some other row(same sentence), then program will highlight this pieces of text.

      Thanks for reply

      Claudia FrankC 1 Reply Last reply Reply Quote 0
      • Claudia FrankC
        Claudia Frank @Peter X
        last edited by

        @Peter-X

        not sue if I understood correctly but what about

        • select the word(s) you want to be highlighted
        • right click on selection and use one of the
        • defined Style Tokens ?

        Cheers
        Claudia

        1 Reply Last reply Reply Quote 0
        • Peter XP
          Peter X
          last edited by

          Your solution just make the same thing like find the words via ctrl+F - find the same words, but I want to see all duplicated words/sentences.

          For better understanding of what I meant:

          Text file content:

          " I visited their hometown yesterday. My father waited till I come back. This text was written by me."
          " Everyone in this town has a garden. This text was written by me. My father waited till I come back"

          1 Reply Last reply Reply Quote 0
          • Claudia FrankC
            Claudia Frank
            last edited by

            So in your example you do have two sentences which appear twice.
            But what do you want to achieve? Having both sentences highlighted
            without user interaction? Having only one sentence colored?
            I assume you need to be more specific about this.

            Cheers
            Claudia

            1 Reply Last reply Reply Quote 0
            • Peter XP
              Peter X
              last edited by

              I want to see all same sentences highlighted - if there is 50 random sentences with some number of repeating, then I want to see all the sentences with same word order. Making it word after word is slow and unpractic.

              1 Reply Last reply Reply Quote 0
              • Claudia FrankC
                Claudia Frank
                last edited by

                What prevents you from selecting the sentence instead of a single word and do the styling?
                There are only 5 predefined styles that’s for sure but I don’t see that this can’t be achieved
                using this technique.

                Cheers
                Claudia

                1 Reply Last reply Reply Quote 0
                • Peter XP
                  Peter X
                  last edited by

                  For example, if the previos sample text will have 50 variants (other same sentences) then I want to see immediately all duplicated sentences (not rows) which are used more then once in whole text file.

                  1 Reply Last reply Reply Quote 0
                  • Claudia FrankC
                    Claudia Frank
                    last edited by

                    Npp doesn’t have it natively and I strongly believe that there isn’t a plugin available as well.

                    Cheers
                    Claudia

                    1 Reply Last reply Reply Quote 0
                    • Peter XP
                      Peter X
                      last edited by Peter X

                      Okay, thanks, time to make it! :D No, really it would be really usefull if you can see all the dups sentences without user any action at start and know if there are some other existences of the same phrases. The ability to check dups in other text editors just check the whole rows but it’s bad because if you have some small diference at start of the line and then you have the duplicated sentence behind that, program will not notice that as dup and it doesn’t find anything.

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