tssgm.vim 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. " Vim syntax file
  2. " Language: TSS (Thermal Synthesizer System) Geometry
  3. " Maintainer: Adrian Nagle, anagle@ball.com
  4. " Last Change: 2003 May 11
  5. " Filenames: *.tssgm
  6. " URL: http://www.naglenet.org/vim/syntax/tssgm.vim
  7. " MAIN URL: http://www.naglenet.org/vim/
  8. " quit when a syntax file was already loaded
  9. if exists("b:current_syntax")
  10. finish
  11. endif
  12. " Ignore case
  13. syn case ignore
  14. "
  15. "
  16. " Begin syntax definitions for tss geomtery file.
  17. "
  18. " Define keywords for TSS
  19. syn keyword tssgmParam units mirror param active sides submodel include
  20. syn keyword tssgmParam iconductor nbeta ngamma optics material thickness color
  21. syn keyword tssgmParam initial_temp
  22. syn keyword tssgmParam initial_id node_ids node_add node_type
  23. syn keyword tssgmParam gamma_boundaries gamma_add beta_boundaries
  24. syn keyword tssgmParam p1 p2 p3 p4 p5 p6 rot1 rot2 rot3 tx ty tz
  25. syn keyword tssgmSurfType rectangle trapezoid disc ellipse triangle
  26. syn keyword tssgmSurfType polygon cylinder cone sphere ellipic-cone
  27. syn keyword tssgmSurfType ogive torus box paraboloid hyperboloid ellipsoid
  28. syn keyword tssgmSurfType quadrilateral trapeziod
  29. syn keyword tssgmArgs OUT IN DOWN BOTH DOUBLE NONE SINGLE RADK CC FECC
  30. syn keyword tssgmArgs white red blue green yellow orange violet pink
  31. syn keyword tssgmArgs turquoise grey black
  32. syn keyword tssgmArgs Arithmetic Boundary Heater
  33. syn keyword tssgmDelim assembly
  34. syn keyword tssgmEnd end
  35. syn keyword tssgmUnits cm feet meters inches
  36. syn keyword tssgmUnits Celsius Kelvin Fahrenheit Rankine
  37. " Define matches for TSS
  38. syn match tssgmDefault "^DEFAULT/LENGTH = \(ft\|in\|cm\|m\)"
  39. syn match tssgmDefault "^DEFAULT/TEMP = [CKFR]"
  40. syn match tssgmComment /comment \+= \+".*"/ contains=tssParam,tssgmCommentString
  41. syn match tssgmCommentString /".*"/ contained
  42. syn match tssgmSurfIdent " \S\+\.\d\+ \=$"
  43. syn match tssgmString /"[^" ]\+"/ms=s+1,me=e-1 contains=ALLBUT,tssInteger
  44. syn match tssgmArgs / = [xyz],"/ms=s+3,me=e-2
  45. syn match tssgmInteger "-\=\<[0-9]*\>"
  46. syn match tssgmFloat "-\=\<[0-9]*\.[0-9]*"
  47. syn match tssgmScientific "-\=\<[0-9]*\.[0-9]*E[-+]\=[0-9]\+\>"
  48. " Define the default highlighting
  49. " Only when an item doesn't have highlighting yet
  50. hi def link tssgmParam Statement
  51. hi def link tssgmSurfType Type
  52. hi def link tssgmArgs Special
  53. hi def link tssgmDelim Typedef
  54. hi def link tssgmEnd Macro
  55. hi def link tssgmUnits Special
  56. hi def link tssgmDefault SpecialComment
  57. hi def link tssgmComment Statement
  58. hi def link tssgmCommentString Comment
  59. hi def link tssgmSurfIdent Identifier
  60. hi def link tssgmString Delimiter
  61. hi def link tssgmInteger Number
  62. hi def link tssgmFloat Float
  63. hi def link tssgmScientific Float
  64. let b:current_syntax = "tssgm"
  65. " vim: ts=8 sw=2