syntax: man: colorize also the .MT .ME .EX .EE .SY .OP and .YS macros

Furthermore, colorize .LP .P and .PP like .TP, as paragraph macros,
instead of inconsistenly as if they specified type faces.
This commit is contained in:
Benno Schulenberg 2023-11-04 14:29:45 +01:00
parent 4ddd61cfde
commit f69a08fc63

View File

@ -6,19 +6,19 @@ syntax man "\.[1-9]x?$"
magic "troff or preprocessor input" magic "troff or preprocessor input"
comment ".\"" comment ".\""
# Section headers, title line, and indented paragraphs. # Section headers, title line, and paragraphs.
color green "^\.(SH|SS|TH) .*" color green "^\.(SH|SS|TH) .*"
color brightgreen "^\.((SH|SS|TH) |[HIT]P)" color brightgreen "^\.((SH|SS|TH) |[HIT]P|TQ|LP$|P?P$)"
# Type faces, and normal paragraphs. # Type faces, and synopses.
color brightred "^\.(B[IR]?|I[BR]?|R[BI]|S[BM]) .*" color brightred "^\.(B[IR]?|I[BR]?|RB|RI|SB|SM|SY|OP) .*"
color brightblue "^\.((B[IR]?|I[BR]?|R[BI]|S[BM]) |[LP]?P$)" color brightblue "^\.((B[IR]?|I[BR]?|RB|RI|SB|SM|SY|OP) |YS$)"
# Inline type faces. # Inline type faces.
color magenta "\\f[BIPR]" color magenta "\\f[BIPR]"
# Hyphenation control. # Hyphenation control.
color purple "\\[%:]" color purple "\\[%:]"
color yellow "^\.(hc|hla|hlm|hw|hy)" color yellow "^\.(hc|hla|hlm|hw|hy)"
# Relative margins, hyperlinks, and various other stuff. # Relative margins, hyperlinks, and various other stuff.
color yellow "^\.(RS|RE|UR|UE|PD|DT)" color yellow "^\.(RS|RE|UR|UE|MT|ME|EX|EE|PD|DT)"
color yellow "^\.(ad|bp|br|ce|de|ds|el|ie|if|fi|ft|ig|in|na|ne|nf|nh|ps|so|sp|ti|tr)" color yellow "^\.(ad|bp|br|ce|de|ds|el|ie|if|fi|ft|ig|in|na|ne|nf|nh|ps|so|sp|ti|tr)"
# Comments. # Comments.