micro/runtime/syntax/groff.micro

25 lines
792 B
Text
Raw Normal View History

2016-03-21 16:16:02 +00:00
## Here is an example for groff.
##
syntax "groff" "\.m[ems]$" "\.rof" "\.tmac$" "^tmac."
2016-03-21 16:16:02 +00:00
## The argument of .ds or .nr
color statement "^\.(ds|nr) [^[[:space:]]]*"
2016-03-21 16:16:02 +00:00
## Single character escapes
color constant.specialChar "\\."
2016-03-21 16:16:02 +00:00
## Highlight the argument of \f or \s in the same color
color constant.specialChar "\\f." "\\f\(.." "\\s(\+|\-)?[0-9]"
2016-03-21 16:16:02 +00:00
## Newlines
color constant "(\\|\\\\)n(.|\(..)"
color constant start="(\\|\\\\)n\[" end="]"
2016-03-21 16:16:02 +00:00
## Requests
color type "^\.[[:space:]]*[^[[:space:]]]*"
2016-03-21 16:16:02 +00:00
## Comments
color comment "^\.\\".*$"
2016-03-21 16:16:02 +00:00
## Strings
color constant.string "(\\|\\\\)\*(.|\(..)"
color constant.string start="(\\|\\\\)\*\[" end="]"
2016-03-21 16:16:02 +00:00
## Characters
color constant.specialChar "\\\(.."
color constant.specialChar start="\\\[" end="]"
2016-03-21 16:16:02 +00:00
## Macro arguments
color identifier.macro "\\\\\$[1-9]"