1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66
|
# SML mode
#
# Chris Inacio
# inacio@ece.cmu.edu
colorize SML
{
SyntaxParser = 'SIMPLE';
color
{
{'Normal', 'Editor_Default'},
{'Number', 'Lang_DecimalNumber'},
{'Punctuation','Lang_Preprocessor'},
{'String','Lang_String'},
{'Comment','Lang_Comment'},
{'Label','Lang_Label'},
{'Function','Lang_Function'}
};
keyword 'Editor_Keywords'
{
'structure', 'and', 'local', 'in', 'end', 'signature', 'functor',
'struct', 'let', 'sig', 'where type', 'val', 'eqtype', 'type',
'datatype', 'exception', 'sharing', 'include', 'fun', 'abstype',
'open', 'infix', 'infixr', 'nonfix', 'raise', 'if', 'while',
'case', 'fn', 'op',
};
h_state 0 {'Normal'}
h_trans {1, '>', '(*', 'Comment'}
h_trans {2, '', '"', 'String'}
h_trans {3, 's', '0-9', 'Number'}
h_trans {0, 'S', '_a-zA-Z0-9', 'Punctuation'}
h_trans {4, '-s', 'a-zA-Z_', 'Normal' }
h_state 1 {'Comment'}
h_trans {0, '<', '*)', 'Comment'}
h_state 2 {'String'}
h_trans {0, '', '"', 'String'}
h_state 3 {'Number'}
h_trans {0, 'S-', '0-9\.', 'Number'}
h_state 4 { 'Normal' }
h_trans { 0, '$', '', 'Normal' }
h_wtype { 0, 0, 0, 'i', 'a-zA-Z0-9_' }
}
mode SML: SOURCE {
FileNameRx = /\.\c{SML}$/;
HilitOn = 1;
Colorizer = 'SML';
AutoIndent = 1;
IndentMode = 'PLAIN';
MatchCase = 1;
Trim = 1;
MultiLineHilit = 1;
AutoHilitParen = 1;
SaveFolds = 2;
CommentStart = ' (*';
CommentEnd = '*)';
}
oinclude 'mym_sml.fte';
|