Community

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

    Windows .reg recognized, but no syntax highlighting?

    Help wanted · · · – – – · · ·
    2
    4
    542
    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.
    • ytdlder
      ytdlder last edited by

      Hi!

      I’m not sure if this is a bug or whatnot, but I’m sure that it worked before.

      The thing is that Notepad recognized those files as “Registry” language, and there is a definition for that in the “%appdata%\notepad++\stylers.xml”:

          <LexerType name="registry" desc="registry" ext="">
              <WordsStyle name="DEFAULT STYLE" styleID="32" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="DEFAULT" styleID="0" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="COMMENT" styleID="1" fgColor="007F00" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="VALUE NAME" styleID="2" fgColor="0000FF" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="STRING" styleID="3" fgColor="7F007F" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="HEX DIGIT" styleID="4" fgColor="7F0B0C" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="VALUE TYPE" styleID="5" fgColor="00007F" bgColor="FFFFFF" fontName="" fontStyle="1" fontSize="" />
              <WordsStyle name="ADDED KEY" styleID="6" fgColor="530155" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="REMOVED KEY" styleID="7" fgColor="FF0000" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="ESCAPED CHARACTERS IN STRINGS" styleID="8" fgColor="7D8187" bgColor="FFFFFF" fontName="" fontStyle="1" fontSize="" />
              <WordsStyle name="GUID IN KEY PATH" styleID="9" fgColor="7B5F15" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="GUID IN STRING" styleID="10" fgColor="7B5F15" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="PARAMETER" styleID="11" fgColor="0B6561" bgColor="FFFFFF" fontName="" fontStyle="0" fontSize="" />
              <WordsStyle name="OPERATORS" styleID="12" fgColor="000000" bgColor="FFFFFF" fontName="" fontStyle="1" fontSize="" />
          </LexerType>
      

      But there is no highlighting what so ever!

      I’m not proficient with this xml, so I don’t know if “Registry” is actually used for a different file format and that’s why highlighting doesn’t work as there is no definition found (like comments).

      Hopefully someone can figure this out and/or post his “registry” or a new “.reg” definition for proper Windows Registry File syntax highlighting!

      Thank you very much and cheers!

      1 Reply Last reply Reply Quote 2
      • ytdlder
        ytdlder last edited by

        Ok, a quick update:
        I just tried the “Style Configurator” and there seems to be no entry for “Registry”!?

        Btw.: this is a NEW n++ install (v7.6.6 x86)!!

        Ekopalypse 1 Reply Last reply Reply Quote 1
        • Ekopalypse
          Ekopalypse @ytdlder last edited by Ekopalypse

          @ytdlder

          I’ve downloaded the x86 portable version and it seems to be there.
          Would you mind sharing your debug info?

          1 Reply Last reply Reply Quote 1
          • ytdlder
            ytdlder last edited by

            Ok, I got it to work; I just asked a friend to try this…

            The “problem” is, that there is no “Registry” style; at least visible in the UI, as it IS in the XML. The same is true with my friend -> the .reg highlighting works for him, because N++ recognizes them as “.ini” ;-)

            Anyway, the solution for now (for me at least):
            o) open the Style Configurator
            o) change ANY color for any language and SAVE
            o) optionally(?) restart N++
            o) now “Registry” is visible in the Style Configurator & the highlighting works!!


            further info: when comparing the “default” stylers.xml with the newly Notepad++ saved one, then there are several differences throughout the .xml
            -> maybe it’s “damaged” somewhere?

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