7
|
1 " Vim syntax file
|
|
2 " Language: CA-OpenROAD
|
|
3 " Maintainer: Luis Moreno <lmoreno@eresmas.net>
|
|
4 " Last change: 2001 Jun 12
|
|
5
|
|
6 " For version 5.x: Clear all syntax items
|
|
7 " For version 6.x: Quit when a syntax file was already loaded
|
|
8 "
|
|
9 if version < 600
|
|
10 syntax clear
|
|
11 elseif exists("b:current_syntax")
|
|
12 finish
|
|
13 endif
|
|
14
|
|
15 syntax case ignore
|
|
16
|
|
17 " Keywords
|
|
18 "
|
|
19 syntax keyword openroadKeyword ABORT ALL ALTER AND ANY AS ASC AT AVG BEGIN
|
|
20 syntax keyword openroadKeyword BETWEEN BY BYREF CALL CALLFRAME CALLPROC CASE
|
|
21 syntax keyword openroadKeyword CLEAR CLOSE COMMIT CONNECT CONTINUE COPY COUNT
|
|
22 syntax keyword openroadKeyword CREATE CURRENT DBEVENT DECLARE DEFAULT DELETE
|
|
23 syntax keyword openroadKeyword DELETEROW DESC DIRECT DISCONNECT DISTINCT DO
|
|
24 syntax keyword openroadKeyword DROP ELSE ELSEIF END ENDCASE ENDDECLARE ENDFOR
|
|
25 syntax keyword openroadKeyword ENDIF ENDLOOP ENDWHILE ESCAPE EXECUTE EXISTS
|
|
26 syntax keyword openroadKeyword EXIT FETCH FIELD FOR FROM GOTOFRAME GRANT GROUP
|
|
27 syntax keyword openroadKeyword HAVING IF IMMEDIATE IN INDEX INITIALISE
|
|
28 syntax keyword openroadKeyword INITIALIZE INQUIRE_INGRES INQUIRE_SQL INSERT
|
|
29 syntax keyword openroadKeyword INSERTROW INSTALLATION INTEGRITY INTO KEY LIKE
|
|
30 syntax keyword openroadKeyword LINK MAX MESSAGE METHOD MIN MODE MODIFY NEXT
|
|
31 syntax keyword openroadKeyword NOECHO NOT NULL OF ON OPEN OPENFRAME OR ORDER
|
|
32 syntax keyword openroadKeyword PERMIT PROCEDURE PROMPT QUALIFICATION RAISE
|
|
33 syntax keyword openroadKeyword REGISTER RELOCATE REMOVE REPEAT REPEATED RESUME
|
|
34 syntax keyword openroadKeyword RETURN RETURNING REVOKE ROLE ROLLBACK RULE SAVE
|
|
35 syntax keyword openroadKeyword SAVEPOINT SELECT SET SLEEP SOME SUM SYSTEM TABLE
|
|
36 syntax keyword openroadKeyword THEN TO TRANSACTION UNION UNIQUE UNTIL UPDATE
|
|
37 syntax keyword openroadKeyword VALUES VIEW WHERE WHILE WITH WORK
|
|
38
|
|
39 syntax keyword openroadTodo contained TODO
|
|
40
|
|
41 " Catch errors caused by wrong parenthesis
|
|
42 "
|
|
43 syntax cluster openroadParenGroup contains=openroadParenError,openroadTodo
|
|
44 syntax region openroadParen transparent start='(' end=')' contains=ALLBUT,@openroadParenGroup
|
|
45 syntax match openroadParenError ")"
|
|
46 highlight link openroadParenError cError
|
|
47
|
|
48 " Numbers
|
|
49 "
|
|
50 syntax match openroadNumber "\<[0-9]\+\>"
|
|
51
|
|
52 " String
|
|
53 "
|
|
54 syntax region openroadString start=+'+ end=+'+
|
|
55
|
|
56 " Operators, Data Types and Functions
|
|
57 "
|
|
58 syntax match openroadOperator /[\+\-\*\/=\<\>;\(\)]/
|
|
59
|
|
60 syntax keyword openroadType ARRAY BYTE CHAR DATE DECIMAL FLOAT FLOAT4
|
|
61 syntax keyword openroadType FLOAT8 INT1 INT2 INT4 INTEGER INTEGER1
|
|
62 syntax keyword openroadType INTEGER2 INTEGER4 MONEY OBJECT_KEY
|
|
63 syntax keyword openroadType SECURITY_LABEL SMALLINT TABLE_KEY VARCHAR
|
|
64
|
|
65 syntax keyword openroadFunc IFNULL
|
|
66
|
|
67 " System Classes
|
|
68 "
|
|
69 syntax keyword openroadClass ACTIVEFIELD ANALOGFIELD APPFLAG APPSOURCE
|
|
70 syntax keyword openroadClass ARRAYOBJECT ATTRIBUTEOBJECT BARFIELD
|
|
71 syntax keyword openroadClass BITMAPOBJECT BOXTRIM BREAKSPEC BUTTONFIELD
|
|
72 syntax keyword openroadClass CELLATTRIBUTE CHOICEBITMAP CHOICEDETAIL
|
|
73 syntax keyword openroadClass CHOICEFIELD CHOICEITEM CHOICELIST CLASS
|
|
74 syntax keyword openroadClass CLASSSOURCE COLUMNCROSS COLUMNFIELD
|
|
75 syntax keyword openroadClass COMPOSITEFIELD COMPSOURCE CONTROLBUTTON
|
|
76 syntax keyword openroadClass CROSSTABLE CURSORBITMAP CURSOROBJECT DATASTREAM
|
|
77 syntax keyword openroadClass DATEOBJECT DBEVENTOBJECT DBSESSIONOBJECT
|
|
78 syntax keyword openroadClass DISPLAYFORM DYNEXPR ELLIPSESHAPE ENTRYFIELD
|
|
79 syntax keyword openroadClass ENUMFIELD EVENT EXTOBJECT EXTOBJFIELD
|
|
80 syntax keyword openroadClass FIELDOBJECT FLEXIBLEFORM FLOATOBJECT FORMFIELD
|
|
81 syntax keyword openroadClass FRAMEEXEC FRAMEFORM FRAMESOURCE FREETRIM
|
|
82 syntax keyword openroadClass GHOSTEXEC GHOSTSOURCE IMAGEFIELD IMAGETRIM
|
|
83 syntax keyword openroadClass INTEGEROBJECT LISTFIELD LISTVIEWCOLATTR
|
|
84 syntax keyword openroadClass LISTVIEWFIELD LONGBYTEOBJECT LONGVCHAROBJECT
|
|
85 syntax keyword openroadClass MATRIXFIELD MENUBAR MENUBUTTON MENUFIELD
|
|
86 syntax keyword openroadClass MENUGROUP MENUITEM MENULIST MENUSEPARATOR
|
|
87 syntax keyword openroadClass MENUSTACK MENUTOGGLE METHODEXEC METHODOBJECT
|
|
88 syntax keyword openroadClass MONEYOBJECT OBJECT OPTIONFIELD OPTIONMENU
|
|
89 syntax keyword openroadClass PALETTEFIELD POPUPBUTTON PROC4GLSOURCE PROCEXEC
|
|
90 syntax keyword openroadClass PROCHANDLE QUERYCOL QUERYOBJECT QUERYPARM
|
|
91 syntax keyword openroadClass QUERYTABLE RADIOFIELD RECTANGLESHAPE ROWCROSS
|
|
92 syntax keyword openroadClass SCALARFIELD SCOPE SCROLLBARFIELD SEGMENTSHAPE
|
|
93 syntax keyword openroadClass SESSIONOBJECT SHAPEFIELD SLIDERFIELD SQLSELECT
|
|
94 syntax keyword openroadClass STACKFIELD STRINGOBJECT SUBFORM TABBAR
|
|
95 syntax keyword openroadClass TABFIELD TABFOLDER TABLEFIELD TABPAGE
|
|
96 syntax keyword openroadClass TOGGLEFIELD TREE TREENODE TREEVIEWFIELD
|
|
97 syntax keyword openroadClass USERCLASSOBJECT USEROBJECT VIEWPORTFIELD
|
|
98
|
|
99 " System Events
|
|
100 "
|
|
101 syntax keyword openroadEvent CHILDCLICK CHILDCLICKPOINT CHILDCOLLAPSED
|
|
102 syntax keyword openroadEvent CHILDDETAILS CHILDDOUBLECLICK CHILDDRAGBOX
|
|
103 syntax keyword openroadEvent CHILDDRAGSEGMENT CHILDENTRY CHILDEXIT
|
|
104 syntax keyword openroadEvent CHILDEXPANDED CHILDHEADERCLICK CHILDMOVED
|
|
105 syntax keyword openroadEvent CHILDPROPERTIES CHILDRESIZED CHILDSCROLL
|
|
106 syntax keyword openroadEvent CHILDSELECT CHILDSELECTIONCHANGED CHILDSETVALUE
|
|
107 syntax keyword openroadEvent CHILDUNSELECT CHILDVALIDATE CLICK CLICKPOINT
|
|
108 syntax keyword openroadEvent COLLAPSED DBEVENT DETAILS DOUBLECLICK DRAGBOX
|
|
109 syntax keyword openroadEvent DRAGSEGMENT ENTRY EXIT EXPANDED EXTCLASSEVENT
|
|
110 syntax keyword openroadEvent FRAMEACTIVATE FRAMEDEACTIVATE HEADERCLICK
|
|
111 syntax keyword openroadEvent INSERTROW LABELCHANGED MOVED PAGEACTIVATED
|
|
112 syntax keyword openroadEvent PAGECHANGED PAGEDEACTIVATED PROPERTIES RESIZED
|
|
113 syntax keyword openroadEvent SCROLL SELECT SELECTIONCHANGED SETVALUE
|
|
114 syntax keyword openroadEvent TERMINATE UNSELECT USEREVENT VALIDATE
|
|
115 syntax keyword openroadEvent WINDOWCLOSE WINDOWICON WINDOWMOVED WINDOWRESIZED
|
|
116 syntax keyword openroadEvent WINDOWVISIBLE
|
|
117
|
|
118 " System Constants
|
|
119 "
|
|
120 syntax keyword openroadConst BF_BMP BF_GIF BF_SUNRASTER BF_TIFF
|
|
121 syntax keyword openroadConst BF_WINDOWCURSOR BF_WINDOWICON BF_XBM
|
|
122 syntax keyword openroadConst CC_BACKGROUND CC_BLACK CC_BLUE CC_BROWN CC_CYAN
|
|
123 syntax keyword openroadConst CC_DEFAULT_1 CC_DEFAULT_10 CC_DEFAULT_11
|
|
124 syntax keyword openroadConst CC_DEFAULT_12 CC_DEFAULT_13 CC_DEFAULT_14
|
|
125 syntax keyword openroadConst CC_DEFAULT_15 CC_DEFAULT_16 CC_DEFAULT_17
|
|
126 syntax keyword openroadConst CC_DEFAULT_18 CC_DEFAULT_19 CC_DEFAULT_2
|
|
127 syntax keyword openroadConst CC_DEFAULT_20 CC_DEFAULT_21 CC_DEFAULT_22
|
|
128 syntax keyword openroadConst CC_DEFAULT_23 CC_DEFAULT_24 CC_DEFAULT_25
|
|
129 syntax keyword openroadConst CC_DEFAULT_26 CC_DEFAULT_27 CC_DEFAULT_28
|
|
130 syntax keyword openroadConst CC_DEFAULT_29 CC_DEFAULT_3 CC_DEFAULT_30
|
|
131 syntax keyword openroadConst CC_DEFAULT_4 CC_DEFAULT_5 CC_DEFAULT_6
|
|
132 syntax keyword openroadConst CC_DEFAULT_7 CC_DEFAULT_8 CC_DEFAULT_9
|
|
133 syntax keyword openroadConst CC_FOREGROUND CC_GRAY CC_GREEN CC_LIGHT_BLUE
|
|
134 syntax keyword openroadConst CC_LIGHT_BROWN CC_LIGHT_CYAN CC_LIGHT_GRAY
|
|
135 syntax keyword openroadConst CC_LIGHT_GREEN CC_LIGHT_ORANGE CC_LIGHT_PINK
|
|
136 syntax keyword openroadConst CC_LIGHT_PURPLE CC_LIGHT_RED CC_LIGHT_YELLOW
|
|
137 syntax keyword openroadConst CC_MAGENTA CC_ORANGE CC_PALE_BLUE CC_PALE_BROWN
|
|
138 syntax keyword openroadConst CC_PALE_CYAN CC_PALE_GRAY CC_PALE_GREEN
|
|
139 syntax keyword openroadConst CC_PALE_ORANGE CC_PALE_PINK CC_PALE_PURPLE
|
|
140 syntax keyword openroadConst CC_PALE_RED CC_PALE_YELLOW CC_PINK CC_PURPLE
|
|
141 syntax keyword openroadConst CC_RED CC_SYS_ACTIVEBORDER CC_SYS_ACTIVECAPTION
|
|
142 syntax keyword openroadConst CC_SYS_APPWORKSPACE CC_SYS_BACKGROUND
|
|
143 syntax keyword openroadConst CC_SYS_BTNFACE CC_SYS_BTNSHADOW CC_SYS_BTNTEXT
|
|
144 syntax keyword openroadConst CC_SYS_CAPTIONTEXT CC_SYS_GRAYTEXT
|
|
145 syntax keyword openroadConst CC_SYS_HIGHLIGHT CC_SYS_HIGHLIGHTTEXT
|
|
146 syntax keyword openroadConst CC_SYS_INACTIVEBORDER CC_SYS_INACTIVECAPTION
|
|
147 syntax keyword openroadConst CC_SYS_INACTIVECAPTIONTEXT CC_SYS_MENU
|
|
148 syntax keyword openroadConst CC_SYS_MENUTEXT CC_SYS_SCROLLBAR CC_SYS_SHADOW
|
|
149 syntax keyword openroadConst CC_SYS_WINDOW CC_SYS_WINDOWFRAME
|
|
150 syntax keyword openroadConst CC_SYS_WINDOWTEXT CC_WHITE CC_YELLOW
|
|
151 syntax keyword openroadConst CL_INVALIDVALUE CP_BOTH CP_COLUMNS CP_NONE
|
|
152 syntax keyword openroadConst CP_ROWS CS_CLOSED CS_CURRENT CS_NOCURRENT
|
|
153 syntax keyword openroadConst CS_NO_MORE_ROWS CS_OPEN CS_OPEN_CACHED DC_BW
|
|
154 syntax keyword openroadConst DC_COLOR DP_AUTOSIZE_FIELD DP_CLIP_IMAGE
|
|
155 syntax keyword openroadConst DP_SCALE_IMAGE_H DP_SCALE_IMAGE_HW
|
|
156 syntax keyword openroadConst DP_SCALE_IMAGE_W DS_CONNECTED DS_DISABLED
|
|
157 syntax keyword openroadConst DS_DISCONNECTED DS_INGRES_DBMS DS_NO_DBMS
|
|
158 syntax keyword openroadConst DS_ORACLE_DBMS DS_SQLSERVER_DBMS DV_NULL
|
|
159 syntax keyword openroadConst DV_STRING DV_SYSTEM EH_NEXT_HANDLER EH_RESUME
|
|
160 syntax keyword openroadConst EH_RETRY EP_INTERACTIVE EP_NONE EP_OUTPUT
|
|
161 syntax keyword openroadConst ER_FAIL ER_NAMEEXISTS ER_OK ER_OUTOFRANGE
|
|
162 syntax keyword openroadConst ER_ROWNOTFOUND ER_USER1 ER_USER10 ER_USER2
|
|
163 syntax keyword openroadConst ER_USER3 ER_USER4 ER_USER5 ER_USER6 ER_USER7
|
|
164 syntax keyword openroadConst ER_USER8 ER_USER9 FALSE FA_BOTTOMCENTER
|
|
165 syntax keyword openroadConst FA_BOTTOMLEFT FA_BOTTOMRIGHT FA_CENTER
|
|
166 syntax keyword openroadConst FA_CENTERLEFT FA_CENTERRIGHT FA_DEFAULT FA_NONE
|
|
167 syntax keyword openroadConst FA_TOPCENTER FA_TOPLEFT FA_TOPRIGHT
|
|
168 syntax keyword openroadConst FB_CHANGEABLE FB_CLICKPOINT FB_DIMMED FB_DRAGBOX
|
|
169 syntax keyword openroadConst FB_DRAGSEGMENT FB_FLEXIBLE FB_INVISIBLE
|
|
170 syntax keyword openroadConst FB_LANDABLE FB_MARKABLE FB_RESIZEABLE
|
|
171 syntax keyword openroadConst FB_VIEWABLE FB_VISIBLE FC_LOWER FC_NONE FC_UPPER
|
|
172 syntax keyword openroadConst FM_QUERY FM_READ FM_UPDATE FM_USER1 FM_USER2
|
|
173 syntax keyword openroadConst FM_USER3 FO_DEFAULT FO_HORIZONTAL FO_VERTICAL
|
|
174 syntax keyword openroadConst FP_BITMAP FP_CLEAR FP_CROSSHATCH FP_DARKSHADE
|
|
175 syntax keyword openroadConst FP_DEFAULT FP_HORIZONTAL FP_LIGHTSHADE FP_SHADE
|
|
176 syntax keyword openroadConst FP_SOLID FP_VERTICAL FT_NOTSETVALUE FT_SETVALUE
|
|
177 syntax keyword openroadConst FT_TABTO FT_TAKEFOCUS GF_BOTTOM GF_DEFAULT
|
|
178 syntax keyword openroadConst GF_LEFT GF_RIGHT GF_TOP HC_DOUBLEQUOTE
|
|
179 syntax keyword openroadConst HC_FORMFEED HC_NEWLINE HC_QUOTE HC_SPACE HC_TAB
|
|
180 syntax keyword openroadConst HV_CONTENTS HV_CONTEXT HV_HELPONHELP HV_KEY
|
|
181 syntax keyword openroadConst HV_QUIT LS_3D LS_DASH LS_DASHDOT LS_DASHDOTDOT
|
|
182 syntax keyword openroadConst LS_DEFAULT LS_DOT LS_SOLID LW_DEFAULT
|
|
183 syntax keyword openroadConst LW_EXTRATHIN LW_MAXIMUM LW_MIDDLE LW_MINIMUM
|
|
184 syntax keyword openroadConst LW_NOLINE LW_THICK LW_THIN LW_VERYTHICK
|
|
185 syntax keyword openroadConst LW_VERYTHIN MB_DISABLED MB_ENABLED MB_INVISIBLE
|
|
186 syntax keyword openroadConst MB_MOVEABLE MT_ERROR MT_INFO MT_NONE MT_WARNING
|
|
187 syntax keyword openroadConst OP_APPEND OP_NONE OS3D OS_DEFAULT OS_SHADOW
|
|
188 syntax keyword openroadConst OS_SOLID PU_CANCEL PU_OK QS_ACTIVE QS_INACTIVE
|
|
189 syntax keyword openroadConst QS_SETCOL QY_ARRAY QY_CACHE QY_CURSOR QY_DIRECT
|
|
190 syntax keyword openroadConst RC_CHILDSELECTED RC_DOWN RC_END RC_FIELDFREED
|
|
191 syntax keyword openroadConst RC_FIELDORPHANED RC_GROUPSELECT RC_HOME RC_LEFT
|
|
192 syntax keyword openroadConst RC_MODECHANGED RC_MOUSECLICK RC_MOUSEDRAG
|
|
193 syntax keyword openroadConst RC_NEXT RC_NOTAPPLICABLE RC_PAGEDOWN RC_PAGEUP
|
|
194 syntax keyword openroadConst RC_PARENTSELECTED RC_PREVIOUS RC_PROGRAM
|
|
195 syntax keyword openroadConst RC_RESUME RC_RETURN RC_RIGHT RC_ROWDELETED
|
|
196 syntax keyword openroadConst RC_ROWINSERTED RC_ROWSALLDELETED RC_SELECT
|
|
197 syntax keyword openroadConst RC_TFSCROLL RC_TOGGLESELECT RC_UP RS_CHANGED
|
|
198 syntax keyword openroadConst RS_DELETED RS_NEW RS_UNCHANGED RS_UNDEFINED
|
|
199 syntax keyword openroadConst SK_CLOSE SK_COPY SK_CUT SK_DELETE SK_DETAILS
|
|
200 syntax keyword openroadConst SK_DUPLICATE SK_FIND SK_GO SK_HELP SK_NEXT
|
|
201 syntax keyword openroadConst SK_NONE SK_PASTE SK_PROPS SK_QUIT SK_REDO
|
|
202 syntax keyword openroadConst SK_SAVE SK_TFDELETEALLROWS SK_TFDELETEROW
|
|
203 syntax keyword openroadConst SK_TFFIND SK_TFINSERTROW SK_UNDO SP_APPSTARTING
|
|
204 syntax keyword openroadConst SP_ARROW SP_CROSS SP_IBEAM SP_ICON SP_NO
|
|
205 syntax keyword openroadConst SP_SIZE SP_SIZENESW SP_SIZENS SP_SIZENWSE
|
|
206 syntax keyword openroadConst SP_SIZEWE SP_UPARROW SP_WAIT SY_NT SY_OS2
|
|
207 syntax keyword openroadConst SY_UNIX SY_VMS SY_WIN95 TF_COURIER TF_HELVETICA
|
|
208 syntax keyword openroadConst TF_LUCIDA TF_MENUDEFAULT TF_NEWCENTURY TF_SYSTEM
|
|
209 syntax keyword openroadConst TF_TIMESROMAN TRUE UE_DATAERROR UE_EXITED
|
|
210 syntax keyword openroadConst UE_NOTACTIVE UE_PURGED UE_RESUMED UE_UNKNOWN
|
|
211 syntax keyword openroadConst WI_MOTIF WI_MSWIN32 WI_MSWINDOWS WI_NONE WI_PM
|
|
212 syntax keyword openroadConst WP_FLOATING WP_INTERACTIVE WP_PARENTCENTERED
|
|
213 syntax keyword openroadConst WP_PARENTRELATIVE WP_SCREENCENTERED
|
|
214 syntax keyword openroadConst WP_SCREENRELATIVE WV_ICON WV_INVISIBLE
|
|
215 syntax keyword openroadConst WV_UNREALIZED WV_VISIBLE
|
|
216
|
|
217 " System Variables
|
|
218 "
|
|
219 syntax keyword openroadVar CurFrame CurProcedure CurMethod CurObject
|
|
220
|
|
221 " Identifiers
|
|
222 "
|
|
223 syntax match openroadIdent /[a-zA-Z_][a-zA-Z_]*![a-zA-Z_][a-zA-Z_]*/
|
|
224
|
|
225 " Comments
|
|
226 "
|
|
227 if exists("openroad_comment_strings")
|
|
228 syntax match openroadCommentSkip contained "^\s*\*\($\|\s\+\)"
|
|
229 syntax region openroadCommentString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ end="$"
|
|
230 syntax region openroadComment start="/\*" end="\*/" contains=openroadCommentString,openroadCharacter,openroadNumber
|
|
231 syntax match openroadComment "//.*" contains=openroadComment2String,openroadCharacter,openroadNumber
|
|
232 else
|
|
233 syn region openroadComment start="/\*" end="\*/"
|
|
234 syn match openroadComment "//.*"
|
|
235 endif
|
|
236
|
|
237 " Define the default highlighting.
|
|
238 " For version 5.7 and earlier: only when not done already
|
|
239 " For version 5.8 and later: only when an item doesn't have highlighting yet
|
|
240 "
|
|
241 if version >= 508 || !exists("did_openroad_syntax_inits")
|
|
242 if version < 508
|
|
243 let did_openroad_syntax_inits = 1
|
|
244 command -nargs=+ HiLink hi link <args>
|
|
245 else
|
|
246 command -nargs=+ HiLink hi def link <args>
|
|
247 endif
|
|
248
|
|
249 HiLink openroadKeyword Statement
|
|
250 HiLink openroadNumber Number
|
|
251 HiLink openroadString String
|
|
252 HiLink openroadComment Comment
|
|
253 HiLink openroadOperator Operator
|
|
254 HiLink openroadType Type
|
|
255 HiLink openroadFunc Special
|
|
256 HiLink openroadClass Type
|
|
257 HiLink openroadEvent Statement
|
|
258 HiLink openroadConst Constant
|
|
259 HiLink openroadVar Identifier
|
|
260 HiLink openroadIdent Identifier
|
|
261 HiLink openroadTodo Todo
|
|
262
|
|
263 delcommand HiLink
|
|
264 endif
|
|
265
|
|
266 let b:current_syntax = "openroad"
|