PageRenderTime 68ms CodeModel.GetById 63ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/jEdit/tags/jedit-4-2-pre4/modes/cplusplus.xml

#
XML | 151 lines | 146 code | 3 blank | 2 comment | 0 complexity | a252264340911fa9c5f1dee68cb78869 MD5 | raw file
  1<?xml version="1.0"?>
  2
  3<!DOCTYPE MODE SYSTEM "xmode.dtd">
  4
  5<MODE>
  6	<PROPS>
  7		<PROPERTY NAME="commentStart" VALUE="/*" />
  8		<PROPERTY NAME="commentEnd" VALUE="*/" />
  9		<PROPERTY NAME="lineComment" VALUE="//" />
 10		<PROPERTY NAME="wordBreakChars" VALUE=",+-=&lt;&gt;/?^&amp;*" />
 11
 12		<!-- Auto indent -->
 13		<PROPERTY NAME="indentOpenBrackets" VALUE="{" />
 14		<PROPERTY NAME="indentCloseBrackets" VALUE="}" />
 15		<PROPERTY NAME="indentNextLine"
 16			VALUE="\s*(((if|while)\s*\(|else\s*|else\s+if\s*\(|for\s*\(.*\))[^{;]*)" />
 17		<!-- set this to 'true' if you want to use GNU coding style -->
 18		<PROPERTY NAME="doubleBracketIndent" VALUE="false" />
 19		<PROPERTY NAME="lineUpClosingBracket" VALUE="true" />
 20	</PROPS>
 21	<RULES ESCAPE="\"
 22		IGNORE_CASE="FALSE"
 23		HIGHLIGHT_DIGITS="TRUE"
 24		DIGIT_RE="(0x[[:xdigit:]]+[lL]?|[[:digit:]]+(e[[:digit:]]*)?[lLdDfF]?)">
 25
 26		<!-- C style comment -->
 27		<SPAN TYPE="COMMENT1">
 28			<BEGIN>/*</BEGIN>
 29			<END>*/</END>
 30		</SPAN>
 31
 32		<SPAN TYPE="LITERAL1" NO_LINE_BREAK="TRUE">
 33			<BEGIN>"</BEGIN>
 34			<END>"</END>
 35		</SPAN>
 36		<SPAN TYPE="LITERAL1" NO_LINE_BREAK="TRUE">
 37			<BEGIN>'</BEGIN>
 38			<END>'</END>
 39		</SPAN>
 40
 41		<!-- preprocessor statements -->
 42		<EOL_SPAN TYPE="KEYWORD2" DELEGATE="c::CPP">#</EOL_SPAN>
 43
 44		<EOL_SPAN TYPE="COMMENT2">//</EOL_SPAN>
 45		<SEQ TYPE="OPERATOR">=</SEQ>
 46		<SEQ TYPE="OPERATOR">!</SEQ>
 47		<SEQ TYPE="OPERATOR">&gt;=</SEQ>
 48		<SEQ TYPE="OPERATOR">&lt;=</SEQ>
 49		<SEQ TYPE="OPERATOR">+</SEQ>
 50		<SEQ TYPE="OPERATOR">-</SEQ>
 51		<SEQ TYPE="OPERATOR">/</SEQ>
 52
 53		<SEQ TYPE="OPERATOR">*</SEQ>
 54		<SEQ TYPE="OPERATOR">&gt;</SEQ>
 55		<SEQ TYPE="OPERATOR">&lt;</SEQ>
 56		<SEQ TYPE="OPERATOR">%</SEQ>
 57		<SEQ TYPE="OPERATOR">&amp;</SEQ>
 58		<SEQ TYPE="OPERATOR">|</SEQ>
 59		<SEQ TYPE="OPERATOR">^</SEQ>
 60		<SEQ TYPE="OPERATOR">~</SEQ>
 61		<SEQ TYPE="OPERATOR">}</SEQ>
 62		<SEQ TYPE="OPERATOR">{</SEQ>
 63		
 64		<MARK_PREVIOUS TYPE="FUNCTION">::</MARK_PREVIOUS>
 65		
 66		<MARK_PREVIOUS AT_WHITESPACE_END="TRUE"
 67			EXCLUDE_MATCH="TRUE"
 68			TYPE="LABEL">:</MARK_PREVIOUS>
 69
 70		<!-- Function calls -->
 71		<MARK_PREVIOUS TYPE="FUNCTION" EXCLUDE_MATCH="TRUE">(</MARK_PREVIOUS>
 72
 73		<KEYWORDS>
 74			<KEYWORD3>and</KEYWORD3>
 75			<KEYWORD3>and_eq</KEYWORD3>
 76			<KEYWORD2>asm</KEYWORD2>
 77			<KEYWORD1>auto</KEYWORD1>
 78			<KEYWORD3>bitand</KEYWORD3>
 79			<KEYWORD3>bitor</KEYWORD3>
 80			<KEYWORD3>bool</KEYWORD3>
 81			<KEYWORD1>break</KEYWORD1>
 82			<KEYWORD1>case</KEYWORD1>
 83			<KEYWORD1>catch</KEYWORD1>
 84			<KEYWORD3>char</KEYWORD3>
 85			<KEYWORD3>class</KEYWORD3>
 86			<KEYWORD3>compl</KEYWORD3>
 87			<KEYWORD1>const</KEYWORD1>
 88			<KEYWORD3>const_cast</KEYWORD3>
 89			<KEYWORD1>continue</KEYWORD1>
 90			<KEYWORD1>default</KEYWORD1>
 91			<KEYWORD1>delete</KEYWORD1>
 92			<KEYWORD1>do</KEYWORD1>
 93			<KEYWORD3>double</KEYWORD3>
 94			<KEYWORD3>dynamic_cast</KEYWORD3>
 95			<KEYWORD1>else</KEYWORD1>
 96			<KEYWORD3>enum</KEYWORD3>
 97			<KEYWORD1>explicit</KEYWORD1>
 98			<KEYWORD2>export</KEYWORD2>
 99			<KEYWORD2>extern</KEYWORD2>
100			<LITERAL2>false</LITERAL2>
101			<KEYWORD3>float</KEYWORD3>
102			<KEYWORD1>for</KEYWORD1>
103			<KEYWORD1>friend</KEYWORD1>
104			<KEYWORD1>goto</KEYWORD1>
105			<KEYWORD1>if</KEYWORD1>
106			<KEYWORD1>inline</KEYWORD1>
107			<KEYWORD3>int</KEYWORD3>
108			<KEYWORD3>long</KEYWORD3>
109			<KEYWORD3>mutable</KEYWORD3>
110			<KEYWORD2>namespace</KEYWORD2>
111			<KEYWORD1>new</KEYWORD1>
112			<KEYWORD3>not</KEYWORD3>
113			<KEYWORD3>not_eq</KEYWORD3>
114			<KEYWORD3>operator</KEYWORD3>
115			<KEYWORD3>or</KEYWORD3>
116			<KEYWORD3>or_eq</KEYWORD3>
117			<KEYWORD1>private</KEYWORD1>
118			<KEYWORD1>protected</KEYWORD1>
119			<KEYWORD1>public</KEYWORD1>
120			<KEYWORD1>register</KEYWORD1>
121			<KEYWORD3>reinterpret_cast</KEYWORD3>
122			<KEYWORD1>return</KEYWORD1>
123			<KEYWORD3>short</KEYWORD3>
124			<KEYWORD3>signed</KEYWORD3>
125			<KEYWORD1>sizeof</KEYWORD1>
126			<KEYWORD1>static</KEYWORD1>
127			<KEYWORD3>static_cast</KEYWORD3>
128			<KEYWORD3>struct</KEYWORD3>
129			<KEYWORD1>switch</KEYWORD1>
130			<KEYWORD3>template</KEYWORD3>
131			<LITERAL2>this</LITERAL2>
132			<KEYWORD1>throw</KEYWORD1>
133			<LITERAL2>true</LITERAL2>
134			<KEYWORD1>try</KEYWORD1>
135			<KEYWORD3>typedef</KEYWORD3>
136			<KEYWORD3>typeid</KEYWORD3>
137			<KEYWORD3>typename</KEYWORD3>
138			<KEYWORD3>union</KEYWORD3>
139			<KEYWORD3>unsigned</KEYWORD3>
140			<KEYWORD2>using</KEYWORD2>
141			<KEYWORD1>virtual</KEYWORD1>
142			<KEYWORD1>void</KEYWORD1>
143			<KEYWORD1>volatile</KEYWORD1>
144			<KEYWORD3>wchar_t</KEYWORD3>
145			<KEYWORD1>while</KEYWORD1>
146			<KEYWORD3>xor</KEYWORD3>
147			<KEYWORD3>xor_eq</KEYWORD3>
148			<LITERAL2>NULL</LITERAL2>
149		</KEYWORDS>
150	</RULES>
151</MODE>