KXStudio Website https://kx.studio/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

zxbasic.php 4.8KB

11 years ago
11 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. <?php
  2. /*************************************************************************************
  3. * zxbasic.php
  4. * -------------
  5. * Author: Jose Rodriguez (a.k.a. Boriel)
  6. * Based on Copyright: (c) 2005 Roberto Rossi (http://rsoftware.altervista.org) Freebasic template
  7. * Release Version: 1.0.8.11
  8. * Date Started: 2010/06/19
  9. *
  10. * ZXBasic language file for GeSHi.
  11. *
  12. * More details at http://www.zxbasic.net/
  13. *
  14. * CHANGES
  15. * -------
  16. * 2010/06/19 (1.0.0)
  17. * - First Release
  18. *
  19. * TODO (updated 2007/02/06)
  20. * -------------------------
  21. *
  22. *************************************************************************************
  23. *
  24. * This file is part of GeSHi.
  25. *
  26. * GeSHi is free software; you can redistribute it and/or modify
  27. * it under the terms of the GNU General Public License as published by
  28. * the Free Software Foundation; either version 2 of the License, or
  29. * (at your option) any later version.
  30. *
  31. * GeSHi is distributed in the hope that it will be useful,
  32. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  33. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  34. * GNU General Public License for more details.
  35. *
  36. * You should have received a copy of the GNU General Public License
  37. * along with GeSHi; if not, write to the Free Software
  38. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  39. *
  40. ************************************************************************************/
  41. $language_data = array (
  42. 'LANG_NAME' => 'ZXBasic',
  43. 'COMMENT_SINGLE' => array(
  44. 1 => "'",
  45. 2 => '#',
  46. 3 => 'REM'
  47. ),
  48. 'COMMENT_MULTI' => array("/'" => "'/"),
  49. 'CASE_KEYWORDS' => GESHI_CAPS_UPPER, //GESHI_CAPS_NO_CHANGE,
  50. 'QUOTEMARKS' => array('"'),
  51. 'ESCAPE_CHAR' => '\\',
  52. 'KEYWORDS' => array(
  53. 1 => array(
  54. "ASM", "BEEP", "BOLD", "BORDER", "BRIGHT", "ByRef", "ByVal", "CAST",
  55. "CIRCLE", "CLS", "CONST", "CONTINUE", "DECLARE", "DIM", "DO",
  56. "DRAW", "ELSE", "ELSEIF", "END", "EXIT", "FastCall", "FLASH", "FOR",
  57. "FUNCTION", "GOTO", "GOSUB", "GO", "IF", "INK", "INVERSE", "ITALIC",
  58. "LET", "LOAD", "LOOP", "NEXT", "OVER", "PAPER", "PAUSE", "PI",
  59. "PLOT", "POKE", "PRINT", "RANDOMIZE", "REM", "RETURN", "SAVE",
  60. "StdCall", "Sub", "THEN", "TO", "UNTIL", "VERIFY", "WEND", "WHILE",
  61. ),
  62. // types
  63. 2 => array(
  64. 'byte', 'ubyte', 'integer', 'uinteger', 'long', 'ulong', 'fixed',
  65. 'float', 'string'
  66. ),
  67. // Functions
  68. 3 => array(
  69. "ABS", "ACS", "ASN", "ATN", "CHR", "CODE", "COS", "CSRLIN", "EXP",
  70. "HEX", "HEX16", "INKEY", "INT", "LEN", "LN", "PEEK", "POS", "RND",
  71. "SCREEN$", "SGN", "SIN", "SQR", "STR", "TAN", "VAL",
  72. ),
  73. // Operators and modifiers
  74. 4 => array(
  75. "AT", "AS", "AND", "MOD", "NOT", "OR", "SHL", "SHR", "STEP", "XOR"
  76. )
  77. ),
  78. 'SYMBOLS' => array(
  79. '(', ')'
  80. ),
  81. 'CASE_SENSITIVE' => array(
  82. GESHI_COMMENTS => false,
  83. 1 => false,
  84. 2 => false,
  85. 3 => false,
  86. 4 => false
  87. ),
  88. 'STYLES' => array(
  89. 'KEYWORDS' => array(
  90. 1 => 'color: #000080; font-weight: bold;', // Commands
  91. 2 => 'color: #800080; font-weight: bold;', // Types
  92. 3 => 'color: #006000; font-weight: bold;', // Functions
  93. 4 => 'color: #801010; font-weight: bold;' // Operators and Modifiers
  94. ),
  95. 'COMMENTS' => array(
  96. 1 => 'color: #808080; font-style: italic;',
  97. 2 => 'color: #339933;',
  98. 3 => 'color: #808080; font-style: italic;',
  99. 'MULTI' => 'color: #808080; font-style: italic;'
  100. ),
  101. 'BRACKETS' => array(
  102. //0 => 'color: #66cc66;'
  103. 0 => 'color: #007676;'
  104. ),
  105. 'STRINGS' => array(
  106. //0 => 'color: #ff0000;'
  107. 0 => 'color: #A00000; font-style: italic;'
  108. ),
  109. 'NUMBERS' => array(
  110. //0 => 'color: #cc66cc;'
  111. 0 => 'color: #b05103;'// font-weight: bold;'
  112. ),
  113. 'METHODS' => array(
  114. 0 => 'color: #66cc66;'
  115. ),
  116. 'SYMBOLS' => array(
  117. 0 => 'color: #66cc66;'
  118. ),
  119. 'ESCAPE_CHAR' => array(
  120. 0 => 'color: #000099;'
  121. ),
  122. 'SCRIPT' => array(
  123. ),
  124. 'REGEXPS' => array(
  125. )
  126. ),
  127. 'URLS' => array(
  128. 1 => '',
  129. 2 => '',
  130. 3 => '',
  131. 4 => ''
  132. ),
  133. 'OOLANG' => true,
  134. 'OBJECT_SPLITTERS' => array(
  135. 1 => '.'
  136. ),
  137. 'REGEXPS' => array(
  138. ),
  139. 'STRICT_MODE_APPLIES' => GESHI_NEVER,
  140. 'SCRIPT_DELIMITERS' => array(
  141. ),
  142. 'HIGHLIGHT_STRICT_BLOCK' => array(
  143. )
  144. );
  145. ?>