! Syntax Highlighting Patterns for Nuweb ! ! Contributed by Reuben Thomas (rrt@sc3d.org); just a small change to the ! LaTeX patterns ! ! (Note: the author also finds it useful to set wrap to "Continuous" in LaTeX ! and Nuweb modes) ! ! In NEdit Version 5.0.1 and beyond, load this pattern by starting nedit with: ! ! nedit -import ! ! Then, check that the patterns were loaded correctly, and choose Save Defaults ! from the Preferences menu. The new patterns will now be incorporated into ! your own .nedit file, so the next time you start NEdit, you will no longer ! need to use -import. ! ! In version 5.0, without -import, you must edit your .nedit file by hand and ! add the contents of each resource below to the corresponding list in your ! .nedit file. Be sure to separate new entries with \n, and continue resource ! strings by escaping all newlines within a resource value with \ (backslash), ! leaving only the last line of the resource value not ending in \. ! nedit.highlightPatterns: \ Nuweb:1:0{\n\ Comment:"%":"$"::Text Comment::\n\ Parameter:"#[0-9]*":::Text Arg::\n\ Special Chars:"[{}&]":::Text Arg::\n\ Escape Chars:"\\\\[$&%#_{}]":::Text Escape::\n\ Super Sub 1 Char:"(\\^|_)[^{]":::Text Arg2::\n\ Verbatim Begin End:"\\\\begin{verbatim\\*?}":"\\\\end{verbatim\\*?}"::Plain::\n\ Verbatim Color:"\\0":"\\0"::Keyword:Verbatim Begin End:C\n\ Verbatim 1:"\\\\verb\\*?`":"`"::Plain::\n\ Verbatim 1 Color:"\\0":"\\0"::Keyword:Verbatim 1:C\n\ Verbatim 2:"\\\\verb\\*?#":"#"::Plain::\n\ Verbatim 2 Color:"\\0":"\\0"::Keyword:Verbatim 2:C\n\ Verbatim 3:"\\\\verb\\*?/":"/"::Plain::\n\ Verbatim 3 Color:"\\0":"\\0"::Keyword:Verbatim 3:C\n\ Verbatim 4:"¦":"¦":"\\n\\n":Plain::\n\ Code fragment:"@{":"@}"::Plain::\n\ Fragment Color:"\\0":"\\0"::Text Key:Code fragment:C\n\ Identifier list:"@\\|":::Text Key:Code fragment:\n\ Fragment macro:"@\\<":"@\\>"::Comment:Code fragment:\n\ Inline Math:"\\$":"\\$":"\\n\\n":LaTeX Math::\n\ Math Color:"\\0":"\\0"::Keyword:Inline Math:C\n\ Inline Math1:"\\\\\\(":"\\\\\\)"::LaTeX Math::\n\ Math1 Color:"\\0":"\\0"::Keyword:Inline Math1:C\n\ Math Escape Chars:"\\\\\\$":::Text Escape:Inline Math:\n\ No Arg Command:"\\\\(left|right)[\\[\\]{}()]":::Text Key::\n\ Command:"[_^]|[\\\\@](a'|a`|a=|[A-Za-z]+\\*?|\\\\\\*|[-@_='`^""|\\[\\]*:!+<>/~.,\\\\ ])":"nevermatch":"[^{[(]":Text Key::\n\ Cmd Brace Args:"{":"}"::Text Arg2:Command:\n\ Brace Color:"\\0":"\\0"::Text Arg:Cmd Brace Args:C\n\ Cmd Paren Args:"\\(":"\\)":"$":Text Arg2:Command:\n\ Paren Color:"\\0":"\\0"::Text Arg:Cmd Paren Args:C\n\ Cmd Bracket Args:"\\[":"\\]":"$":Text Arg2:Command:\n\ Bracket Color:"\\0":"\\0"::Text Arg:Cmd Bracket Args:C\n\ Sub Command:"([_^]|([\\\\@]([A-Za-z]+\\*?|[^A-Za-z$&%#{}~\\\\ \\t])))":::Text Key1:Cmd Brace Args:\n\ Sub Brace:"{":"}"::Text Arg2:Cmd Brace Args:\n\ Sub Sub Brace:"{":"}"::Text Arg2:Sub Brace:\n\ Sub Paren:"\\(":"\\)":"$":Text Arg2:Cmd Paren Args:\n\ Sub Sub Paren:"\\(":"\\)":"$":Text Arg2:Sub Paren:\n\ Sub Parameter:"#[0-9]*":::Text Arg:Cmd Brace Args:\n\ Sub Spec Chars:"[{}$&]":::Text Arg:Cmd Brace Args:\n\ Sub Esc Chars:"\\\\[$&%#_{}~^\\\\]":::Text Arg1:Cmd Brace Args:\n\ } nedit.languageModes: Nuweb:.w::::::