Comment or highlight everything from column 81 and later

Comment or highlight everything from column 81 and later

2
NewbieNewbie
2

    Aug 19, 2019#1

    Hi!

    I would like to comment or highlight everything that is located from column 81 and later. See example:

    001 ..\PUSH_COMMON\DFA_PUSH_PATH.INP                                            This text should be commented or a different color

    Only the "This text should be commented or a different color" should be highlighted or have a different color. Any suggestions?

    6,686585
    Grand MasterGrand Master
    6,686585

      Aug 19, 2019#2

      Following could be used in the syntax highlighting wordfile in first line left to File Extensions =

      Code: Select all

      Line Comment Num = 1  Line Comment Valid Columns = [80]
      Note: There are exactly two spaces after 1.

      If a line has at column 80 a space character, everything right starting at column 81 is syntax highlighted as line comment.
      Best regards from an UC/UE/UES for Windows user from Austria

      2
      NewbieNewbie
      2

        Aug 20, 2019#3

        I have already a syntax that comments everything which has three spaces from column 1 to 3 as seen below:

        /L21"TEST" Line Comment Num = 3    : Line Comment Valid Columns = [1] Line Comment Num = 1  Line Comment Valid Columns = [80] String Chars = " DisableMLS File Extensions = INP

        When I include "Line Comment Num = 1  Line Comment Valid Columns = [80]" in the first line it will not change the syntax highlighting for characters comming after column 80. Is there any option for combining these two i.e. both having a syntax highlighting when having three spaces and having a syntax highlighting for every character after column 80?

        6,686585
        Grand MasterGrand Master
        6,686585

          Aug 20, 2019#4

          Please open help page Syntax Highlighting in help of UltraEdit. There is described what can be used in a wordfile. The sticky topic Template for syntax highlighting language wordfile contains even more information.

          It is not possible to use multiple Line Comment Num = and Line Comment Valid Columns =.

          For line comments can be used:
          • Line Comment = or Line Comment Num = x in combination with Line Comment Valid Columns = [a-b,c-d,e-f,g,h,i-j] and/or Line Comment Preceding Chars = [...]
          • Line Comment Alt = in combination with Line Comment Valid Columns Alt = [a-b,c-d,e-f,g,h,i-j] and/or Line Comment Preceding Chars Alt = [...]
          • Block Comment On = with no Block Comment Off =
          • Block Comment On Alt = with no Block Comment Off Alt =
          There is no Line Comment Num Alt = and the block comment strings used for definition of line comments cannot contain a space character because of the space character is the word delimiter in *.uew files. For that reason only one line comment starting string containing one or even more spaces can be defined in a syntax highlighting wordfile.

          If you want highlighted as line comment a line with three spaces at beginning of the line and also everything after column 80 with three spaces at columns 78 to 80, the following definition can be used in the wordfile in first line:

          Code: Select all

          /L20"TEST" Line Comment Num = 3    Line Comment Valid Columns = [1,78] String Chars = " DisableMLS File Extensions = INP
          Note: There are exactly four spaces between 3 and Line and no other character like a colon.

          The language number should be in range 1 to 20 as more languages were not supported in UltraEdit for Windows < v15.00. The language number is not relevant anymore since UE v15.00, but tools like my syntax tools macros still expect a language number in range 1 to 20 for downwards compatibility reasons.
          Best regards from an UC/UE/UES for Windows user from Austria