Community
    • Login

    Styling Questions.

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    6 Posts 3 Posters 4.0k 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.
    • Fields BarleyF
      Fields Barley
      last edited by

      How can I make it so that whenever the character | is written, it will always be bold but still inherit the same font-family? Also, how can I make it so that the selected/highlighted words will be bolded and have a different foreground color? I’m trying to tweak mine right now and it doesn’t work.

      1 Reply Last reply Reply Quote 0
      • dailD
        dail
        last edited by

        Are you trying to modify a specific language? Or all of them? Are you creating a UDL?

        1 Reply Last reply Reply Quote 0
        • Fields BarleyF
          Fields Barley
          last edited by

          No. I don’t even really know what a language is. All I want is that whenever I type | it shows as |.

          Claudia FrankC 1 Reply Last reply Reply Quote 0
          • dailD
            dail
            last edited by

            The lexers for specific languages are what decides what is colored, highlighted, bolded, etc. If you are just editing text files then your best bet is to create a User Defined Language that all it does is make those characters bold. I’ve never created a UDL before so I can’t be any help there.

            1 Reply Last reply Reply Quote 0
            • Claudia FrankC
              Claudia Frank @Fields Barley
              last edited by

              Hello @Fields-Barley,

              may I jump in.

              As already said by dail, a lexer, like UDL, can do this job.

              High level description:
              UDL needs the informations what should be coloured and which
              font and size should be used. Once you’ve done this, your new
              language appears in the language menu. To get your document colored,
              as you’ve defined, you need to either manually click the new language
              every time you want to or you register an file extension then your
              UDL language gets automatically selected when such a file gets opened.

              The description how the UDL works is here

              Short description regarding your wishes:
              In Language menu click on define your language…
              A new window appears.
              Click Create new and give your language a meaningful name.

              Now you see, that a new field Ext. has been created. Here you would define
              your preferred file extension.

              The styler button needs to be used to define the color and font attributes for
              that particular section.

              In Keyword list you would enter the words that should be highlighted in different
              color.

              In Operator section you would defined the single chars like |.
              Strictly spoken, you can define the | also as a keyword if you wish.

              Cheers
              Claudia

              1 Reply Last reply Reply Quote 0
              • Fields BarleyF
                Fields Barley
                last edited by

                Claudia, that was just perfect. Now I’m able to do it.

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