blob: 29112fcc7ebd3c119b3a3bd068f675de12ca4bf3 [file] [log] [blame]
Bram Moolenaar446cb832008-06-24 21:56:24 +00001" Vim syntax file for Fvwm-2.5.22
Bram Moolenaar9964e462007-05-05 17:54:07 +00002" Language: Fvwm{1,2} configuration file
3" Maintainer: Gautam Iyer <gi1242@users.sourceforge.net>
4" Previous Maintainer: Haakon Riiser <hakonrk@fys.uio.no>
Bram Moolenaar446cb832008-06-24 21:56:24 +00005" Last Change: Sat 29 Sep 2007 11:08:34 AM PDT
Bram Moolenaar071d4272004-06-13 20:20:40 +00006"
7" Thanks to David Necas (Yeti) for adding Fvwm 2.4 support.
Bram Moolenaar9964e462007-05-05 17:54:07 +00008"
9" 2006-05-09 gi1242: Rewrote fvwm2 syntax completely. Also since fvwm1 is now
10" mostly obsolete, made the syntax file pick fvwm2 syntax by default.
Bram Moolenaar071d4272004-06-13 20:20:40 +000011
Bram Moolenaar9964e462007-05-05 17:54:07 +000012if exists("b:current_syntax")
Bram Moolenaar071d4272004-06-13 20:20:40 +000013 finish
14endif
15
16" Fvwm configuration files are case insensitive
17syn case ignore
18
19" Identifiers in Fvwm can contain most characters, so we only
20" include the most common ones here.
Bram Moolenaar9964e462007-05-05 17:54:07 +000021setlocal iskeyword=_,-,+,.,a-z,A-Z,48-57
Bram Moolenaar071d4272004-06-13 20:20:40 +000022
Bram Moolenaar9964e462007-05-05 17:54:07 +000023" Syntax items common to fvwm1 and fvwm2 config files
24syn cluster fvwmConstants contains=fvwmEnvVar,fvwmNumber
Bram Moolenaar071d4272004-06-13 20:20:40 +000025syn match fvwmEnvVar "\$\w\+"
Bram Moolenaar9964e462007-05-05 17:54:07 +000026syn match fvwmNumber '\v<(\d+|0x[0-9a-f]+)>'
27
28syn match fvwmModConf nextgroup=fvwmModArg "\v^\s*\*\a+"
29syn region fvwmModArg contained contains=fvwmString,fvwmRGBValue
30 \ start='.' skip='\\$' end='$'
31
32syn region fvwmString contains=fvwmBackslash start='"'
33 \ matchgroup=fvwmBackslash skip='\v\\"' end='"'
34syn region fvwmString contains=fvwmBackslash start='`'
35 \ matchgroup=fvwmBackslash skip='\v\\`' end='`'
36syn region fvwmString contains=fvwmBackslash start="'"
37 \ matchgroup=fvwmBackslash skip="\v\\'" end="'"
38syn match fvwmBackslash contained '\\[^"'`]'
39
Bram Moolenaar071d4272004-06-13 20:20:40 +000040syn match fvwmRGBValue "#\x\{3}"
41syn match fvwmRGBValue "#\x\{6}"
42syn match fvwmRGBValue "#\x\{9}"
43syn match fvwmRGBValue "#\x\{12}"
44syn match fvwmRGBValue "rgb:\x\{1,4}/\x\{1,4}/\x\{1,4}"
Bram Moolenaar071d4272004-06-13 20:20:40 +000045
Bram Moolenaar446cb832008-06-24 21:56:24 +000046syn region fvwmComment contains=@Spell
47 \ start='^\s*#\s' skip='\\$' end='$'
48syn region fvwmComment start="\v^\s*#(\S|$)" skip='\\$' end='$'
Bram Moolenaar9964e462007-05-05 17:54:07 +000049
50if (exists("b:fvwm_version") && b:fvwm_version == 1)
51 \ || (exists("use_fvwm_1") && use_fvwm_1)
52
53 "
54 " Syntax highlighting for Fvwm1 files.
55 "
56
57 " Moved from common syntax items
58 syn match fvwmModule "\<Module\s\+\w\+"he=s+6
59 syn keyword fvwmExec Exec
60 syn match fvwmPath "\<IconPath\s.*$"lc=8 contains=fvwmEnvVar
61 syn match fvwmPath "\<ModulePath\s.*$"lc=10 contains=fvwmEnvVar
62 syn match fvwmPath "\<PixmapPath\s.*$"lc=10 contains=fvwmEnvVar
63 syn match fvwmKey "\<Key\s\+\w\+"he=s+3
64
65 " fvwm1 specific items
Bram Moolenaar071d4272004-06-13 20:20:40 +000066 syn match fvwmEnvVar "\$(\w\+)"
Bram Moolenaar9964e462007-05-05 17:54:07 +000067 syn match fvwmWhitespace contained "\s\+"
68 syn region fvwmStyle oneline keepend
69 \ contains=fvwmString,fvwmKeyword,fvwmWhiteSpace
70 \ matchgroup=fvwmFunction
71 \ start="^\s*Style\>"hs=e-5 end="$"
Bram Moolenaar071d4272004-06-13 20:20:40 +000072
Bram Moolenaar9964e462007-05-05 17:54:07 +000073 syn keyword fvwmFunction AppsBackingStore AutoRaise BackingStore Beep
74 \ BoundaryWidth ButtonStyle CenterOnCirculate
75 \ CirculateDown CirculateHit CirculateSkip
76 \ CirculateSkipIcons CirculateUp ClickTime
77 \ ClickToFocus Close Cursor CursorMove
78 \ DecorateTransients Delete Desk DeskTopScale
79 \ DeskTopSize Destroy DontMoveOff
80 \ EdgeResistance EdgeScroll EndFunction
81 \ EndMenu EndPopup Focus Font Function
82 \ GotoPage HiBackColor HiForeColor Icon
83 \ IconBox IconFont Iconify IconPath Key
84 \ Lenience Lower Maximize MenuBackColor
85 \ MenuForeColor MenuStippleColor Module
86 \ ModulePath Mouse Move MWMBorders MWMButtons
87 \ MWMDecorHints MWMFunctionHints
88 \ MWMHintOverride MWMMenus NoBorder
89 \ NoBoundaryWidth Nop NoPPosition NoTitle
90 \ OpaqueMove OpaqueResize Pager PagerBackColor
91 \ PagerFont PagerForeColor PagingDefault
92 \ PixmapPath Popup Quit Raise RaiseLower
93 \ RandomPlacement Refresh Resize Restart
94 \ SaveUnders Scroll SloppyFocus SmartPlacement
95 \ StartsOnDesk StaysOnTop StdBackColor
96 \ StdForeColor Stick Sticky StickyBackColor
97 \ StickyForeColor StickyIcons
98 \ StubbornIconPlacement StubbornIcons
99 \ StubbornPlacement SuppressIcons Title
100 \ TogglePage Wait Warp WindowFont WindowList
101 \ WindowListSkip WindowsDesk WindowShade
102 \ XORvalue
Bram Moolenaar071d4272004-06-13 20:20:40 +0000103
104 " These keywords are only used after the "Style" command. To avoid
105 " name collision with several commands, they are contained.
Bram Moolenaar9964e462007-05-05 17:54:07 +0000106 syn keyword fvwmKeyword contained
107 \ BackColor BorderWidth BoundaryWidth Button
108 \ CirculateHit CirculateSkip Color DoubleClick
109 \ ForeColor Handles HandleWidth Icon IconTitle
110 \ NoBorder NoBoundaryWidth NoButton NoHandles
111 \ NoIcon NoIconTitle NoTitle Slippery
112 \ StartIconic StartNormal StartsAnyWhere
113 \ StartsOnDesk StaysOnTop StaysPut Sticky
114 \ Title WindowListHit WindowListSkip
115
116" elseif (exists("b:fvwm_version") && b:fvwm_version == 2)
117" \ || (exists("use_fvwm_2") && use_fvwm_2)
118else
119
120 "
121 " Syntax highlighting for fvwm2 files.
122 "
Bram Moolenaar071d4272004-06-13 20:20:40 +0000123 syn match fvwmEnvVar "\${\w\+}"
124 syn match fvwmEnvVar "\$\[[^]]\+\]"
125 syn match fvwmEnvVar "\$[$0-9*]"
Bram Moolenaar071d4272004-06-13 20:20:40 +0000126
Bram Moolenaar9964e462007-05-05 17:54:07 +0000127 syn match fvwmDef contains=fvwmMenuString,fvwmWhitespace
128 \ '^\s*+\s*".\{-}"'
129 syn region fvwmMenuString contains=fvwmIcon,fvwmShortcutKey
130 \ start='^\s*+\s*\zs"' skip='\v\\\\|\\\"' end='"'
131 syn region fvwmIcon contained start='\v\%\%@!' end='%'
132 syn match fvwmShortcutKey contained "&."
Bram Moolenaar071d4272004-06-13 20:20:40 +0000133
Bram Moolenaar9964e462007-05-05 17:54:07 +0000134 syn keyword fvwmModuleName FvwmAnimate FvwmAudio FvwmAuto FvwmBacker
Bram Moolenaar446cb832008-06-24 21:56:24 +0000135 \ FvwmBanner FvwmButtons FvwmCascade
136 \ FvwmCommandS FvwmConsole FvwmConsoleC
137 \ FvwmCpp FvwmDebug FvwmDragWell FvwmEvent
138 \ FvwmForm FvwmGtkDebug FvwmIconBox
Bram Moolenaar9964e462007-05-05 17:54:07 +0000139 \ FvwmIconMan FvwmIdent FvwmM4 FvwmPager
Bram Moolenaar446cb832008-06-24 21:56:24 +0000140 \ FvwmPerl FvwmProxy FvwmRearrange FvwmSave
141 \ FvwmSaveDesk FvwmScript FvwmScroll FvwmTabs
142 \ FvwmTalk FvwmTaskBar FvwmTheme FvwmTile
143 \ FvwmWharf FvwmWindowMenu FvwmWinList
144
Bram Moolenaar9964e462007-05-05 17:54:07 +0000145 " Obsolete fvwmModuleName: FvwmTheme
Bram Moolenaar071d4272004-06-13 20:20:40 +0000146
Bram Moolenaar9964e462007-05-05 17:54:07 +0000147 syn keyword fvwmKeyword AddToMenu ChangeMenuStyle CopyMenuStyle
148 \ DestroyMenu DestroyMenuStyle Menu
149 \ Popup TearMenuOff Title BugOpts BusyCursor
150 \ ClickTime ColorLimit ColormapFocus
151 \ DefaultColors DefaultColorset DefaultFont
152 \ DefaultIcon DefaultLayers Deschedule Emulate
153 \ EscapeFunc FakeClick FakeKeypress GlobalOpts
154 \ HilightColor HilightColorset IconFont
155 \ PrintInfo Repeat Schedule State WindowFont
156 \ XSync XSynchronize AnimatedMove
157 \ HideGeometryWindow Layer Lower Move
158 \ MoveToDesk MoveThreshold MoveToPage
159 \ MoveToScreen OpaqueMoveSize PlaceAgain Raise
160 \ RaiseLower ResizeMaximize ResizeMove
161 \ ResizeMoveMaximize RestackTransients
162 \ SetAnimation SnapAttraction SnapGrid
163 \ WindowsDesk XorPixmap XorValue CursorMove
164 \ FlipFocus Focus WarpToWindow Close Delete
165 \ Destroy Iconify Recapture RecaptureWindow
166 \ Refresh RefreshWindow Stick StickAcrossPages
167 \ StickAcrossDesks WindowShade
168 \ WindowShadeAnimate IgnoreModifiers
169 \ EdgeCommand EdgeLeaveCommand GnomeButton
170 \ Stroke StrokeFunc FocusStyle DestroyStyle
Bram Moolenaar446cb832008-06-24 21:56:24 +0000171 \ DestroyWindowStyle UpdateStyles AddToDecor
172 \ BorderStyle ChangeDecor DestroyDecor
173 \ UpdateDecor DesktopName DeskTopSize
174 \ EdgeResistance EdgeScroll EdgeThickness
175 \ EwmhBaseStruts EWMHNumberOfDesktops
176 \ GotoDeskAndPage GotoPage Scroll Xinerama
Bram Moolenaar9964e462007-05-05 17:54:07 +0000177 \ XineramaPrimaryScreen XineramaSls
178 \ XineramaSlsSize XineramaSlsScreens AddToFunc
179 \ Beep DestroyFunc Echo Exec ExecUseShell
180 \ Function Nop PipeRead Read SetEnv Silent
181 \ UnsetEnv Wait DestroyModuleConfig KillModule
Bram Moolenaar446cb832008-06-24 21:56:24 +0000182 \ Module ModuleListenOnly ModuleSynchronous
183 \ ModuleTimeout SendToModule Quit QuitScreen
184 \ QuitSession Restart SaveSession
185 \ SaveQuitSession KeepRc NoWindow Break
186 \ CleanupColorsets EchoFuncDefinition
Bram Moolenaar071d4272004-06-13 20:20:40 +0000187
Bram Moolenaar9964e462007-05-05 17:54:07 +0000188 " Conditional commands
189 syn keyword fvwmKeyword nextgroup=fvwmCondition skipwhite
190 \ All Any Current Next None Pick PointerWindow
191 \ Prev ThisWindow
192 syn keyword fvwmKeyword nextgroup=fvwmDirection skipwhite
193 \ Direction
194 syn keyword fvwmDirection contained nextgroup=fvwmDirection skipwhite
195 \ FromPointer
196 syn keyword fvwmDirection contained nextgroup=fvwmCondition skipwhite
197 \ North Northeast East Southeast South
198 \ Southwest West Northwest Center
199 syn region fvwmCondition contained contains=fvwmCondNames,fvwmString
200 \ matchgroup=fvwmKeyword start='(' skip=','
201 \ end=')'
202 syn keyword fvwmCondNames contained
203 \ AcceptsFocus AnyScreen CirculateHit
204 \ CirculateHitIcon CirculateHitShaded Closable
205 \ CurrentDesk CurrentGlobalPage
206 \ CurrentGlobalPageAnyDesk CurrentPage
207 \ CurrentPageAnyDesk CurrentScreen FixedSize
208 \ Focused HasHandles HasPointer Iconic
209 \ Iconifiable Maximizable Maximized
Bram Moolenaar446cb832008-06-24 21:56:24 +0000210 \ Overlapped PlacedByButton PlacedByButton3
211 \ PlacedByFvwm Raised Shaded Sticky
212 \ StickyAcrossDesks StickyAcrossPages
213 \ Transient Visible StickyIcon
214 \ StickyAcrossPagesIcon StickyAcrossDesksIcon
215
Bram Moolenaar9964e462007-05-05 17:54:07 +0000216 syn keyword fvwmCondNames contained skipwhite nextgroup=@fvwmConstants
217 \ State Layer
Bram Moolenaar071d4272004-06-13 20:20:40 +0000218
Bram Moolenaar9964e462007-05-05 17:54:07 +0000219 " Test
220 syn keyword fvwmKeyword nextgroup=fvwmTCond skipwhite
221 \ Test
222 syn region fvwmTCond contained contains=fvwmTCNames,fvwmString
223 \ matchgroup=fvwmKeyword start='(' end=')'
224 syn keyword fvwmTCNames contained
225 \ Version EnvIsSet EnvMatch EdgeHasPointer
226 \ EdgeIsActive Start Init Restart Exit Quit
227 \ ToRestart True False F R W X I
228
229 " TestRc
230 syn keyword fvwmKeyword nextgroup=fvwmTRCond skipwhite
231 \ TestRc
232 syn region fvwmTRCond contained contains=fvwmTRNames,fvwmNumber
233 \ matchgroup=fvwmKeyword start='(' end=')'
234 syn keyword fvwmTRNames contained NoMatch Match Error Break
Bram Moolenaar071d4272004-06-13 20:20:40 +0000235
Bram Moolenaar9964e462007-05-05 17:54:07 +0000236 " Colorsets
237 syn keyword fvwmKeyword nextgroup=fvwmCSArgs skipwhite
238 \ ColorSet
239 syn region fvwmCSArgs contained transparent contains=fvwmCSNames,@fvwmConstants,fvwmString,fvwmRGBValue,fvwmGradient
240 \ start='.' skip='\\$' end='$'
241 syn keyword fvwmCSNames contained
242 \ fg Fore Foreground bg Back Background hi
243 \ Hilite Hilight sh Shade Shadow fgsh Pixmap
244 \ TiledPixmap AspectPixmap RootTransparent
245 \ Shape TiledShape AspectShape Tint fgTint
246 \ bgTint Alpha fgAlpha Dither IconTint
247 \ IconAlpha NoShape Plain Translucent
248 syn match fvwmCSNames contained '\v<Transparent>'
249 syn match fvwmGradient contained '\v<[HVDBSCRY]Gradient>'
250
251 " Styles
252 syn keyword fvwmKeyword nextgroup=fvwmStyleArgs skipwhite
253 \ Style WindowStyle
254 syn region fvwmStyleArgs contained transparent contains=fvwmStyleNames,@fvwmConstants,fvwmString,fvwmRGBValue
255 \ start='.' skip='\\$' end='$'
256 syn keyword fvwmStyleNames contained
257 \ BorderWidth HandleWidth NoIcon Icon MiniIcon
258 \ IconBox IconGrid IconFill IconSize NoTitle
259 \ Title TitleAtBottom TitleAtLeft TitleAtRight
260 \ TitleAtTop LeftTitleRotatedCW
261 \ LeftTitleRotatedCCW RightTitleRotatedCCW
262 \ RightTitleRotatedCW TopTitleRotated
263 \ TopTitleNotRotated BottomTitleRotated
264 \ BottomTitleNotRotated UseTitleDecorRotation
265 \ StippledTitle StippledTitleOff
266 \ IndexedWindowName ExactWindowName
267 \ IndexedIconName ExactIconName Borders
268 \ NoHandles Handles WindowListSkip
269 \ WindowListHit CirculateSkip CirculateHit
270 \ CirculateSkipShaded CirculateHitShaded Layer
271 \ StaysOnTop StaysOnBottom StaysPut Sticky
272 \ Slippery StickyAcrossPages StickyAcrossDesks
273 \ StartIconic StartNormal Color ForeColor
274 \ BackColor Colorset HilightFore HilightBack
275 \ HilightColorset BorderColorset
276 \ HilightBorderColorset IconTitleColorset
277 \ HilightIconTitleColorset
278 \ IconBackgroundColorset IconTitleRelief
279 \ IconBackgroundRelief IconBackgroundPadding
280 \ Font IconFont StartsOnDesk StartsOnPage
281 \ StartsAnyWhere StartsOnScreen
282 \ ManualPlacementHonorsStartsOnPage
283 \ ManualPlacementIgnoresStartsOnPage
284 \ CaptureHonorsStartsOnPage
285 \ CaptureIgnoresStartsOnPage
286 \ RecaptureHonorsStartsOnPage
287 \ RecaptureIgnoresStartsOnPage
288 \ StartsOnPageIncludesTransients
289 \ StartsOnPageIgnoresTransients IconTitle
290 \ NoIconTitle MwmButtons FvwmButtons MwmBorder
291 \ FvwmBorder MwmDecor NoDecorHint MwmFunctions
292 \ NoFuncHint HintOverride NoOverride NoButton
293 \ Button ResizeHintOverride NoResizeOverride
294 \ OLDecor NoOLDecor GNOMEUseHints
295 \ GNOMEIgnoreHints StickyIcon SlipperyIcon
296 \ StickyAcrossPagesIcon StickyAcrossDesksIcon
297 \ ManualPlacement CascadePlacement
298 \ MinOverlapPlacement
299 \ MinOverlapPercentPlacement
300 \ TileManualPlacement TileCascadePlacement
Bram Moolenaar446cb832008-06-24 21:56:24 +0000301 \ MinOverlapPlacementPenalties
Bram Moolenaar9964e462007-05-05 17:54:07 +0000302 \ MinOverlapPercentPlacementPenalties
303 \ DecorateTransient NakedTransient
304 \ DontRaiseTransient RaiseTransient
305 \ DontLowerTransient LowerTransient
306 \ DontStackTransientParent
307 \ StackTransientParent SkipMapping ShowMapping
308 \ ScatterWindowGroups KeepWindowGroupsOnDesk
309 \ UseDecor UseStyle NoPPosition UsePPosition
310 \ NoUSPosition UseUSPosition
311 \ NoTransientPPosition UseTransientPPosition
312 \ NoTransientUSPosition UseTransientUSPosition
313 \ NoIconPosition UseIconPosition Lenience
314 \ NoLenience ClickToFocus SloppyFocus
315 \ MouseFocus FocusFollowsMouse NeverFocus
316 \ ClickToFocusPassesClickOff
317 \ ClickToFocusPassesClick
318 \ ClickToFocusRaisesOff ClickToFocusRaises
319 \ MouseFocusClickRaises
320 \ MouseFocusClickRaisesOff GrabFocus
321 \ GrabFocusOff GrabFocusTransientOff
322 \ GrabFocusTransient FPFocusClickButtons
323 \ FPFocusClickModifiers
324 \ FPSortWindowlistByFocus FPClickRaisesFocused
325 \ FPClickDecorRaisesFocused
326 \ FPClickIconRaisesFocused
327 \ FPClickRaisesUnfocused
328 \ FPClickDecorRaisesUnfocused
329 \ FPClickIconRaisesUnfocused FPClickToFocus
330 \ FPClickDecorToFocus FPClickIconToFocus
331 \ FPEnterToFocus FPLeaveToUnfocus
332 \ FPFocusByProgram FPFocusByFunction
333 \ FPFocusByFunctionWarpPointer FPLenient
334 \ FPPassFocusClick FPPassRaiseClick
335 \ FPIgnoreFocusClickMotion
336 \ FPIgnoreRaiseClickMotion
337 \ FPAllowFocusClickFunction
338 \ FPAllowRaiseClickFunction FPGrabFocus
339 \ FPGrabFocusTransient FPOverrideGrabFocus
340 \ FPReleaseFocus FPReleaseFocusTransient
341 \ FPOverrideReleaseFocus StartsLowered
342 \ StartsRaised IgnoreRestack AllowRestack
343 \ FixedPosition VariablePosition
344 \ FixedUSPosition VariableUSPosition
345 \ FixedPPosition VariablePPosition FixedSize
346 \ VariableSize FixedUSSize VariableUSSize
347 \ FixedPSize VariablePSize Closable
348 \ Iconifiable Maximizable
349 \ AllowMaximizeFixedSize IconOverride
350 \ NoIconOverride NoActiveIconOverride
351 \ DepressableBorder FirmBorder MaxWindowSize
352 \ IconifyWindowGroups IconifyWindowGroupsOff
353 \ ResizeOpaque ResizeOutline BackingStore
354 \ BackingStoreOff BackingStoreWindowDefault
355 \ Opacity ParentalRelativity SaveUnder
356 \ SaveUnderOff WindowShadeShrinks
357 \ WindowShadeScrolls WindowShadeSteps
358 \ WindowShadeAlwaysLazy WindowShadeBusy
359 \ WindowShadeLazy EWMHDonateIcon
360 \ EWMHDontDonateIcon EWMHDonateMiniIcon
361 \ EWMHDontDonateMiniIcon EWMHMiniIconOverride
362 \ EWMHNoMiniIconOverride
363 \ EWMHUseStackingOrderHints
364 \ EWMHIgnoreStackingOrderHints
365 \ EWMHIgnoreStateHints EWMHUseStateHints
Bram Moolenaar446cb832008-06-24 21:56:24 +0000366 \ EWMHIgnoreStrutHints EWMHIgnoreWindowType
367 \ EWMHUseStrutHints
Bram Moolenaar9964e462007-05-05 17:54:07 +0000368 \ EWMHMaximizeIgnoreWorkingArea
369 \ EWMHMaximizeUseWorkingArea
370 \ EWMHMaximizeUseDynamicWorkingArea
371 \ EWMHPlacementIgnoreWorkingArea
372 \ EWMHPlacementUseWorkingArea
373 \ EWMHPlacementUseDynamicWorkingArea
374 \ MoveByProgramMethod Unmanaged State
Bram Moolenaar446cb832008-06-24 21:56:24 +0000375 \ StippledIconTitle StickyStippledTitle
376 \ StickyStippledIconTitle
377 \ PositionPlacement
378 \ UnderMousePlacementHonorsStartsOnPage
379 \ UnderMousePlacementIgnoresStartsOnPage
380 \ MinOverlapPlacementPenalties
381 \ MinOverlapPercentPlacementPenalties
382 \ MinWindowSize StartShaded
Bram Moolenaar9964e462007-05-05 17:54:07 +0000383
384 " Cursor styles
385 syn keyword fvwmKeyword nextgroup=fvwmCursorStyle skipwhite
386 \ CursorStyle
387 syn case match
388 syn keyword fvwmCursorStyle contained
389 \ POSITION TITLE DEFAULT SYS MOVE RESIZE WAIT
390 \ MENU SELECT DESTROY TOP RIGHT BOTTOM LEFT
391 \ TOP_LEFT TOP_RIGHT BOTTOM_LEFT BOTTOM_RIGHT
392 \ TOP_EDGE RIGHT_EDGE BOTTOM_EDGE LEFT_EDGE
393 \ ROOT STROKE
394 syn case ignore
395
396 " Menu style
397 syn keyword fvwmKeyword nextgroup=fvwmMStyleArgs skipwhite
398 \ MenuStyle
399 syn region fvwmMStyleArgs contained transparent contains=fvwmMStyleNames,@fvwmConstants,fvwmString,fvwmGradient,fvwmRGBValue
400 \ start='.' skip='\\$' end='$'
401 syn keyword fvwmMStyleNames contained
402 \ Fvwm Mwm Win BorderWidth Foreground
403 \ Background Greyed HilightBack HilightBackOff
404 \ ActiveFore ActiveForeOff MenuColorset
405 \ ActiveColorset GreyedColorset Hilight3DThick
406 \ Hilight3DThin Hilight3DOff
407 \ Hilight3DThickness Animation AnimationOff
408 \ Font MenuFace PopupDelay PopupOffset
409 \ TitleWarp TitleWarpOff TitleUnderlines0
410 \ TitleUnderlines1 TitleUnderlines2
411 \ SeparatorsLong SeparatorsShort
412 \ TrianglesSolid TrianglesRelief
413 \ PopupImmediately PopupDelayed
414 \ PopdownImmediately PopdownDelayed
415 \ PopupActiveArea DoubleClickTime SidePic
416 \ SideColor PopupAsRootMenu PopupAsSubmenu
417 \ PopupIgnore PopupClose RemoveSubmenus
418 \ HoldSubmenus SubmenusRight SubmenusLeft
419 \ SelectOnRelease ItemFormat
420 \ VerticalItemSpacing VerticalTitleSpacing
421 \ AutomaticHotkeys AutomaticHotkeysOff
Bram Moolenaar446cb832008-06-24 21:56:24 +0000422 \ TitleFont TitleColorset HilightTitleBack
Bram Moolenaar9964e462007-05-05 17:54:07 +0000423
424 " Button style
425 syn keyword fvwmKeyword nextgroup=fvwmBNum skipwhite
426 \ ButtonStyle AddButtonStyle
427 syn match fvwmBNum contained
428 \ nextgroup=fvwmBState,fvwmBStyleArgs skipwhite
429 \ '\v<([0-9]|All|Left|Right|Reset)>'
430 syn keyword fvwmBState contained nextgroup=fvwmBStyleArgs skipwhite
431 \ ActiveUp ActiveDown InactiveUp InactiveDown
432 \ Active Inactive ToggledActiveUp
433 \ ToggledActiveDown ToggledInactiveUp
434 \ ToggledInactiveDown ToggledActive
435 \ ToggledInactive AllNormal AllToggled
436 \ AllActive AllInactive AllUp AllDown
437 syn region fvwmBStyleArgs contained contains=fvwmBStyleFlags,fvwmBStyleNames,fvwmGradient,fvwmRGBValue,@fvwmConstants,fvwmString
438 \ start='\S' skip='\\$' end='$'
439 syn keyword fvwmBStyleNames contained
440 \ Simple Default Solid Colorset Vector Pixmap
441 \ AdjustedPixmap ShrunkPixmap StretchedPixmap
442 \ TiledPixmap MiniIcon
443 syn keyword fvwmBStyleFlags contained
444 \ Raised Sunk Flat UseTitleStyle
445 \ UseBorderStyle
446
447 " Border style
448 syn keyword fvwmKeyword skipwhite nextgroup=fvwmBdState,fvwmBdStyleArgs
449 \ BorderStyle
450 syn keyword fvwmBdState contained skipwhite nextgroup=fvwmBdStyleArgs
451 \ Active Inactive
452 syn region fvwmBdStyleArgs contained contains=fvwmBdStyNames,fvwmBdStyFlags
453 \ start='\S' skip='\\$' end='$'
454 syn keyword fvwmBdStyNames contained
455 \ TiledPixmap Colorset
456 syn keyword fvwmBdStyFlags contained
457 \ HiddenHandles NoInset Raised Sunk Flat
458
459 " Title styles
460 syn keyword fvwmKeyword skipwhite nextgroup=fvwmTState,fvwmTStyleArgs
461 \ TitleStyle AddTitleStyle
462 syn keyword fvwmTState contained skipwhite nextgroup=fvwmTStyleArgs
463 \ ActiveUp ActiveDown InactiveUp InactiveDown
464 \ Active Inactive ToggledActiveUp
465 \ ToggledActiveDown ToggledInactiveUp
466 \ ToggledInactiveDown ToggledActive
467 \ ToggledInactive AllNormal AllToggled
468 \ AllActive AllInactive AllUp AllDown
469 syn region fvwmTStyleArgs contained contains=fvwmBStyleNames,fvwmTStyleNames,fvwmMPmapNames,fvwmTStyleFlags,fvwmGradient,fvwmRGBValue,@fvwmConstants
470 \ start='\S' skip='\\$' end='$'
471 syn keyword fvwmTStyleNames contained
472 \ MultiPixmap
473 syn keyword fvwmTStyleNames contained
474 \ LeftJustified Centered RightJustified Height
475 \ MinHeight
476 syn keyword fvwmMPmapNames contained
477 \ Main LeftMain RightMain UnderText LeftOfText
478 \ RightOfText LeftEnd RightEnd Buttons
479 \ LeftButtons RightButtons
480 syn keyword fvwmTStyleFlags contained
481 \ Raised Flat Sunk
482
483 " Button state
484 syn keyword fvwmKeyword nextgroup=fvwmBStateArgs
485 \ ButtonState
486 syn region fvwmBStateArgs contained contains=fvwmBStateTF,fvwmBStateNames
487 \ start='.' skip='\\$' end='$'
488 syn keyword fvwmBStateNames contained ActiveDown Inactive InactiveDown
489 syn keyword fvwmBStateTF contained True False
490
491 " Paths
492 syn keyword fvwmKeyword nextgroup=fvwmPath skipwhite
493 \ IconPath ImagePath LocalePath PixmapPath
494 \ ModulePath
495 syn match fvwmPath contained contains=fvwmEnvVar '\v.+$'
496
497 " Window list command
498 syn keyword fvwmKeyword nextgroup=fvwmWLArgs skipwhite
499 \ WindowList
500 syn region fvwmWLArgs contained
501 \ contains=fvwmCondition,@fvwmConstants,fvwmString,fvwmWLOpts
502 \ start='.' skip='\\$' end='$'
503 syn keyword fvwmWLOpts contained
504 \ Geometry NoGeometry NoGeometryWithInfo
505 \ NoDeskNum NoNumInDeskTitle
506 \ NoCurrentDeskTitle MaxLabelWidth width
507 \ TitleForAllDesks Function funcname Desk
508 \ desknum CurrentDesk NoIcons Icons OnlyIcons
509 \ NoNormal Normal OnlyNormal NoSticky Sticky
510 \ OnlySticky NoStickyAcrossPages
511 \ StickyAcrossPages OnlyStickyAcrossPages
512 \ NoStickyAcrossDesks StickyAcrossDesks
513 \ OnlyStickyAcrossDesks NoOnTop OnTop
514 \ OnlyOnTop NoOnBottom OnBottom OnlyOnBottom
515 \ Layer UseListSkip OnlyListSkip NoDeskSort
516 \ ReverseOrder CurrentAtEnd IconifiedAtEnd
517 \ UseIconName Alphabetic NotAlphabetic
518 \ SortByResource SortByClass NoHotkeys
519 \ SelectOnRelease
520
521 syn keyword fvwmSpecialFn StartFunction InitFunction RestartFunction
522 \ ExitFunction SessionInitFunction
523 \ SessionRestartFunction SessionExitFunction
524 \ MissingSubmenuFunction WindowListFunc
525
526 syn keyword fvwmKeyword skipwhite nextgroup=fvwmKeyWin,fvwmKeyName
527 \ Key PointerKey
528 syn region fvwmKeyWin contained skipwhite nextgroup=fvwmKeyName
529 \ start='(' end=')'
530 syn case match
531 syn match fvwmKeyName contained skipwhite nextgroup=fvwmKeyContext
532 \ '\v<([a-zA-Z0-9]|F\d+|KP_\d)>'
533 syn keyword fvwmKeyName contained skipwhite nextgroup=fvwmKeyContext
534 \ BackSpace Begin Break Cancel Clear Delete
535 \ Down End Escape Execute Find Help Home
536 \ Insert KP_Add KP_Begin KP_Decimal KP_Delete
537 \ KP_Divide KP_Down KP_End KP_Enter KP_Equal
538 \ KP_Home KP_Insert KP_Left KP_Multiply
539 \ KP_Next KP_Page_Down KP_Page_Up KP_Prior
540 \ KP_Right KP_Separator KP_Space KP_Subtract
541 \ KP_Tab KP_Up Left Linefeed Menu Mode_switch
542 \ Next Num_Lock Page_Down Page_Up Pause Print
543 \ Prior Redo Return Right script_switch
544 \ Scroll_Lock Select Sys_Req Tab Undo Up space
545 \ exclam quotedbl numbersign dollar percent
546 \ ampersand apostrophe quoteright parenleft
547 \ parenright asterisk plus comma minus period
548 \ slash colon semicolon less equal greater
549 \ question at bracketleft backslash
550 \ bracketright asciicircum underscore grave
551 \ quoteleft braceleft bar braceright
552 \ asciitilde
553
554 syn match fvwmKeyContext contained skipwhite nextgroup=fvwmKeyMods
555 \ '\v<[][RWDTS_F<^>vI0-9AM-]+>'
556 syn match fvwmKeyMods contained '\v[NCSMLA1-5]+'
557 syn case ignore
558
559 syn keyword fvwmKeyword skipwhite nextgroup=fvwmMouseWin,fvwmMouseButton
560 \ Mouse
561 syn region fvwmMouseWin contained skipwhite nextgroup=fvwmMouseButton
562 \ start='(' end=')'
563 syn match fvwmMouseButton contained skipwhite nextgroup=fvwmKeyContext
564 \ '[0-5]'
Bram Moolenaar071d4272004-06-13 20:20:40 +0000565endif
566
Bram Moolenaar9964e462007-05-05 17:54:07 +0000567" Define syntax highlighting groups
Bram Moolenaar071d4272004-06-13 20:20:40 +0000568
Bram Moolenaar9964e462007-05-05 17:54:07 +0000569"
570" Common highlighting groups
571"
572hi def link fvwmComment Comment
573hi def link fvwmEnvVar Macro
574hi def link fvwmNumber Number
575hi def link fvwmKeyword Keyword
576hi def link fvwmPath Constant
577hi def link fvwmModConf Macro
578hi def link fvwmRGBValue Constant
579hi def link fvwmString String
580hi def link fvwmBackslash SpecialChar
Bram Moolenaar071d4272004-06-13 20:20:40 +0000581
Bram Moolenaar071d4272004-06-13 20:20:40 +0000582
Bram Moolenaar9964e462007-05-05 17:54:07 +0000583"
584" Highlighting groups for fvwm1 specific items
585"
586hi def link fvwmExec fvwmKeyword
587hi def link fvwmKey fvwmKeyword
588hi def link fvwmModule fvwmKeyword
589hi def link fvwmFunction Function
590
591"
592" Highlighting groups for fvwm2 specific items
593"
594hi def link fvwmSpecialFn Type
595hi def link fvwmCursorStyle fvwmStyleNames
596hi def link fvwmStyleNames Identifier
597hi def link fvwmMStyleNames fvwmStyleNames
598hi def link fvwmCSNames fvwmStyleNames
599hi def link fvwmGradient fvwmStyleNames
600hi def link fvwmCondNames fvwmStyleNames
601hi def link fvwmTCNames fvwmStyleNames
602hi def link fvwmTRNames fvwmStyleNames
603hi def link fvwmWLOpts fvwmStyleNames
604
605hi def link fvwmBNum Number
606hi def link fvwmBState Type
607hi def link fvwmBStyleNames fvwmStyleNames
608hi def link fvwmBStyleFlags Special
609
610hi def link fvwmBStateTF Constant
611hi def link fvwmBStateNames fvwmStyleNames
612
613hi def link fvwmBdState fvwmBState
614hi def link fvwmBdStyNames fvwmStyleNames
615hi def link fvwmBdStyFlags fvwmBStyleFlags
616
617hi def link fvwmTState fvwmBState
618hi def link fvwmTStyleNames fvwmStyleNames
619hi def link fvwmMPmapNames fvwmBStyleFlags
620hi def link fvwmTStyleFlags fvwmBStyleFlags
621
622hi def link fvwmDirection fvwmBStyleFlags
623
624hi def link fvwmKeyWin Constant
625hi def link fvwmMouseWin fvwmKeyWin
626hi def link fvwmKeyName Special
627hi def link fvwmKeyContext fvwmKeyName
628hi def link fvwmKeyMods fvwmKeyName
629hi def link fvwmMouseButton fvwmKeyName
630
631hi def link fvwmMenuString String
632hi def link fvwmIcon Type
633hi def link fvwmShortcutKey SpecialChar
634
635hi def link fvwmModuleName Function
Bram Moolenaar071d4272004-06-13 20:20:40 +0000636
637let b:current_syntax = "fvwm"