Community

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

    NotePad++ 7.5.6 inserts ASCII control codes like "DC3" for Control-S WITHOUT any background dialogues open when Unix-LF (UTF-8 w/o BOM) format is used

    Help wanted · · · – – – · · ·
    bug
    1
    2
    2205
    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.
    • Max South
      Max South last edited by Max South

      Hi there,

      As many of us know, Notepad++ has an old bug – never fixed even to this day – about corrupting texts with ASCII control codes when keyboard shortcuts are used if it has any dialogues open (not just search/replace one). The remedy for years is to close all the dialogues/windows.

      However, I stumbled upon a new way that it manifests itself: if I work on a text file that is Unix-LF (UTF-8 without BOM) format, and I use an AutoHotkey script to catch myself pressing “Control+S” (vk53sc01F) to automatically call a syntax checker plugin JSLint on the file, Notepad++ (the newest, fully updated 7.5.6 version) inserts “DC3” ASCII control code in the text instead of just accepting it is a short-cut and saving my text.

      Interestingly enough, if the format of the text is Windows-CRLF (also UTF-8 without BOM), this never happens, everything works as intended.

      Is there a way to FORCE Notepad++ to never glitch again in this case? So far I am at a loss what can be done. And I do not even know how to ask the developers to fix this bug so they would actually see it and fix it.

      Thanks in advance.

      1 Reply Last reply Reply Quote 0
      • Max South
        Max South last edited by Max South

        PARTIALLY SOLVED:

        It turns out that NP++ executable process returns “ready” state to Windows API before it is actually ready as it still running plugin activity. In my case JSLint’s syntax check of Unix-LF (UTF-8 without BOM) files apparently takes longer versus Windows-CRLF (UTF-8 without BOM) files, and this is how NP++ ends up not being able to process “Control+S” as a short-cut to save the file, but as a text input that shows up as “DC3”, corrupting it. Thus the solution is to use “Sleep 1000” AutoHotKey command before generating “Control+S” key combination or to swap it with the call for JSLint syntax check.

        However, why the underlying issue of NP++ allowing ASCII control codes to be inserted in the text is still not fixed, is still a question. At no circumstances NP++ should allow the corruption of texts by garbage.

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