Highlighting other occurences of currently selected word ignores occurences followed by ";"...

  • When I select a word, all other occurences of the word are highlighted. (Very practical while programming to find the occurences of your variables!)

    However, when the word is immediately followed by a semicolon, it gets not highlighted. Why?


  • @Linus-F.

    this functionality searches for the whole word only and
    I assume the language you use treats the semicolon as a char which might be part
    of a word, could this be?


  • Hi Claudia,

    the problem even occurs if you just try it with an empty new document in Notepad++. So it is irrespective of the programming language used. But it does particularly occur with c(++) files, where I guess “;” should not be considered part of a word?

    Is there any way to tell Notepad++ that “;” should not be considered part of a word?


  • Hi Linus,

    in one of the latest version a new section word char list has been added.
    But this it normally used to add new chars.
    Maybe you wanna check if, why ever, there has been the semicolon set.
    If this isn’t the case, by any chance, do you have python script plugin installed?


  • Hi, @linus-f,

    I don’t understand ! I did a try, with a new tab and language = C++

    I inserted the text below, where the first line is the simple string test, only :


    And I confirm that all the occurrences, of the string test, are highlighted in green, except for the two :


    Logic, because, for these two lines, the string test is part of the words 0test0 and test !

    You should verify which options are set/unset in Settings > Preferences… > Highlighting > Smart Highlighting. With the default options, that I’m using, only the options Enable and Match whole word only are checked !

    If you cannot see any problem in your settings, may be an installed plugin could disturb the default N++ behaviour !

    Best Regards,


  • I’ll be damned! Just tried it again, and now it works as expected…


    No idea, what has changed since the last time… Maybe just a glitch?
    Thanks anyway for your assistance.

Log in to reply