A tumblelog CMS built on AJAX, PHP and MySQL.

smalltalk.php 4.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160
  1. <?php
  2. /*************************************************************************************
  3. * smalltalk.php
  4. * --------
  5. * Author: Bananeweizen (Bananeweizen@gmx.de)
  6. * Copyright: (c) 2005 Bananeweizen (www.bananeweizen.de)
  7. * Release Version: 1.0.7.21
  8. * Date Started: 2005/03/27
  9. *
  10. * Smalltalk language file for GeSHi.
  11. *
  12. * CHANGES
  13. * -------
  14. * 2006-05-24 (1.0.0)
  15. * - First Release
  16. *
  17. * TODO
  18. * -------------------------
  19. * * recognize nested array symbols correctly
  20. *
  21. *************************************************************************************
  22. *
  23. * This file is part of GeSHi.
  24. *
  25. * GeSHi is free software; you can redistribute it and/or modify
  26. * it under the terms of the GNU General Public License as published by
  27. * the Free Software Foundation; either version 2 of the License, or
  28. * (at your option) any later version.
  29. *
  30. * GeSHi is distributed in the hope that it will be useful,
  31. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  32. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  33. * GNU General Public License for more details.
  34. *
  35. * You should have received a copy of the GNU General Public License
  36. * along with GeSHi; if not, write to the Free Software
  37. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  38. *
  39. ************************************************************************************/
  40. $language_data = array (
  41. 'LANG_NAME' => 'Smalltalk',
  42. 'COMMENT_SINGLE' => array(),
  43. 'COMMENT_MULTI' => array('"' => '"'),
  44. 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE,
  45. 'QUOTEMARKS' => array("'"),
  46. 'ESCAPE_CHAR' => '',
  47. 'KEYWORDS' => array(
  48. 1 => array('self','super','true','false','nil')
  49. ),
  50. 'SYMBOLS' => array(
  51. '[', ']', '=' , ':=', '(', ')', '#'
  52. ),
  53. 'CASE_SENSITIVE' => array(
  54. GESHI_COMMENTS => false,
  55. 1 => true
  56. ),
  57. 'STYLES' => array(
  58. 'KEYWORDS' => array(
  59. 1 => 'color: #7f007f;'
  60. ),
  61. 'COMMENTS' => array(
  62. 'MULTI' => 'color: #007f00; font-style: italic;'
  63. ),
  64. 'ESCAPE_CHAR' => array(
  65. 0 => ''
  66. ),
  67. 'BRACKETS' => array(
  68. 0 => ''
  69. ),
  70. 'STRINGS' => array(
  71. 0 => 'color: #7f0000;'
  72. ),
  73. 'NUMBERS' => array(
  74. 0 => 'color: #7f0000;'
  75. ),
  76. 'METHODS' => array(
  77. 0 => ''
  78. ),
  79. 'SYMBOLS' => array(
  80. 0 => 'color: #000066; font-weight:bold;'
  81. ),
  82. 'REGEXPS' => array(
  83. 0 => 'color: #0000ff;',
  84. 1 => 'color: #7f0000;',
  85. 2 => 'color: #7f0000;',
  86. 3 => 'color: #00007f;',
  87. 4 => 'color: #7f007f;',
  88. 5 => 'color: #00007f;',
  89. 6 => 'color: #00007f;'
  90. ),
  91. 'SCRIPT' => array(
  92. 0 => ''
  93. )
  94. ),
  95. 'URLS' => array(
  96. ),
  97. 'OOLANG' => false,
  98. 'OBJECT_SPLITTERS' => array(
  99. ),
  100. 'REGEXPS' => array(
  101. 0 => array(
  102. GESHI_SEARCH => '([^a-zA-Z0-9_#])([A-Z]+[a-zA-Z0-9_]*)', //class names
  103. GESHI_REPLACE => '\\2',
  104. GESHI_MODIFIERS => '',
  105. GESHI_BEFORE => '\\1',
  106. GESHI_AFTER => ''
  107. ),
  108. 1 => array(
  109. GESHI_SEARCH => '(#+)([a-zA-Z0-9_]+)', //symbols
  110. GESHI_REPLACE => '\\1\\2',
  111. GESHI_MODIFIERS => '',
  112. GESHI_BEFORE => '',
  113. GESHI_AFTER => ''
  114. ),
  115. 2 => array(
  116. GESHI_SEARCH => '(#\s*\([^)]*\))', //array symbols
  117. GESHI_REPLACE => '\\1',
  118. GESHI_MODIFIERS => '',
  119. GESHI_BEFORE => '',
  120. GESHI_AFTER => ''
  121. ),
  122. 3 => array(
  123. GESHI_SEARCH => '\|([a-zA-Z0-9_\s]+)\|', //temporary variables
  124. GESHI_REPLACE => '\\1',
  125. GESHI_MODIFIERS => '',
  126. GESHI_BEFORE => '|',
  127. GESHI_AFTER => '|'
  128. ),
  129. 4 => array(
  130. GESHI_SEARCH => '(self|super|true|false|nil)', //keywords again (to avoid matching in next regexp)
  131. GESHI_REPLACE => '\\1',
  132. GESHI_MODIFIERS => '',
  133. GESHI_BEFORE => '',
  134. GESHI_AFTER => ''
  135. ),
  136. 5 => array(
  137. GESHI_SEARCH => '([:(,=[.*/+-]\s*)([a-zA-Z0-9_]+)', //message parameters, message receivers
  138. GESHI_REPLACE => '\\2',
  139. GESHI_MODIFIERS => 's',
  140. GESHI_BEFORE => '\\1',
  141. GESHI_AFTER => ''
  142. ),
  143. 6 => array(
  144. GESHI_SEARCH => '([a-zA-Z0-9_]+)(\s*:=)', //assignment targets
  145. GESHI_REPLACE => '\\1',
  146. GESHI_MODIFIERS => '',
  147. GESHI_BEFORE => '',
  148. GESHI_AFTER => '\\2'
  149. )
  150. ),
  151. 'STRICT_MODE_APPLIES' => GESHI_NEVER,
  152. 'SCRIPT_DELIMITERS' => array(
  153. ),
  154. 'HIGHLIGHT_STRICT_BLOCK' => array(
  155. )
  156. );
  157. ?>