f90.syntax 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240
  1. # ---------------------------------------------------
  2. # f90.syntax
  3. # FORTRAN 90/95 language freeform syntax highlighting template.
  4. # Provides syntax highlighting rules for the
  5. # FORTRAN programming language.
  6. #
  7. # Based on FORTRAN77 version fortran.syntax
  8. # Author: John Theal
  9. # Email: jtheal@renegadelinuxbox.dhs.org
  10. # December 7, 1999
  11. # ---------------------------------------------------
  12. # Heavily modified by Paul Sheer <psheer@obsidian.co.za>.
  13. # Adjusted to Fortran 90 by Norbert Nemec <Norbert@Nemec-online.de>.
  14. context default
  15. # keywords at the beginning of line
  16. keyword linestart \{0123456789\}\{0123456789\}\{0123456789\}\{0123456789\}\{0123456789\} brightred
  17. keyword linestart \{0123456789\}\{0123456789\}\{0123456789\}\{0123456789\} brightred
  18. keyword linestart \{0123456789\}\{0123456789\}\{0123456789\} brightred
  19. keyword linestart \{0123456789\}\{0123456789\} brightred
  20. keyword linestart \{0123456789\} brightred
  21. # structure
  22. keyword whole MODULE white black
  23. keyword whole SUBROUTINE white black
  24. keyword whole PROGRAM white black
  25. keyword whole FUNCTION white black
  26. keyword whole CONTAINS white black
  27. keyword whole END white black
  28. # boolean and logical expressions / operators
  29. keyword .and. brightred/orange
  30. keyword .eq. brightred/orange
  31. keyword .eqv. brightred/orange
  32. keyword .false. brightred/orange
  33. keyword .ge. brightred/orange
  34. keyword .gt. brightred/orange
  35. keyword .le. brightred/orange
  36. keyword .lt. brightred/orange
  37. keyword .ne. brightred/orange
  38. keyword .neqv. brightred/orange
  39. keyword .not. brightred/orange
  40. keyword .or. brightred/orange
  41. keyword .true. brightred/orange
  42. keyword whole lge brightred/orange
  43. keyword whole lgt brightred/orange
  44. keyword whole lle brightred/orange
  45. keyword whole llt brightred/orange
  46. # declarations
  47. keyword whole ALLOCATABLE brightcyan
  48. keyword whole BLOCK brightcyan
  49. keyword whole CHARACTER brightcyan
  50. keyword whole COMMON brightcyan
  51. keyword whole COMPLEX brightcyan
  52. keyword whole DATA brightcyan
  53. keyword whole DIMENSION brightcyan
  54. keyword whole DOUBLE brightcyan
  55. keyword whole EXTERNAL brightcyan
  56. keyword whole FORMAT brightcyan
  57. keyword whole IMPLICIT brightcyan
  58. keyword whole INTEGER brightcyan
  59. keyword whole INTENT brightcyan
  60. keyword whole INTRINSIC brightcyan
  61. keyword whole LOGICAL brightcyan
  62. keyword whole NONE brightcyan
  63. keyword whole ONLY brightcyan
  64. keyword whole OPTIONAL brightcyan
  65. keyword whole PARAMETER brightcyan
  66. keyword whole POINTER brightcyan
  67. keyword whole PRECISION brightcyan
  68. keyword whole PRIVATE brightcyan
  69. keyword whole PUBLIC brightcyan
  70. keyword whole REAL brightcyan
  71. keyword whole USE brightcyan
  72. # general programming syntax
  73. keyword whole allocate brightgreen
  74. keyword whole assign brightgreen
  75. keyword whole call brightgreen
  76. keyword whole continue brightgreen
  77. keyword whole do brightgreen
  78. keyword whole else brightgreen
  79. keyword whole elseif brightgreen
  80. keyword whole end brightgreen
  81. keyword whole enddo brightgreen
  82. keyword whole endif brightgreen
  83. keyword whole for brightgreen
  84. keyword whole goto brightgreen
  85. keyword whole if brightgreen
  86. keyword whole pause brightgreen
  87. keyword whole return brightgreen
  88. keyword whole stop brightgreen
  89. keyword whole then brightgreen
  90. keyword whole to brightgreen
  91. keyword whole while brightgreen
  92. # headers
  93. keyword whole entry brightgreen
  94. # I/O functions
  95. # may have optional equal signs after them: 'keyword ='
  96. keyword whole access brightmagenta
  97. keyword whole backspace brightmagenta
  98. keyword whole blank brightmagenta
  99. keyword whole close brightmagenta
  100. keyword whole direct brightmagenta
  101. keyword whole endfile brightmagenta
  102. keyword whole err brightmagenta
  103. keyword whole exist brightmagenta
  104. keyword whole file brightmagenta
  105. keyword whole fmt brightmagenta
  106. keyword whole form brightmagenta
  107. keyword whole formatted brightmagenta
  108. keyword whole inquire brightmagenta
  109. keyword whole iostat brightmagenta
  110. keyword whole name brightmagenta
  111. keyword whole named brightmagenta
  112. keyword whole nextrec brightmagenta
  113. keyword whole number brightmagenta
  114. keyword whole open brightmagenta
  115. keyword whole opened brightmagenta
  116. keyword whole print brightmagenta
  117. keyword whole read brightmagenta
  118. keyword whole rec brightmagenta
  119. keyword whole recl brightmagenta
  120. keyword whole rewind brightmagenta
  121. keyword whole sequential brightmagenta
  122. keyword whole status brightmagenta
  123. keyword whole unformatted brightmagenta
  124. keyword whole unit brightmagenta
  125. keyword whole write brightmagenta
  126. # mathematical functions
  127. keyword whole abs yellow
  128. keyword whole acos yellow
  129. keyword whole aimag yellow
  130. keyword whole aint yellow
  131. keyword whole alog yellow
  132. keyword whole alog10 yellow
  133. keyword whole amax0 yellow
  134. keyword whole amax1 yellow
  135. keyword whole amin0 yellow
  136. keyword whole amin1 yellow
  137. keyword whole amod yellow
  138. keyword whole anint yellow
  139. keyword whole aprime yellow
  140. keyword whole asin yellow
  141. keyword whole atan yellow
  142. keyword whole atan2 yellow
  143. keyword whole acos yellow
  144. keyword whole cabs yellow
  145. keyword whole cexp yellow
  146. keyword whole char yellow
  147. keyword whole clog yellow
  148. keyword whole cmplx yellow
  149. keyword whole conjg yellow
  150. keyword whole cos yellow
  151. keyword whole cosh yellow
  152. keyword whole ccos yellow
  153. keyword whole csin yellow
  154. keyword whole csqrt yellow
  155. keyword whole dabs yellow
  156. keyword whole dacos yellow
  157. keyword whole dasin yellow
  158. keyword whole datan yellow
  159. keyword whole datan2 yellow
  160. keyword whole dble yellow
  161. keyword whole dcos yellow
  162. keyword whole dcosh yellow
  163. keyword whole dfloat yellow
  164. keyword whole ddmim yellow
  165. keyword whole dexp yellow
  166. keyword whole dim yellow
  167. keyword whole dint yellow
  168. keyword whole dlog yellow
  169. keyword whole dlog10 yellow
  170. keyword whole dmax1 yellow
  171. keyword whole dmin1 yellow
  172. keyword whole dmod yellow
  173. keyword whole dnint yellow
  174. keyword whole dsign yellow
  175. keyword whole dsin yellow
  176. keyword whole dsinh yellow
  177. keyword whole dsqrt yellow
  178. keyword whole dtan yellow
  179. keyword whole dtanh yellow
  180. keyword whole equivalence yellow
  181. keyword whole exp yellow
  182. keyword whole float yellow
  183. keyword whole iabs yellow
  184. keyword whole ichar yellow
  185. keyword whole idim yellow
  186. keyword whole idint yellow
  187. keyword whole ifix yellow
  188. keyword whole index yellow
  189. keyword whole int yellow
  190. keyword whole isign yellow
  191. keyword whole len yellow
  192. keyword whole log yellow
  193. keyword whole log10 yellow
  194. keyword whole max yellow
  195. keyword whole max0 yellow
  196. keyword whole max1 yellow
  197. keyword whole min yellow
  198. keyword whole min0 yellow
  199. keyword whole min1 yellow
  200. keyword whole mod yellow
  201. keyword whole rand yellow
  202. keyword whole sign yellow
  203. keyword whole sin yellow
  204. keyword whole sinh yellow
  205. keyword whole sngl yellow
  206. keyword whole sqrt yellow
  207. keyword whole tan yellow
  208. keyword whole tanh yellow
  209. # operators and syntax elements
  210. keyword ( brightcyan
  211. keyword ) brightcyan
  212. keyword : brightcyan
  213. keyword , brightcyan
  214. keyword \+ yellow
  215. keyword - yellow
  216. keyword \* yellow
  217. keyword / yellow
  218. keyword = yellow
  219. keyword < yellow
  220. keyword > yellow
  221. # comments and quotes
  222. keyword '*' green
  223. context &\n & black cyan
  224. context format( ) green
  225. context ! \n brown
  226. spellcheck