home *** CD-ROM | disk | FTP | other *** search
/ vim.ftp.fu-berlin.de / 2015-02-03.vim.ftp.fu-berlin.de.tar / vim.ftp.fu-berlin.de / mac / vim55rt.sit / runtime / syntax / vb.vim < prev    next >
Encoding:
Text File  |  1999-09-25  |  10.6 KB  |  178 lines  |  [TEXT/VIM!]

  1. " Vim syntax file
  2. " Language:    Visual Basic
  3. " Maintainer:    Robert M. Cortopassi <cortopar@mindspring.com>
  4. " Last change:    January 14, 1999
  5.  
  6. " This was thrown together after seeing numerous requests on the
  7. " VIM and VIM-DEV mailing lists.  It is by no means complete.
  8. " Send comments, suggestions and requests to the maintainer.
  9.  
  10. " Remove any old syntax stuff hanging around
  11. syn clear
  12.  
  13. " VB is case insensitive
  14. syn case ignore
  15.  
  16. syn keyword vbStatement AppActivate Base Beep Call Case ChDir ChDrive Const
  17. syn keyword vbStatement Declare DefBool DefByte DefCur DefDate DefDbl DefDec
  18. syn keyword vbStatement DefInt DefLng DefObj DefSng DefStr Deftype DefVar
  19. syn keyword vbStatement DeleteSetting Dim Do Else End Enum Erase Event Exit
  20. syn keyword vbStatement Explicit FileCopy For ForEach Funtion Get GoSub GoTo
  21. syn keyword vbStatement If Implements Kill Let LineInput Lock LSet MkDir Name
  22. syn keyword vbStatement OnError On Option Private Property Public Put RaiseEvent
  23. syn keyword vbStatement Randomize ReDim Rem Reset Resume Return RmDir RSet
  24. syn keyword vbStatement SavePicture SaveSetting SendKeys SetAttr Static Sub Then
  25. syn keyword vbStatement Type Unlock Wend While Width With Write
  26.  
  27. syn keyword vbFunction Abs Array Asc AscB AscW Atn Avg
  28. syn keyword vbFunction CBool CByte CCur CDate CDbl Cdec Choose Chr ChrB ChrW
  29. syn keyword vbFunction CInt CLng Command Cos Count CreateObject CSng CStr
  30. syn keyword vbFunction CurDir CVar CVDate CVErr Date DateAdd DateDiff DatePart
  31. syn keyword vbFunction DateSerial DateValue Day DDB Dir DoEvents Environ EOF
  32. syn keyword vbFunction Error Exp FileAttr FileDateTime FileLen Fix Format
  33. syn keyword vbFunction FreeFile FV GetAllStrings GetAttr GetAutoServerSettings
  34. syn keyword vbFunction GetObject GetSetting Hex Hour IIf IMEStatus Input InputB
  35. syn keyword vbFunction InputBox InStr InstB Int IPmt IsArray IsDate IsEmpty
  36. syn keyword vbFunction IsError IsMissing IsNull IsNumeric IsObject LBound LCase
  37. syn keyword vbFunction Left LeftB Len LenB LoadPicture Loc LOF Log LTrim Max
  38. syn keyword vbFunction Mid MidB Min Minute MIRR Month MsgBox Now NPer NPV Oct
  39. syn keyword vbFunction Partition Pmt PPmt PV QBColor Rate RGB Right RightB Rnd
  40. syn keyword vbFunction RTrim Second Seek Sgn Shell Sin SLN Space Spc Sqr StDev
  41. syn keyword vbFunction StDevP Str StrComp StrConv String Switch Sum SYD Tab Tan
  42. syn keyword vbFunction Time Timer TimeSerial TimeValue Trim TypeName UBound UCase
  43. syn keyword vbFunction Val Var VarP VarType Weekday Year
  44.  
  45. syn keyword vbMethods Accept Activate Add AddCustom AddFile AddFromFile
  46. syn keyword vbMethods AddFromTemplate AddItem AddNew AddToAddInToolbar
  47. syn keyword vbMethods AddToolboxProgID Append AppendChunk Arrange Assert
  48. syn keyword vbMethods AsyncRead BatchUpdate BeginTrans Bind Cancel CancelAsyncRead
  49. syn keyword vbMethods CancelBatch CancelUpdate CanPropertyChange CaptureImage
  50. syn keyword vbMethods CellText CellValue Circle Clear ClearFields ClearSel
  51. syn keyword vbMethods ClearSelCols Clone Close Cls ColContaining ColumnSize
  52. syn keyword vbMethods CommitTrans CompactDatabase Compose Connect Copy
  53. syn keyword vbMethods CopyQueryDef CreateDatabase CreateDragImage CreateEmbed
  54. syn keyword vbMethods CreateField CreateGroup CreateIndex CreateLink
  55. syn keyword vbMethods CreatePreparedStatement CreatePropery CreateQuery
  56. syn keyword vbMethods CreateQueryDef CreateRelation CreateTableDef CreateUser
  57. syn keyword vbMethods CreateWorkspace Customize Delete DeleteColumnLabels
  58. syn keyword vbMethods DeleteColumns DeleteRowLabels DeleteRows DoVerb Drag Draw
  59. syn keyword vbMethods Edit EditCopy EditPaste EndDoc EnsureVisible
  60. syn keyword vbMethods EstablishConnection Execute ExtractIcon Fetch FetchVerbs
  61. syn keyword vbMethods Files FillCache Find FindFirst FindItem FindLast FindNext
  62. syn keyword vbMethods FindPrevious Forward GetBookmark GetChunk GetClipString
  63. syn keyword vbMethods GetData GetFirstVisible GetFormat GetHeader GetLineFromChar
  64. syn keyword vbMethods GetNumTicks GetRows GetSelectedPart GetText GetVisibleCount
  65. syn keyword vbMethods GoBack GoForward Hide HitTest HoldFields Idle
  66. syn keyword vbMethods InitializeLabels InsertColumnLabels InsertColumns
  67. syn keyword vbMethods InsertObjDlg InsertRowLabels InsertRows Item KillDoc
  68. syn keyword vbMethods Layout Line LinkExecute LinkPoke LinkRequest LinkSend Listen
  69. syn keyword vbMethods LoadFile LoadResData LoadResPicture LoadResString LogEvent
  70. syn keyword vbMethods MakeCompileFile MakeReplica MoreResults Move MoveData
  71. syn keyword vbMethods MoveFirst MoveLast MoveNext MovePrevious NavigateTo NewPage
  72. syn keyword vbMethods NewPassword NextRecordset OLEDrag OnAddinsUpdate
  73. syn keyword vbMethods OnConnection OnDisconnection OnStartupComplete Open
  74. syn keyword vbMethods OpenConnection OpenDatabase OpenQueryDef OpenRecordset
  75. syn keyword vbMethods OpenResultset OpenURL Overlay PaintPicture Paste
  76. syn keyword vbMethods PastSpecialDlg PeekData Play Point PopulatePartial PopupMenu
  77. syn keyword vbMethods Print PrintForm PropertyChanged PSet Quit Raise
  78. syn keyword vbMethods RandomDataFill RandomFillColumns RandomFillRows
  79. syn keyword vbMethods rdoCreateEnvironment rdoRegisterDataSource ReadFromFile
  80. syn keyword vbMethods ReadProperty Rebind ReFill Refresh RefreshLink
  81. syn keyword vbMethods RegisterDatabase Reload Remove RemoveAddInFromToolbar
  82. syn keyword vbMethods RemoveItem Render RepairDatabase Reply ReplyAll Requery
  83. syn keyword vbMethods ResetCustom ResetCustomLabel ResolveName RestoreToolbar
  84. syn keyword vbMethods Resync Rollback RollbackTrans RowBookmark RowContaining
  85. syn keyword vbMethods RowTop Save SaveAs SaveFile SaveToFile SaveToolbar
  86. syn keyword vbMethods SaveToOle1File Scale ScaleX ScaleY Scroll Select SelectAll
  87. syn keyword vbMethods SelectPart SelPrint Send SendData Set SetAutoServerSettings
  88. syn keyword vbMethods SetData SetFocus SetOption SetSize SetText SetViewport Show
  89. syn keyword vbMethods ShowColor ShowFont ShowHelp ShowOpen ShowPrinter ShowSave
  90. syn keyword vbMethods ShowWhatsThis SignOff SignOn Size Span SplitContaining
  91. syn keyword vbMethods StartLabelEdit StartLogging Stop Synchronize TextHeight
  92. syn keyword vbMethods TextWidth ToDefaults TwipsToChartPart TypeByChartType
  93. syn keyword vbMethods Update UpdateControls UpdateRecord UpdateRow Upto
  94. syn keyword vbMethods WhatsThisMode WriteProperty ZOrder
  95.  
  96. syn keyword vbEvents AccessKeyPress AfterAddFile AfterChangeFileName
  97. syn keyword vbEvents AfterCloseFile AfterColEdit AfterColUpdate
  98. syn keyword vbEvents AfterDelete AfterInsert AfterLabelEdit AfterRemoveFile
  99. syn keyword vbEvents AfterUpdate AfterWriteFile AmbienChanged ApplyChanges
  100. syn keyword vbEvents Associate AsyncReadComplete AxisActivated AxisLabelActivated
  101. syn keyword vbEvents AxisLabelSelected AxisLabelUpdated AxisSelected
  102. syn keyword vbEvents AxisTitleActivated AxisTitleSelected AxisTitleUpdated
  103. syn keyword vbEvents AxisUpdated BeforeClick BeforeColEdit BeforeColUpdate
  104. syn keyword vbEvents BeforeConnect BeforeDelete BeforeInsert BeforeLabelEdit
  105. syn keyword vbEvents BeforeLoadFile BeforeUpdate ButtonClick ButtonCompleted
  106. syn keyword vbEvents ButtonGotFocus ButtonLostFocus Change ChartActivated
  107. syn keyword vbEvents ChartSelected ChartUpdated Click ColEdit Collapse
  108. syn keyword vbEvents ColResize ColumnClick Compare ConfigChageCancelled
  109. syn keyword vbEvents ConfigChanged ConnectionRequest DataArrival DataChanged
  110. syn keyword vbEvents DataUpdated DblClick Deactivate DeviceArrival
  111. syn keyword vbEvents DeviceOtherEvent DeviceQueryRemove DeviceQueryRemoveFailed
  112. syn keyword vbEvents DeviceRemoveComplete DeviceRemovePending DevModeChange
  113. syn keyword vbEvents Disconnect DisplayChanged Dissociate DoGetNewFileName Done
  114. syn keyword vbEvents DonePainting DownClick DragDrop DragOver DropDown
  115. syn keyword vbEvents EditProperty EnterCell EnterFocus ExitFocus Expand
  116. syn keyword vbEvents FootnoteActivated FootnoteSelected FootnoteUpdated GotFocus
  117. syn keyword vbEvents HeadClick InfoMessage Initialize IniProperties ItemActivated
  118. syn keyword vbEvents ItemAdded ItemCheck ItemClick ItemReloaded ItemRemoved
  119. syn keyword vbEvents ItemRenamed ItemSeletected KeyDown KeyPress KeyUp LeaveCell
  120. syn keyword vbEvents LegendActivated LegendSelected LegendUpdated LinkClose
  121. syn keyword vbEvents LinkError LinkNotify LinkOpen Load LostFocus MouseDown
  122. syn keyword vbEvents MouseMove MouseUp NodeClick ObjectMove OLECompleteDrag
  123. syn keyword vbEvents OLEDragDrop OLEDragOver OLEGiveFeedback OLESetData
  124. syn keyword vbEvents OLEStartDrag OnAddNew OnComm Paint PanelClick PanelDblClick
  125. syn keyword vbEvents PathChange PatternChange PlotActivated PlotSelected
  126. syn keyword vbEvents PlotUpdated PointActivated PointLabelActivated
  127. syn keyword vbEvents PointLabelSelected PointLabelUpdated PointSelected
  128. syn keyword vbEvents PointUpdated PowerQuerySuspend PowerResume PowerStatusChanged
  129. syn keyword vbEvents PowerSuspend QueryChangeConfig QueryComplete QueryCompleted
  130. syn keyword vbEvents QueryTimeout QueryUnload ReadProperties Reposition
  131. syn keyword vbEvents RequestChangeFileName RequestWriteFile Resize ResultsChanged
  132. syn keyword vbEvents RowColChange RowCurrencyChange RowResize RowStatusChanged
  133. syn keyword vbEvents SelChange SelectionChanged SendComplete SendProgress
  134. syn keyword vbEvents SeriesActivated SeriesSelected SeriesUpdated SettingChanged
  135. syn keyword vbEvents SplitChange StateChanged StatusUpdate SysColorsChanged
  136. syn keyword vbEvents Terminate TimeChanged TitleActivated TitleSelected
  137. syn keyword vbEvents TitleActivated UnboundAddData UnboundDeleteRow
  138. syn keyword vbEvents UnboundGetRelativeBookmark UnboundReadData UnboundWriteData
  139. syn keyword vbEvents Unload UpClick Updated Validate ValidationError
  140. syn keyword vbEvents WillAssociate WillChangeData WillDissociate WillExecute
  141. syn keyword vbEvents WillUpdateRows WriteProperties
  142.  
  143. syn keyword vbTodo contained    TODO
  144.  
  145. "integer number, or floating point number without a dot.
  146. syn match  vbNumber        "\<\d\+\>"
  147. "floating point number, with dot
  148. syn match  vbNumber        "\<\d\+\.\d*\>"
  149. "floating point number, starting with a dot
  150. syn match  vbNumber        "\.\d\+\>"
  151.  
  152. " String and Character contstants
  153. syn region  vbString          start=+"+  end=+"+
  154. syn region  vbComment    start="REM" end="$" contains=vbTodo
  155. syn region  vbComment   start="'"   end="$" contains=vbTodo
  156. syn region  vbLineNumber    start="^\d" end="\s"
  157. syn match   vbTypeSpecifier  "[a-zA-Z0-9][\$%&!#]"ms=s+1
  158.  
  159. if !exists("did_vb_syntax_inits")
  160.   let did_vb_syntax_inits = 1
  161.   " The default methods for highlighting.  Can be overridden later
  162.   hi link vbLineNumber            Comment
  163.   hi link vbNumber        Number
  164.   hi link vbError        Error
  165.   hi link vbStatement            Statement
  166.   hi link vbString        String
  167.   hi link vbComment        Comment
  168.   hi link vbTodo        Todo
  169.   hi link vbFunction        Identifier
  170.   hi link vbMethods             PreProc
  171.   hi link vbEvents              Special
  172.   hi link vbTypeSpecifier       Type
  173. endif
  174.  
  175. let b:current_syntax = "vb"
  176.  
  177. " vim: ts=8
  178.