• Login
Community
  • Login

Help with specifying a new UDL

Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
4 Posts 3 Posters 330 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.
  • K
    Ken Weinert
    last edited by Nov 7, 2022, 8:09 PM

    I have some java debugging that looks like this:

    UnformattedDebugging.png

    And I’d like it to look like this:

    FormattedDebugging.png

    I’ve looked at creating a new UDL but it’s not quite made the connection in my mind. If anyone has a link to something similar that I could base this on that would be appreciated.

    Or any other help - this is basically just a formatting issue, there are no real keywords to find/highlight/etc.

    Your thoughts are very much appreciated.

    P 1 Reply Last reply Nov 7, 2022, 8:25 PM Reply Quote 0
    • P
      PeterJones @Ken Weinert
      last edited by PeterJones Nov 7, 2022, 8:39 PM Nov 7, 2022, 8:25 PM

      @Ken-Weinert ,

      UDLs are for syntax highlighting (defining keywords, and having Notepad++ show the text in different colors depending on those keywords and the styler settings).

      The change you showed was more of a “pretty print” feature, which doesn’t exist in Notepad++, for any languages. Some languages have plugins which will do a pretty print (such as XML and HTML and JSON). But Notepad++ doesn’t have that feature natively, so Notepad++ has no way to automatically make the transformation for your particular language.

      You could try to develop a search-and-replace regular expression that might be able to handle it – but it would be rather complicated (I just spent 5-10 minutes, but couldn’t even come up with a multistep sequence that did something reasonable.)

      K 1 Reply Last reply Nov 7, 2022, 9:10 PM Reply Quote 1
      • K
        Ken Weinert @PeterJones
        last edited by Nov 7, 2022, 9:10 PM

        @PeterJones Thanks. I looked a JSON and the definition and didn’t see how it would ever do the formatting. Now knowing that it’s a plugin helps give me direction on where I need to investigate next.

        Thank you. As you can probably tell this is my first foray into the internals of the editor :) Very much appreciate the assistance.

        M 1 Reply Last reply Nov 7, 2022, 9:25 PM Reply Quote 0
        • M
          Michael Vincent @Ken Weinert
          last edited by Nov 7, 2022, 9:25 PM

          @Ken-Weinert said in Help with specifying a new UDL:

          Now knowing that it’s a plugin

          If it’s JSON you want, there is a JSON pretty-print feature in JSONTools .

          Cheers.

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