A tumblelog CMS built on AJAX, PHP and MySQL.

csharp.php 6.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239
  1. <?php
  2. /*************************************************************************************
  3. * csharp.php
  4. * ----------
  5. * Author: Alan Juden (alan@judenware.org)
  6. * Copyright: (c) 2004 Alan Juden, Nigel McNie (http://qbnz.com/highlighter/)
  7. * Release Version: 1.0.7.21
  8. * Date Started: 2004/06/04
  9. *
  10. * C# language file for GeSHi.
  11. *
  12. * CHANGES
  13. * -------
  14. * 2005/01/05 (1.0.1)
  15. * - Used hardquote support for @"..." strings (Cliff Stanford)
  16. * 2004/11/27 (1.0.0)
  17. * - Initial release
  18. *
  19. * TODO (updated 2004/11/27)
  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' => 'C#',
  43. 'COMMENT_SINGLE' => array(1 => '//', 2 => '#'),
  44. 'COMMENT_MULTI' => array('/*' => '*/'),
  45. 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE,
  46. 'QUOTEMARKS' => array("'", '"'),
  47. 'HARDQUOTE' => array('@"', '"'),
  48. 'HARDESCAPE' => array('""'),
  49. 'ESCAPE_CHAR' => '\\',
  50. 'KEYWORDS' => array(
  51. 1 => array(
  52. 'as', 'auto', 'base', 'break', 'case', 'catch', 'const', 'continue',
  53. 'default', 'do', 'else', 'event', 'explicit', 'extern', 'false',
  54. 'finally', 'fixed', 'for', 'foreach', 'goto', 'if', 'implicit',
  55. 'in', 'internal', 'lock', 'namespace', 'null', 'operator', 'out',
  56. 'override', 'params', 'private', 'protected', 'public', 'readonly',
  57. 'ref', 'return', 'sealed', 'stackalloc', 'static', 'switch', 'this',
  58. 'throw', 'true', 'try', 'unsafe', 'using', 'virtual', 'void', 'while'
  59. ),
  60. 2 => array(
  61. '#elif', '#endif', '#endregion', '#else', '#error', '#define', '#if',
  62. '#line', '#region', '#undef', '#warning'
  63. ),
  64. 3 => array(
  65. 'checked', 'is', 'new', 'sizeof', 'typeof', 'unchecked'
  66. ),
  67. 4 => array(
  68. 'bool', 'byte', 'char', 'class', 'decimal', 'delegate', 'double',
  69. 'enum', 'float', 'int', 'interface', 'long', 'object', 'sbyte',
  70. 'short', 'string', 'struct', 'uint', 'ulong', 'ushort'
  71. ),
  72. 5 => array(
  73. 'Microsoft.Win32',
  74. 'System',
  75. 'System.CodeDOM',
  76. 'System.CodeDOM.Compiler',
  77. 'System.Collections',
  78. 'System.Collections.Bases',
  79. 'System.ComponentModel',
  80. 'System.ComponentModel.Design',
  81. 'System.ComponentModel.Design.CodeModel',
  82. 'System.Configuration',
  83. 'System.Configuration.Assemblies',
  84. 'System.Configuration.Core',
  85. 'System.Configuration.Install',
  86. 'System.Configuration.Interceptors',
  87. 'System.Configuration.Schema',
  88. 'System.Configuration.Web',
  89. 'System.Core',
  90. 'System.Data',
  91. 'System.Data.ADO',
  92. 'System.Data.Design',
  93. 'System.Data.Internal',
  94. 'System.Data.SQL',
  95. 'System.Data.SQLTypes',
  96. 'System.Data.XML',
  97. 'System.Data.XML.DOM',
  98. 'System.Data.XML.XPath',
  99. 'System.Data.XML.XSLT',
  100. 'System.Diagnostics',
  101. 'System.Diagnostics.SymbolStore',
  102. 'System.DirectoryServices',
  103. 'System.Drawing',
  104. 'System.Drawing.Design',
  105. 'System.Drawing.Drawing2D',
  106. 'System.Drawing.Imaging',
  107. 'System.Drawing.Printing',
  108. 'System.Drawing.Text',
  109. 'System.Globalization',
  110. 'System.IO',
  111. 'System.IO.IsolatedStorage',
  112. 'System.Messaging',
  113. 'System.Net',
  114. 'System.Net.Sockets',
  115. 'System.NewXml',
  116. 'System.NewXml.XPath',
  117. 'System.NewXml.Xsl',
  118. 'System.Reflection',
  119. 'System.Reflection.Emit',
  120. 'System.Resources',
  121. 'System.Runtime.InteropServices',
  122. 'System.Runtime.InteropServices.Expando',
  123. 'System.Runtime.Remoting',
  124. 'System.Runtime.Serialization',
  125. 'System.Runtime.Serialization.Formatters',
  126. 'System.Runtime.Serialization.Formatters.Binary',
  127. 'System.Security',
  128. 'System.Security.Cryptography',
  129. 'System.Security.Cryptography.X509Certificates',
  130. 'System.Security.Permissions',
  131. 'System.Security.Policy',
  132. 'System.Security.Principal',
  133. 'System.ServiceProcess',
  134. 'System.Text',
  135. 'System.Text.RegularExpressions',
  136. 'System.Threading',
  137. 'System.Timers',
  138. 'System.Web',
  139. 'System.Web.Caching',
  140. 'System.Web.Configuration',
  141. 'System.Web.Security',
  142. 'System.Web.Services',
  143. 'System.Web.Services.Description',
  144. 'System.Web.Services.Discovery',
  145. 'System.Web.Services.Protocols',
  146. 'System.Web.UI',
  147. 'System.Web.UI.Design',
  148. 'System.Web.UI.Design.WebControls',
  149. 'System.Web.UI.Design.WebControls.ListControls',
  150. 'System.Web.UI.HtmlControls',
  151. 'System.Web.UI.WebControls',
  152. 'System.WinForms',
  153. 'System.WinForms.ComponentModel',
  154. 'System.WinForms.Design',
  155. 'System.Xml',
  156. 'System.Xml.Serialization',
  157. 'System.Xml.Serialization.Code',
  158. 'System.Xml.Serialization.Schema'
  159. ),
  160. ),
  161. 'SYMBOLS' => array(
  162. '+', '-', '*', '?', '=', '/', '%', '&', '>', '<', '^', '!', '|', ':',
  163. '(', ')', '{', '}', '[', ']'
  164. ),
  165. 'CASE_SENSITIVE' => array(
  166. GESHI_COMMENTS => true,
  167. 1 => false,
  168. 2 => false,
  169. 3 => false,
  170. 4 => false,
  171. 5 => false,
  172. ),
  173. 'STYLES' => array(
  174. 'KEYWORDS' => array(
  175. 1 => 'color: #0600FF;',
  176. 2 => 'color: #FF8000; font-weight: bold;',
  177. 3 => 'color: #008000;',
  178. 4 => 'color: #FF0000;',
  179. 5 => 'color: #000000;'
  180. ),
  181. 'COMMENTS' => array(
  182. 1 => 'color: #008080; font-style: italic;',
  183. 2 => 'color: #008080;',
  184. 'MULTI' => 'color: #008080; font-style: italic;'
  185. ),
  186. 'ESCAPE_CHAR' => array(
  187. 0 => 'color: #008080; font-weight: bold;'
  188. ),
  189. 'BRACKETS' => array(
  190. 0 => 'color: #000000;'
  191. ),
  192. 'STRINGS' => array(
  193. 0 => 'color: #808080;'
  194. ),
  195. 'NUMBERS' => array(
  196. 0 => 'color: #FF0000;'
  197. ),
  198. 'METHODS' => array(
  199. 1 => 'color: #0000FF;',
  200. 2 => 'color: #0000FF;'
  201. ),
  202. 'SYMBOLS' => array(
  203. 0 => 'color: #008000;'
  204. ),
  205. 'REGEXPS' => array(
  206. ),
  207. 'SCRIPT' => array(
  208. )
  209. ),
  210. 'URLS' => array(
  211. 1 => '',
  212. 2 => '',
  213. 3 => 'http://www.google.com/search?q={FNAME}+msdn.microsoft.com',
  214. 4 => ''
  215. ),
  216. 'OOLANG' => true,
  217. 'OBJECT_SPLITTERS' => array(
  218. 1 => '.',
  219. 2 => '::'
  220. ),
  221. 'REGEXPS' => array(
  222. ),
  223. 'STRICT_MODE_APPLIES' => GESHI_NEVER,
  224. 'SCRIPT_DELIMITERS' => array(
  225. ),
  226. 'HIGHLIGHT_STRICT_BLOCK' => array(
  227. ),
  228. 'TAB_WIDTH' => 4,
  229. 'PARSER_CONTROL' => array(
  230. 'KEYWORDS' => array(
  231. 'DISALLOWED_BEFORE' => "a-zA-Z0-9\$_\|\#>|^",
  232. 'DISALLOWED_AFTER' => "a-zA-Z0-9_<\|%\\-"
  233. )
  234. )
  235. );
  236. ?>