plugins/geshi/geshi/delphi.php
changeset 2 9e3258dfae15
parent 0 441963e5b07a
child 3 f3e2bbbd2155
--- a/plugins/geshi/geshi/delphi.php	Sun Feb 10 19:00:04 2008 -0500
+++ b/plugins/geshi/geshi/delphi.php	Fri May 29 19:30:59 2009 -0400
@@ -2,15 +2,17 @@
 /*************************************************************************************
  * delphi.php
  * ----------
- * Author: Járja Norbert (jnorbi@vipmail.hu)
- * Copyright: (c) 2004 Járja Norbert, Nigel McNie (http://qbnz.com/highlighter)
- * Release Version: 1.0.7.20
+ * Author: J�rja Norbert (jnorbi@vipmail.hu), Benny Baumann (BenBE@omorphia.de)
+ * Copyright: (c) 2004 J�rja Norbert, Benny Baumann (BenBE@omorphia.de), Nigel McNie (http://qbnz.com/highlighter)
+ * Release Version: 1.0.8.2
  * Date Started: 2004/07/26
  *
  * Delphi (Object Pascal) language file for GeSHi.
  *
  * CHANGES
  * -------
+ * 2008/05/23 (1.0.7.22)
+ *   -  Added description of extra language features (SF#1970248)
  * 2005/11/19 (1.0.3)
  *   -  Updated the very incomplete keyword and type lists
  * 2005/09/03 (1.0.2)
@@ -47,23 +49,26 @@
     'LANG_NAME' => 'Delphi',
     'COMMENT_SINGLE' => array(1 => '//'),
     'COMMENT_MULTI' => array('(*' => '*)', '{' => '}'),
+    //Compiler directives
+    'COMMENT_REGEXP' => array(2 => '/{\\$.*?}|\\(\\*\\$.*?\\*\\)/U'),
     'CASE_KEYWORDS' => 0,
-    'QUOTEMARKS' => array("'", '"'),
+    'QUOTEMARKS' => array("'"),
     'ESCAPE_CHAR' => '',
     'KEYWORDS' => array(
         1 => array(
-            'Abstract', 'And', 'Array', 'As', 'Asm', 'At', 'Begin', 'Case', 'Class',
-            'Const', 'Constructor', 'Contains', 'Destructor', 'DispInterface', 'Div',
-            'Do', 'DownTo', 'Else', 'End', 'Except', 'File', 'Finalization',
-            'Finally', 'For', 'Function', 'Goto', 'If', 'Implementation', 'In',
-            'Inherited', 'Initialization', 'Inline', 'Interface', 'Is', 'Label',
+            'Abstract', 'And', 'Array', 'As', 'Asm', 'At', 'Begin', 'Case',
+            'Class', 'Const', 'Constructor', 'Contains', 'Destructor',
+            'DispInterface', 'Div', 'Do', 'DownTo', 'Else', 'End', 'Except',
+            'Export', 'Exports', 'External', 'File', 'Finalization', 'Finally',
+            'For', 'Function', 'Goto', 'If', 'Implementation', 'In', 'Inherited',
+            'Initialization', 'Inline', 'Interface', 'Is', 'Label', 'Library',
             'Mod', 'Not', 'Object', 'Of', 'On', 'Or', 'Overload', 'Override',
             'Package', 'Packed', 'Private', 'Procedure', 'Program', 'Property',
-            'Protected', 'Public', 'Published', 'Raise', 'Record', 'Repeat',
-            'Requires', 'Resourcestring', 'Set', 'Shl', 'Shr', 'Then', 'ThreadVar',
-            'To', 'Try', 'Type', 'Unit', 'Until', 'Uses', 'Var', 'Virtual', 'While',
-            'With', 'Xor', 'assembler', 'cdecl', 'far', 'near', 'pascal', 'register',
-            'safecall', 'stdcall', 'varargs'
+            'Protected', 'Public', 'Published', 'Raise', 'Record', 'Register',
+            'Repeat', 'Requires', 'Resourcestring', 'Set', 'Shl', 'Shr', 'Then',
+            'ThreadVar', 'To', 'Try', 'Type', 'Unit', 'Until', 'Uses', 'Var',
+            'Virtual', 'While', 'With', 'Xor', 'assembler', 'far',
+            'near', 'pascal', 'register', 'cdecl', 'safecall', 'stdcall', 'varargs'
             ),
         2 => array(
             'nil', 'false', 'self', 'true', 'var', 'type', 'const'
@@ -205,33 +210,41 @@
             ),
         ),
     'CASE_SENSITIVE' => array(
-        GESHI_COMMENTS => true,
+        GESHI_COMMENTS => false,
         1 => false,
         2 => false,
         3 => false,
         4 => false,
         ),
+    'SYMBOLS' => array(
+        0 => array('(', ')', '[', ']'),
+        1 => array('.', ',', ':', ';'),
+        2 => array('@', '^'),
+        3 => array('=', '+', '-', '*', '/')
+        ),
     'STYLES' => array(
         'KEYWORDS' => array(
             1 => 'color: #000000; font-weight: bold;',
             2 => 'color: #000000; font-weight: bold;',
             3 => 'color: #000066;',
-            4 => 'color: #993333;'
+            4 => 'color: #000066; font-weight: bold;'
             ),
         'COMMENTS' => array(
             1 => 'color: #808080; font-style: italic;',
+            2 => 'color: #008000; font-style: italic;',
             'MULTI' => 'color: #808080; font-style: italic;'
             ),
         'ESCAPE_CHAR' => array(
+            0 => 'color: #ff0000; font-weight: bold;'
             ),
         'BRACKETS' => array(
-            0 => 'color: #66cc66;'
+            0 => 'color: #000066;'
             ),
         'STRINGS' => array(
             0 => 'color: #ff0000;'
             ),
         'NUMBERS' => array(
-            0 => 'color: #cc66cc;'
+            0 => 'color: #0000ff;'
             ),
         'METHODS' => array(
             1 => 'color: #006600;'
@@ -241,7 +254,10 @@
             1 => 'color: #ff0000;'
             ),
         'SYMBOLS' => array(
-            0 => 'color: #66cc66;'
+            0 => 'color: #000066;',
+            1 => 'color: #000066;',
+            2 => 'color: #000066;',
+            3 => 'color: #000066;'
             ),
         'SCRIPT' => array(
             )
@@ -257,7 +273,9 @@
         1 => '.'
         ),
     'REGEXPS' => array(
+        //Hex numbers
         0 => '\$[0-9a-fA-F]+',
+        //Characters
         1 => '\#\$?[0-9]{1,3}'
         ),
     'STRICT_MODE_APPLIES' => GESHI_NEVER,