2020-04-20 20:15:43 +03:00
|
|
|
## Syntax highlighting for groff.
|
2014-05-17 00:21:34 +04:00
|
|
|
|
2021-10-25 11:24:17 +03:00
|
|
|
syntax groff "\.(m[ems]|rof|tmac)$|/tmac\.[^/]+$"
|
2017-07-06 22:35:07 +03:00
|
|
|
comment ".\""
|
2014-05-17 00:21:34 +04:00
|
|
|
|
2022-02-16 14:29:14 +03:00
|
|
|
# The setting of a string or register
|
2015-05-03 18:47:05 +03:00
|
|
|
color cyan "^\.(ds|nr) [^[:space:]]*"
|
2014-05-17 00:21:34 +04:00
|
|
|
# Single-character escapes
|
2006-06-01 21:23:28 +04:00
|
|
|
color brightmagenta "\\."
|
2014-05-17 00:21:34 +04:00
|
|
|
# The argument of \f or \s in the same color
|
2022-02-16 14:29:14 +03:00
|
|
|
color brightmagenta "\\f(.|\(..)|\\s(\+|\-)?[0-9]"
|
|
|
|
# References to registers
|
2020-04-21 13:47:08 +03:00
|
|
|
color cyan "\\(\\)?n(.|\(..)"
|
|
|
|
color cyan start="\\(\\)?n\[" end="]"
|
2014-05-17 00:21:34 +04:00
|
|
|
# Requests
|
2021-04-27 12:18:41 +03:00
|
|
|
color brightgreen "^\.[[:blank:]]*[^[:space:]]*"
|
2014-05-17 00:21:34 +04:00
|
|
|
# Comments
|
2018-11-03 23:12:44 +03:00
|
|
|
color yellow "^\.\\".*"
|
2022-02-16 14:29:14 +03:00
|
|
|
# References to strings
|
2020-04-21 13:47:08 +03:00
|
|
|
color green "\\(\\)?\*(.|\(..)"
|
|
|
|
color green start="\\(\\)?\*\[" end="]"
|
2022-02-16 14:29:14 +03:00
|
|
|
# Special characters
|
2006-06-01 21:23:28 +04:00
|
|
|
color brightred "\\\(.."
|
|
|
|
color brightred start="\\\[" end="]"
|
2014-05-17 00:21:34 +04:00
|
|
|
# Macro arguments
|
2006-06-01 21:23:28 +04:00
|
|
|
color brightcyan "\\\\\$[1-9]"
|