Community
    • Login

    UDL highlight words between 2 keyword

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    udlhighlighting
    2 Posts 2 Posters 392 Views 2 Watching
    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.
    • taigama_coderT Offline
      taigama_coder
      last edited by

      the rule is simple

      • highlight between (space) and (equal) (operator =) as blue
      • highlight between (equal) and (space) as orange
        (equal) remains default

      the sample text are
      id=045 name=“Valencia” offset=3,1 jump=5
      id=046 name=“Zeken” offset=5,4 jump=67

      c5f1d84f-a7da-4f90-b10f-6a93488c7d89-image.png

      I am stucking because:

      • Found no way to use whitespace
      • The highlighter always includes (equal)

      How can I use UDL to fromat it?

      Thank you.

      PeterJonesP 1 Reply Last reply Reply Quote 0
      • PeterJonesP Online
        PeterJones @taigama_coder
        last edited by

        @taigama_coder said in UDL highlight words between 2 keyword:

        How can I use UDL to fromat it?

        That is beyond the capability of UDL: it’s designed for simple keyword and operator highlighting, and what you are asking would require a custom lexer…

        Normally, I would suggest the EnhanceAnyLexer plugin, which allows adding foreground coloring based on regular expressions… but since you are asking to highlight the whitespace, and whitespace by definition is not using the foreground color, I don’t think it’s features would help you.

        1 Reply Last reply Reply Quote 1

        Hello! It looks like you're interested in this conversation, but you don't have an account yet.

        Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

        With your input, this post could be even better 💗

        Register Login
        • First post
          Last post
        The Community of users of the Notepad++ text editor.
        Powered by NodeBB | Contributors