You can subscribe to this list here.
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(68) |
Oct
(105) |
Nov
(44) |
Dec
(128) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(72) |
Feb
(102) |
Mar
(30) |
Apr
(85) |
May
(170) |
Jun
(102) |
Jul
(29) |
Aug
(16) |
Sep
(31) |
Oct
(22) |
Nov
(10) |
Dec
|
2017 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Nigel M. <ora...@us...> - 2005-09-15 01:18:43
|
Update of /cvsroot/geshi/geshi-src/geshi/classes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24290/geshi/classes Modified Files: class.geshistyler.php Log Message: Implemented aliasing: one context can call itself by another's name. Commented out a raft of unused code. Index: class.geshistyler.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/classes/class.geshistyler.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** class.geshistyler.php 25 Jul 2005 07:03:11 -0000 1.6 --- class.geshistyler.php 15 Sep 2005 01:18:36 -0000 1.7 *************** *** 71,103 **** var $_contextCacheData = array(); ! function setStyle ($context_name, $style) { $this->_styleData[$context_name] = $style; ! if (!isset($this->_styleData[$context_name . '/start'])) { ! $this->setStartStyle($context_name, $style); ! } ! if (!isset($this->_styleData[$context_name . '/end'])) { ! $this->setEndStyle($context_name, $style); } } ! function setStartStyle ($context_name, $style) { ! $this->_styleData[$context_name . '/start'] = $style; } ! function removeStyleData ($context_name) { unset($this->_styleData[$context_name]); ! unset($this->_styleData[$context_name . '/start']); ! unset($this->_styleData[$context_name . '/end']); //geshi_dbg(' removed style data for ' . $context_name, GESHI_DBG_PARSE); } ! function setEndStyle ($context_name, $style) { ! $this->_styleData[$context_name . '/end'] = $style; } function getStyle ($context_name) { --- 71,113 ---- var $_contextCacheData = array(); ! function setStyle ($context_name, $style, $start_name = 'start', $end_name = 'end') { $this->_styleData[$context_name] = $style; ! /*if (!isset($this->_styleData["$context_name/$start_name"])) { ! $this->_styleData["$context_name/$start_name"] = $style; } + if (!isset($this->_styleData["$context_name/$end_name"])) { + $this->_styleData["$context_name/$end_name"] = $style; + }*/ } ! /*function setStartStyle ($context_name, $style) { ! $this->_styleData["$context_name/$this->_startName"] = $style; } ! function setStartName ($name) ! { ! $this->_startName = $name; ! }*/ ! ! function removeStyleData ($context_name, $context_start_name = 'start', $context_end_name = 'end') { unset($this->_styleData[$context_name]); ! unset($this->_styleData["$context_name/$context_start_name"]); ! unset($this->_styleData["$context_name/$context_end_name"]); //geshi_dbg(' removed style data for ' . $context_name, GESHI_DBG_PARSE); } ! /*function setEndStyle ($context_name, $style) { ! $this->_styleData["$context_name/$this->_endName"] = $style; } + function setEndName ($name) + { + $this->_endName = $name; + }*/ + function getStyle ($context_name) { *************** *** 105,145 **** return $this->_styleData[$context_name]; } //@todo [blocking 1.1.5] Make the default style for otherwise unstyled elements configurable $this->_styleData[$context_name] = 'color:#000;'; return 'color:#000;'; } ! function getStyleStart ($context_name) { ! if (isset($this->_styleData[$context_name . '/start'])) { ! return $this->_styleData[$context_name . '/start']; } ! $this->_styleData[$context_name . '/start'] = $this->getStyle($context_name); ! return $this->_styleData[$context_name . '/start']; } function getStyleEnd ($context_name) { ! if (isset($this->_styleData[$context_name . '/end'])) { ! return $this->_styleData[$context_name . '/end']; } ! $this->_styleData[$context_name . '/end'] = $this->getStyle($context_name); ! return $this->_styleData[$context_name . '/start']; ! } ! function startIsUnique ($context_name) { ! return (isset($this->_styleData[$context_name . '/start']) && '' != $this->_styleData[$context_name . '/start'] ! && $this->_styleData[$context_name . '/start'] != $this->_styleData[$context_name]); } function endIsUnique ($context_name) { ! $r = (isset($this->_styleData[$context_name . '/end']) && '' != $this->_styleData[$context_name . '/end'] ! && $this->_styleData[$context_name . '/end'] != $this->_styleData[$context_name]); geshi_dbg('GeSHiStyler::endIsUnique(' . $context_name . ') = ' . $r, GESHI_DBG_PARSE); return $r; } ! function resetParseData () { --- 115,167 ---- return $this->_styleData[$context_name]; } + // If style for starter/ender requested and we got here, use the default + if ('/end' == substr($context_name, -4)) { + $this->_styleData[$context_name] = $this->_styleData[substr($context_name, 0, -4)]; + return $this->_styleData[$context_name]; + } + if ('/start' == substr($context_name, -6)) { + $this->_styleData[$context_name] = $this->_styleData[substr($context_name, 0, -6)]; + return $this->_styleData[$context_name]; + } + //@todo [blocking 1.1.5] Make the default style for otherwise unstyled elements configurable $this->_styleData[$context_name] = 'color:#000;'; return 'color:#000;'; } ! /* function getStyleStart ($context_name) { ! if (isset($this->_styleData["$context_name/$this->_startName"])) { ! return $this->_styleData["$context_name/$this->_startName"]; } ! $this->_styleData["$context_name/$this->_startName"] = $this->getStyle($context_name); ! return $this->_styleData["$context_name/$this->_startName"]; } function getStyleEnd ($context_name) { ! if (isset($this->_styleData["$context_name/$this->_endName"])) { ! return $this->_styleData["$context_name/$this->_endName"]; } ! $this->_styleData["$context_name/$this->_endName"] = $this->getStyle($context_name); ! return $this->_styleData["$context_name/$this->_endName"]; ! }*/ ! /* function startIsUnique ($context_name) { ! return (isset($this->_styleData["$context_name/$this->_startName"]) ! && '' != $this->_styleData["$context_name/$this->_startName"] ! && $this->_styleData["$context_name/$this->_startName"] != $this->_styleData[$context_name]); } function endIsUnique ($context_name) { ! $r = (isset($this->_styleData["$context_name/$this->_endName"]) ! && '' != $this->_styleData["$context_name/$this->_endName"] ! && $this->_styleData["$context_name/$this->_endName"] != $this->_styleData[$context_name]); geshi_dbg('GeSHiStyler::endIsUnique(' . $context_name . ') = ' . $r, GESHI_DBG_PARSE); return $r; } ! */ function resetParseData () { *************** *** 163,174 **** } ! function addParseDataStart ($code, $context_name) { ! $this->addParseData($code, $context_name . '/start'); } ! function addParseDataEnd ($code, $context_name) { ! $this->addParseData($code, $context_name . '/end'); } --- 185,196 ---- } ! function addParseDataStart ($code, $context_name, $start_name = 'start') { ! $this->addParseData($code, "$context_name/$start_name"); } ! function addParseDataEnd ($code, $context_name, $end_name = 'end') { ! $this->addParseData($code, "$context_name/$end_name"); } |
From: Nigel M. <ora...@us...> - 2005-09-15 01:17:16
|
Update of /cvsroot/geshi/geshi-src/geshi/classes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23912/geshi/classes Modified Files: class.geshicontext.php Log Message: Implemented aliasing: one context can call itself by another's name. Index: class.geshicontext.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/classes/class.geshicontext.php,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** class.geshicontext.php 24 Aug 2005 12:56:05 -0000 1.15 --- class.geshicontext.php 15 Sep 2005 01:17:08 -0000 1.16 *************** *** 122,125 **** --- 122,137 ---- */ var $_loaded = false; + + /** + * The name for stuff detected in the start of a context + * @var string + */ + var $_startName = 'start'; + + /** + * The name for stuff detected in the end of a context + * @var string + */ + var $_endName = 'end'; /**#@-*/ *************** *** 131,137 **** * @param string The dialect of the language this context represents * @param string The name of the context * @todo [blocking 1.1.9] Better comment */ ! function GeSHiContext ($language_name, $dialect_name = '', $context_name = '') { // Set dialect --- 143,150 ---- * @param string The dialect of the language this context represents * @param string The name of the context + * @param array The name used for aliasing * @todo [blocking 1.1.9] Better comment */ ! function GeSHiContext ($language_name, $dialect_name = '', $context_name = '', $alias_name = '') { // Set dialect *************** *** 154,158 **** $this->_fileName = $language_name . '/' . $context_name; } ! $this->_contextName = "$language_name/$dialect_name/$context_name"; } --- 167,175 ---- $this->_fileName = $language_name . '/' . $context_name; } ! if ($alias_name) { ! $this->_contextName = $alias_name; ! } else { ! $this->_contextName = "$language_name/$dialect_name/$context_name"; ! } } *************** *** 167,170 **** --- 184,197 ---- } + function getStartName () + { + return $this->_startName; + } + + function getEndName () + { + return $this->_endName; + } + /** * Loads the context data *************** *** 190,193 **** --- 217,222 ---- // Load the data for this context $CONTEXT = $this->_contextName; + $CONTEXT_START = "$this->_contextName/$this->_startName"; + $CONTEXT_END = "$this->_contextName/$this->_endName"; $DIALECT = $this->_dialectName; // @todo [blocking 1.1.5] This needs testing to see if it is faster *************** *** 290,294 **** //geshi_dbg('@buseless, removed', GESHI_DBG_PARSE); // RAM saving technique ! $this->_styler->removeStyleData($this->_childContexts[$key]->getName()); unset($this->_childContexts[$key]); } --- 319,325 ---- //geshi_dbg('@buseless, removed', GESHI_DBG_PARSE); // RAM saving technique ! $this->_styler->removeStyleData($this->_childContexts[$key]->getName(), ! $this->_childContexts[$key]->getStartName(), ! $this->_childContexts[$key]->getEndName()); unset($this->_childContexts[$key]); } *************** *** 644,648 **** function _addParseDataStart ($code) { ! $this->_styler->addParseDataStart($code, $this->_contextName); } --- 675,679 ---- function _addParseDataStart ($code) { ! $this->_styler->addParseDataStart($code, $this->_contextName, $this->_startName); } *************** *** 652,656 **** function _addParseDataEnd ($code) { ! $this->_styler->addParseDataEnd($code, $this->_contextName); } --- 683,687 ---- function _addParseDataEnd ($code) { ! $this->_styler->addParseDataEnd($code, $this->_contextName, $this->_endName); } |
From: Nigel M. <ora...@us...> - 2005-09-15 01:15:38
|
Update of /cvsroot/geshi/geshi-src/geshi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23603/geshi Modified Files: functions.geshi.php Log Message: Allow numbers at very end of a context. Index: functions.geshi.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/functions.geshi.php,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** functions.geshi.php 13 Sep 2005 08:00:41 -0000 1.15 --- functions.geshi.php 15 Sep 2005 01:15:27 -0000 1.16 *************** *** 178,182 **** return array( 0 => array( ! '#([^a-zA-Z_0-9])([-]?[0-9]+)([^a-zA-Z_0-9])#' ), 1 => '', --- 178,183 ---- return array( 0 => array( ! // @todo add start-of-input marker to banned chars before??? ! '#([^a-zA-Z_0-9])([-]?[0-9]+)([^a-zA-Z_0-9]|$)#' ), 1 => '', |
From: Nigel M. <ora...@us...> - 2005-09-14 11:59:31
|
Update of /cvsroot/geshi/geshi-src/geshi/classes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26302/geshi/classes Modified Files: class.geshicodecontext.php Log Message: Allow keywords immediately after regex match. Index: class.geshicodecontext.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/classes/class.geshicodecontext.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** class.geshicodecontext.php 13 Sep 2005 08:04:18 -0000 1.13 --- class.geshicodecontext.php 14 Sep 2005 11:59:22 -0000 1.14 *************** *** 342,345 **** --- 342,347 ---- $result[++$result_pointer] = $replacement; } + // Allow keyword matching immediately after regular expressions + $keyword_match_allowed = true; } *************** *** 435,440 **** /// The second test on the first line is a little contentious - allows functions that don't /// start with an alpha character to be within other words, e.g abc<?php, where <?php is a kw ! $last_char_is_alpha = ctype_alpha(substr($code, $i, 1)); ! $keyword_match_allowed = (!$last_char_is_alpha || ($last_char_is_alpha && !ctype_alpha($char))); $keyword_match_allowed = ($keyword_match_allowed && !in_array(substr($code, $i, 1), $this->_contextCharactersDisallowedBeforeKeywords)); --- 437,442 ---- /// The second test on the first line is a little contentious - allows functions that don't /// start with an alpha character to be within other words, e.g abc<?php, where <?php is a kw ! $last_char_is_alpha = ctype_alnum(substr($code, $i, 1)); ! $keyword_match_allowed = (!$last_char_is_alpha || ($last_char_is_alpha && !ctype_alnum($char))); $keyword_match_allowed = ($keyword_match_allowed && !in_array(substr($code, $i, 1), $this->_contextCharactersDisallowedBeforeKeywords)); |
From: BenBE <be...@us...> - 2005-09-14 10:31:32
|
Update of /cvsroot/geshi/geshi-src/geshi/contexts/delphi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8774/geshi-src/geshi/contexts/delphi Modified Files: delphi.php Added Files: extern.php property.php Log Message: add: Subcontexts for properties and exports\external clauses fix: some fixes for invalid highlightings --- NEW FILE: property.php --- <?php /** * GeSHi - Generic Syntax Highlighter * * For information on how to use GeSHi, please consult the documentation * found in the docs/ directory, or online at http://geshi.org/docs/ * * This file is part of GeSHi. * * GeSHi is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * GeSHi is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with GeSHi; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA * * You can view a copy of the GNU GPL in the COPYING file that comes * with GeSHi, in the docs/ directory. * * @package lang * @author Nigel McNie <ni...@ge...> * @license http://www.gnu.org/copyleft/gpl.html GNU GPL * @copyright (C) 2005 Nigel McNie * @version $Id: property.php,v 1.1 2005/09/14 10:31:11 benbe Exp $ * */ $this->_contextDelimiters = array( 0 => array( 0 => array('property'), 1 => array(';'), 2 => false ) ); $this->_childContexts = array( new GeSHiContext('delphi', $CONTEXT, 'preprocessor'), new GeSHiContext('delphi', $CONTEXT, 'multi_comment') ); $this->_styler->setStyle($CONTEXT, 'color:#000;'); $this->_styler->setStartStyle($CONTEXT, 'color:#f00;font-weight:bold;'); $this->_styler->setEndStyle($CONTEXT, 'color:#00f;'); $this->_contextKeywords = array( 0 => array( 0 => array( 'read','write','index','stored','default','nodefault','implements', 'dispid','readonly','writeonly' ), 1 => $CONTEXT . '/keywords', 2 => 'color:#f00; font-weight:bold;', 3 => false, 4 => '' ) ); $this->_contextSymbols = array( 0 => array( 0 => array( ',', '[', ']', '.' ), 1 => $CONTEXT . '/sym', 2 => 'color:#008000;' ) ); $this->_contextRegexps = array( 0 => array( 0 => array( '/(#[0-9]+)/' ), 1 => '#', 2 => array( 1 => array($CONTEXT . '/char', 'color:#db9;', false) ) ), 1 => array( 0 => array( '/(#\$[0-9a-fA-F]+)/' ), 1 => '#', 2 => array( 1 => array($CONTEXT . '/charhex', 'color:#db9;', false) ) ), 2 => array( 0 => array( '/(\$[0-9a-fA-F]+)/' ), 1 => '$', 2 => array( 1 => array($CONTEXT . '/hex', 'color: #2bf;', false) ) ), 3 => geshi_use_integers($CONTEXT) ); $this->_objectSplitters = array( 0 => array( 0 => array('.'), 1 => $CONTEXT . '/oodynamic', 2 => 'color:#559;', 3 => false // If true, check that matched method isn't a keyword first ) ); ?> Index: delphi.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/contexts/delphi/delphi.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** delphi.php 12 Sep 2005 00:41:19 -0000 1.5 --- delphi.php 14 Sep 2005 10:31:11 -0000 1.6 *************** *** 30,34 **** * @copyright (C) 2005 Nigel McNie * @version $Id$ ! * */ --- 30,34 ---- * @copyright (C) 2005 Nigel McNie * @version $Id$ ! * */ *************** *** 39,43 **** new GeSHiContext('delphi', $DIALECT, 'common/single_string_eol'), new GeSHiContext('delphi', $DIALECT, 'preprocessor'), ! new GeSHiCodeContext('delphi', $DIALECT, 'asm') ); --- 39,45 ---- new GeSHiContext('delphi', $DIALECT, 'common/single_string_eol'), new GeSHiContext('delphi', $DIALECT, 'preprocessor'), ! new GeSHiCodeContext('delphi', $DIALECT, 'asm'), ! new GeSHiCodeContext('delphi', $DIALECT, 'extern'), ! new GeSHiCodeContext('delphi', $DIALECT, 'property') ); *************** *** 53,57 **** 'As', 'Asm', - 'Assembler', 'At', 'Begin', --- 55,58 ---- *************** *** 62,65 **** --- 63,67 ---- 'Contains', 'Destructor', + 'DispInterface', 'Div', 'Do', *************** *** 81,86 **** 'Interface', 'Is', 'Mod', - 'Nil', 'Not', 'Object', --- 83,88 ---- 'Interface', 'Is', + 'Label', 'Mod', 'Not', 'Object', *************** *** 117,121 **** 'Virtual', 'Abstract', 'Override', 'Overload', ! 'cdecl', 'stdcall', 'register', 'pascal', 'safecall', 'near', 'far' ), 1 => $CONTEXT . '/keywords', --- 119,125 ---- 'Virtual', 'Abstract', 'Override', 'Overload', ! 'cdecl', 'stdcall', 'register', 'pascal', 'safecall', 'near', 'far', 'varargs', ! ! 'assembler' ), 1 => $CONTEXT . '/keywords', *************** *** 150,154 **** 3 => false, 4 => '' ! ) ); --- 154,292 ---- 3 => false, 4 => '' ! ), ! ! 2 => array( ! 0 => array( ! //@todo get keywords normal way ! 'nil', ! 'false', 'true' ! ), ! 1 => $CONTEXT . '/keyidents', ! 2 => 'color:#000; font-weight:bold;', ! 3 => false, ! 4 => '' ! ), ! ! //Standard functions of Unit System ! 3 => array( ! 0 => array( ! //@todo get keywords normal way ! 'Abs','AcquireExceptionObject','Addr','AnsiToUtf8','Append','ArcTan','Assert','Assigned','AssignFile', ! 'BeginThread','BlockRead','BlockWrite','Break','ChDir','Chr','Close','CloseFile','CompToCurrency', ! 'CompToDouble','Concat','Continue','Copy','Cos','Dec','Delete','Dispose','DoubleToComp','EndThread', ! 'EnumModules','EnumResourceModules','Eof','Eoln','Erase','ExceptAddr','ExceptObject','Exclude','Exit', ! 'Exp','FilePos','FileSize','FillChar','Finalize','FindClassHInstance','FindHInstance','FindResourceHInstance', ! 'Flush','Frac','FreeMem','Get8087CW','GetDir','GetLastError','GetMem','GetMemoryManager', ! 'GetModuleFileName','GetVariantManager','Halt','Hi','High','Inc','Include','Initialize','Insert', ! 'Int','IOResult','IsMemoryManagerSet','IsVariantManagerSet','Length','Ln','Lo','Low','MkDir','Move', ! 'New','Odd','OleStrToString','OleStrToStrVar','Ord','ParamCount','ParamStr','Pi','Pos','Pred','Ptr', ! 'PUCS4Chars','Random','Randomize','Read','ReadLn','ReallocMem','ReleaseExceptionObject','Rename', ! 'Reset','Rewrite','RmDir','Round','RunError','Seek','SeekEof','SeekEoln','Set8087CW','SetLength', ! 'SetLineBreakStyle','SetMemoryManager','SetString','SetTextBuf','SetVariantManager','Sin','SizeOf', ! 'Slice','Sqr','Sqrt','Str','StringOfChar','StringToOleStr','StringToWideChar','Succ','Swap','Trunc', ! 'Truncate','TypeInfo','UCS4StringToWideString','UnicodeToUtf8','UniqueString','UpCase','UTF8Decode', ! 'UTF8Encode','Utf8ToAnsi','Utf8ToUnicode','Val','VarArrayRedim','VarClear','WideCharLenToString', ! 'WideCharLenToStrVar','WideCharToString','WideCharToStrVar','WideStringToUCS4String','Write','WriteLn' ! ), ! 1 => $CONTEXT . '/stdprocs/system', ! 2 => 'color:#444;', ! 3 => false, ! 4 => '' ! ), ! ! //Standard functions of Unit SysUtils ! 4 => array( ! 0 => array( ! //@todo get keywords normal way ! 'Abort','AddExitProc','AddTerminateProc','AdjustLineBreaks','AllocMem','AnsiCompareFileName', ! 'AnsiCompareStr','AnsiCompareText','AnsiDequotedStr','AnsiExtractQuotedStr','AnsiLastChar', ! 'AnsiLowerCase','AnsiLowerCaseFileName','AnsiPos','AnsiQuotedStr','AnsiSameStr','AnsiSameText', ! 'AnsiStrComp','AnsiStrIComp','AnsiStrLastChar','AnsiStrLComp','AnsiStrLIComp','AnsiStrLower', ! 'AnsiStrPos','AnsiStrRScan','AnsiStrScan','AnsiStrUpper','AnsiUpperCase','AnsiUpperCaseFileName', ! 'AppendStr','AssignStr','Beep','BoolToStr','ByteToCharIndex','ByteToCharLen','ByteType', ! 'CallTerminateProcs','ChangeFileExt','CharLength','CharToByteIndex','CharToByteLen','CompareMem', ! 'CompareStr','CompareText','CreateDir','CreateGUID','CurrentYear','CurrToStr','CurrToStrF','Date', ! 'DateTimeToFileDate','DateTimeToStr','DateTimeToString','DateTimeToSystemTime','DateTimeToTimeStamp', ! 'DateToStr','DayOfWeek','DecodeDate','DecodeDateFully','DecodeTime','DeleteFile','DirectoryExists', ! 'DiskFree','DiskSize','DisposeStr','EncodeDate','EncodeTime','ExceptionErrorMessage', ! 'ExcludeTrailingBackslash','ExcludeTrailingPathDelimiter','ExpandFileName','ExpandFileNameCase', ! 'ExpandUNCFileName','ExtractFileDir','ExtractFileDrive','ExtractFileExt','ExtractFileName', ! 'ExtractFilePath','ExtractRelativePath','ExtractShortPathName','FileAge','FileClose','FileCreate', ! 'FileDateToDateTime','FileExists','FileGetAttr','FileGetDate','FileIsReadOnly','FileOpen','FileRead', ! 'FileSearch','FileSeek','FileSetAttr','FileSetDate','FileSetReadOnly','FileWrite','FinalizePackage', ! 'FindClose','FindCmdLineSwitch','FindFirst','FindNext','FloatToCurr','FloatToDateTime', ! 'FloatToDecimal','FloatToStr','FloatToStrF','FloatToText','FloatToTextFmt','FmtLoadStr','FmtStr', ! 'ForceDirectories','Format','FormatBuf','FormatCurr','FormatDateTime','FormatFloat','FreeAndNil', ! 'GetCurrentDir','GetEnvironmentVariable','GetFileVersion','GetFormatSettings', ! 'GetLocaleFormatSettings','GetModuleName','GetPackageDescription','GetPackageInfo','GUIDToString', ! 'IncAMonth','IncludeTrailingBackslash','IncludeTrailingPathDelimiter','IncMonth','InitializePackage', ! 'InterlockedDecrement','InterlockedExchange','InterlockedExchangeAdd','InterlockedIncrement', ! 'IntToHex','IntToStr','IsDelimiter','IsEqualGUID','IsLeapYear','IsPathDelimiter','IsValidIdent', ! 'Languages','LastDelimiter','LoadPackage','LoadStr','LowerCase','MSecsToTimeStamp','NewStr', ! 'NextCharIndex','Now','OutOfMemoryError','QuotedStr','RaiseLastOSError','RaiseLastWin32Error', ! 'RemoveDir','RenameFile','ReplaceDate','ReplaceTime','SafeLoadLibrary','SameFileName','SameText', ! 'SetCurrentDir','ShowException','Sleep','StrAlloc','StrBufSize','StrByteType','StrCat', ! 'StrCharLength','StrComp','StrCopy','StrDispose','StrECopy','StrEnd','StrFmt','StrIComp', ! 'StringReplace','StringToGUID','StrLCat','StrLComp','StrLCopy','StrLen','StrLFmt','StrLIComp', ! 'StrLower','StrMove','StrNew','StrNextChar','StrPas','StrPCopy','StrPLCopy','StrPos','StrRScan', ! 'StrScan','StrToBool','StrToBoolDef','StrToCurr','StrToCurrDef','StrToDate','StrToDateDef', ! 'StrToDateTime','StrToDateTimeDef','StrToFloat','StrToFloatDef','StrToInt','StrToInt64', ! 'StrToInt64Def','StrToIntDef','StrToTime','StrToTimeDef','StrUpper','Supports','SysErrorMessage', ! 'SystemTimeToDateTime','TextToFloat','Time','GetTime','TimeStampToDateTime','TimeStampToMSecs', ! 'TimeToStr','Trim','TrimLeft','TrimRight','TryEncodeDate','TryEncodeTime','TryFloatToCurr', ! 'TryFloatToDateTime','TryStrToBool','TryStrToCurr','TryStrToDate','TryStrToDateTime','TryStrToFloat', ! 'TryStrToInt','TryStrToInt64','TryStrToTime','UnloadPackage','UpperCase','WideCompareStr', ! 'WideCompareText','WideFmtStr','WideFormat','WideFormatBuf','WideLowerCase','WideSameStr', ! 'WideSameText','WideUpperCase','Win32Check','WrapText' ! ), ! 1 => $CONTEXT . '/stdprocs/sysutils', ! 2 => 'color:#444;', ! 3 => false, ! 4 => '' ! ), ! ! //Standard functions of Unit Classes ! 5 => array( ! 0 => array( ! //@todo get keywords normal way ! 'ActivateClassGroup','AllocateHwnd','BinToHex','CheckSynchronize','CollectionsEqual','CountGenerations', ! 'DeallocateHwnd','EqualRect','ExtractStrings','FindClass','FindGlobalComponent','GetClass', ! 'GroupDescendantsWith','HexToBin','IdentToInt','InitInheritedComponent','IntToIdent','InvalidPoint', ! 'IsUniqueGlobalComponentName','LineStart','ObjectBinaryToText','ObjectResourceToText', ! 'ObjectTextToBinary','ObjectTextToResource','PointsEqual','ReadComponentRes','ReadComponentResEx', ! 'ReadComponentResFile','Rect','RegisterClass','RegisterClassAlias','RegisterClasses', ! 'RegisterComponents','RegisterIntegerConsts','RegisterNoIcon','RegisterNonActiveX','SmallPoint', ! 'StartClassGroup','TestStreamFormat','UnregisterClass','UnregisterClasses','UnregisterIntegerConsts', ! 'UnregisterModuleClasses','WriteComponentResFile' ! ), ! 1 => $CONTEXT . '/stdprocs/classes', ! 2 => 'color:#444;', ! 3 => false, ! 4 => '' ! ), ! ! //Standard functions of Unit Math ! 6 => array( ! 0 => array( ! //@todo get keywords normal way ! 'ArcCos', 'ArcCosh', 'ArcCot', 'ArcCotH', 'ArcCsc', 'ArcCscH', 'ArcSec', 'ArcSecH', 'ArcSin', ! 'ArcSinh', 'ArcTan2', 'ArcTanh', 'Ceil', 'CompareValue', 'Cosecant', 'Cosh', 'Cot', 'Cotan', ! 'CotH', 'Csc', 'CscH', 'CycleToDeg', 'CycleToGrad', 'CycleToRad', 'DegToCycle', 'DegToGrad', ! 'DegToRad', 'DivMod', 'DoubleDecliningBalance', 'EnsureRange', 'Floor', 'Frexp', 'FutureValue', ! 'GetExceptionMask', 'GetPrecisionMode', 'GetRoundMode', 'GradToCycle', 'GradToDeg', 'GradToRad', ! 'Hypot', 'InRange', 'InterestPayment', 'InterestRate', 'InternalRateOfReturn', 'IntPower', ! 'IsInfinite', 'IsNan', 'IsZero', 'Ldexp', 'LnXP1', 'Log10', 'Log2', 'LogN', 'Max', 'MaxIntValue', ! 'MaxValue', 'Mean', 'MeanAndStdDev', 'Min', 'MinIntValue', 'MinValue', 'MomentSkewKurtosis', ! 'NetPresentValue', 'Norm', 'NumberOfPeriods', 'Payment', 'PeriodPayment', 'Poly', 'PopnStdDev', ! 'PopnVariance', 'Power', 'PresentValue', 'RadToCycle', 'RadToDeg', 'RadToGrad', 'RandG', 'RandomRange', ! 'RoundTo', 'SameValue', 'Sec', 'Secant', 'SecH', 'SetExceptionMask', 'SetPrecisionMode', 'SetRoundMode', ! 'Sign', 'SimpleRoundTo', 'SinCos', 'Sinh', 'SLNDepreciation', 'StdDev', 'Sum', 'SumInt', 'SumOfSquares', ! 'SumsAndSquares', 'SYDDepreciation', 'Tan', 'Tanh', 'TotalVariance', 'Variance' ! ), ! 1 => $CONTEXT . '/stdprocs/math', ! 2 => 'color:#444;', ! 3 => false, ! 4 => '' ! ), ); *************** *** 214,218 **** 2 => array( 0 => array( ! '/(\$[0-9a-fA-F_]+)/' ), 1 => '$', --- 352,356 ---- 2 => array( 0 => array( ! '/(\$[0-9a-fA-F]+)/' ), 1 => '$', *************** *** 234,236 **** ); ! ?> --- 372,374 ---- ); ! ?> \ No newline at end of file --- NEW FILE: extern.php --- <?php /** * GeSHi - Generic Syntax Highlighter * * For information on how to use GeSHi, please consult the documentation * found in the docs/ directory, or online at http://geshi.org/docs/ * * This file is part of GeSHi. * * GeSHi is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * GeSHi is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with GeSHi; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA * * You can view a copy of the GNU GPL in the COPYING file that comes * with GeSHi, in the docs/ directory. * * @package lang * @author Nigel McNie <ni...@ge...> * @license http://www.gnu.org/copyleft/gpl.html GNU GPL * @copyright (C) 2005 Nigel McNie * @version $Id: extern.php,v 1.1 2005/09/14 10:31:11 benbe Exp $ * */ $this->_contextDelimiters = array( 0 => array( 0 => array('exports'), 1 => array(';'), 2 => false ), 1 => array( 0 => array('external'), 1 => array(';'), 2 => false ) ); $this->_childContexts = array( new GeSHiContext('delphi', $CONTEXT, 'preprocessor'), new GeSHiContext('delphi', $CONTEXT, 'multi_comment'), new GeSHiContext('delphi', $DIALECT, 'common/single_string_eol') ); $this->_styler->setStyle($CONTEXT, 'color:#000;'); $this->_styler->setStartStyle($CONTEXT, 'color:#f00;font-weight:bold;'); $this->_styler->setEndStyle($CONTEXT, 'color:#00f;'); $this->_contextKeywords = array( 0 => array( 0 => array( 'name','index','resident' ), 1 => $CONTEXT . '/keywords', 2 => 'color:#f00; font-weight:bold;', 3 => false, 4 => '' ), ); $this->_contextSymbols = array( 0 => array( 0 => array( ',', '[', ']', '.' ), 1 => $CONTEXT . '/sym', 2 => 'color:#008000;' ), 1 => array( 0 => array( '(', ')', '[', ']' ), 1 => $CONTEXT . '/brksym', 2 => 'color:#008000;' ) ); $this->_contextRegexps = array( 0 => array( 0 => array( '/(#[0-9]+)/' ), 1 => '#', 2 => array( 1 => array($CONTEXT . '/char', 'color:#db9;', false) ) ), 1 => array( 0 => array( '/(#\$[0-9a-fA-F]+)/' ), 1 => '#', 2 => array( 1 => array($CONTEXT . '/charhex', 'color:#db9;', false) ) ), 2 => array( 0 => array( '/(\$[0-9a-fA-F]+)/' ), 1 => '$', 2 => array( 1 => array($CONTEXT . '/hex', 'color: #2bf;', false) ) ), 3 => geshi_use_integers($CONTEXT) ); $this->_objectSplitters = array( 0 => array( 0 => array('.'), 1 => $CONTEXT . '/oodynamic', 2 => 'color:#559;', 3 => false // If true, check that matched method isn't a keyword first ) ); ?> |
From: Nigel M. <ora...@us...> - 2005-09-13 08:04:27
|
Update of /cvsroot/geshi/geshi-src/geshi/classes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12938/geshi/classes Modified Files: class.geshicodecontext.php Log Message: Prevent warning in eclipse about undefined variable. Keywords are now allowed only after a non-alphanumeric character, previously they were allowed only after a non-alpha character. Prevents "42var" being highlighted in delphi for example. Index: class.geshicodecontext.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/classes/class.geshicodecontext.php,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** class.geshicodecontext.php 25 Jul 2005 07:03:11 -0000 1.12 --- class.geshicodecontext.php 13 Sep 2005 08:04:18 -0000 1.13 *************** *** 212,215 **** --- 212,216 ---- foreach ($regex_data[0] as $regex) { geshi_dbg(' Trying regex ' . $regex . '... ', GESHI_DBG_PARSE, false); + $matches = array(); preg_match_all($regex, $code, $matches); geshi_dbg('found ' . count($matches[0]) . ' matches', GESHI_DBG_PARSE); *************** *** 374,377 **** --- 375,379 ---- } + geshi_dbg(" next part is keyword: $next_part_is_keyword", GESHI_DBG_PARSE); // OPTIMIZE (use lookup to remember for length $foo(1 => false, 2 => false) so if kw is length 1 or 2 then don't need to check //$after_allowed = ( !in_array(substr($code, $i + strlen($keyword_array[0]), 1), array_diff($this->_context_characters_disallowed_after_keywords, $this->_context_keywords[$keyword_array[1]][4])) ); *************** *** 383,389 **** geshi_dbg(" after char to check: |$after_char|", GESHI_DBG_PARSE); ! $after_allowed = (!ctype_alpha(substr($code, $i + strlen($keyword_array[0]), 1)) || ! (ctype_alpha(substr($code, $i + strlen($keyword_array[0]), 1)) && ! !ctype_alpha($char)) ); $after_allowed = ($after_allowed && !in_array($after_char, $this->_contextCharactersDisallowedAfterKeywords)); --- 385,391 ---- geshi_dbg(" after char to check: |$after_char|", GESHI_DBG_PARSE); ! $after_allowed = ('' == $after_char || !ctype_alnum($after_char) || ! (ctype_alnum($after_char) && ! !ctype_alnum($char)) ); $after_allowed = ($after_allowed && !in_array($after_char, $this->_contextCharactersDisallowedAfterKeywords)); |
From: Nigel M. <ora...@us...> - 2005-09-13 08:00:53
|
Update of /cvsroot/geshi/geshi-src/geshi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12074/geshi Modified Files: functions.geshi.php Log Message: Added a new debug function that can turn debug statements on/off for parts of the code. Improved the integer number regular expression again: banning certain characters from the end. Index: functions.geshi.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/functions.geshi.php,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** functions.geshi.php 9 Sep 2005 04:14:41 -0000 1.14 --- functions.geshi.php 13 Sep 2005 08:00:41 -0000 1.15 *************** *** 33,36 **** --- 33,41 ---- */ + $GLOBALS['geshi_dbg_level'] = 0; + function geshi_dbg_level ($level) { + $GLOBALS['geshi_dbg_level'] = $level; + } + /** * Handles debugging by printing a message according to current debug level, *************** *** 45,49 **** function geshi_dbg ($message, $context, $add_nl = true, $return_counts = false) { ! if (GESHI_DBG & $context) { // // Message can have the following symbols at start --- 50,54 ---- function geshi_dbg ($message, $context, $add_nl = true, $return_counts = false) { ! if ((GESHI_DBG & $context) || ($GLOBALS['geshi_dbg_level'] & $context)) { // // Message can have the following symbols at start *************** *** 168,172 **** * @param string The prefix to use for the name of this number match * @return array - * @todo [blocking 1.1.0] Handle Int64 example (4 is highlighted...) */ function geshi_use_integers ($prefix) --- 173,176 ---- *************** *** 174,178 **** return array( 0 => array( ! '#([^a-zA-Z_0-9])([-]?[0-9]+)#' ), 1 => '', --- 178,182 ---- return array( 0 => array( ! '#([^a-zA-Z_0-9])([-]?[0-9]+)([^a-zA-Z_0-9])#' ), 1 => '', *************** *** 183,187 **** 1 => 'color:#11e;', 2 => false ! ) ) ); --- 187,192 ---- 1 => 'color:#11e;', 2 => false ! ), ! 3 => true ) ); |
From: Nigel M. <ora...@us...> - 2005-09-12 00:41:28
|
Update of /cvsroot/geshi/geshi-src/geshi/contexts/delphi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24257/geshi/contexts/delphi Modified Files: asm.php delphi.php Log Message: Added newlines back on the end of the files. To Ben: please leave a newline at the end of files, after the ?> marker. Index: asm.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/contexts/delphi/asm.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** asm.php 11 Sep 2005 12:09:26 -0000 1.3 --- asm.php 12 Sep 2005 00:41:19 -0000 1.4 *************** *** 269,271 **** ); ! ?> \ No newline at end of file --- 269,271 ---- ); ! ?> Index: delphi.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/contexts/delphi/delphi.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** delphi.php 11 Sep 2005 12:11:52 -0000 1.4 --- delphi.php 12 Sep 2005 00:41:19 -0000 1.5 *************** *** 234,236 **** ); ! ?> \ No newline at end of file --- 234,236 ---- ); ! ?> |
From: Nigel M. <ora...@us...> - 2005-09-12 00:39:52
|
Update of /cvsroot/geshi/geshi-src/geshi/classes/php In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23986/geshi/classes/php Modified Files: class.geshiphpdoublestringcontext.php Log Message: Fixed the \\$ bug (hopefully!). Restored highilghting of object variables in double strings. Improved variable highlighting in general, especially with regards to brace-surrounded variables. Index: class.geshiphpdoublestringcontext.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/classes/php/class.geshiphpdoublestringcontext.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** class.geshiphpdoublestringcontext.php 9 Jun 2005 13:27:17 -0000 1.6 --- class.geshiphpdoublestringcontext.php 12 Sep 2005 00:39:40 -0000 1.7 *************** *** 61,66 **** */ var $_regexes = array( ! 'REGEX#(\{?\$\$?[a-zA-Z_][a-zA-Z0-9_\'\[\]]*\}?)#', ! 'REGEX#(\{?)(\$this)(\s*->\s*)([a-zA-Z_][a-zA-Z0-9_]*)(\}?)#' ); --- 61,67 ---- */ var $_regexes = array( ! 'REGEX#(\{?\$\$?[a-zA-Z_][a-zA-Z0-9_]*\}?)#', ! 'REGEX#(\{?\$\$?[a-zA-Z_][a-zA-Z0-9_]*\[[\$a-zA-Z0-9_\s\[\]\']*\]\}?)#', ! 'REGEX#(\{?)(\$\$?[a-zA-Z_][a-zA-Z0-9_]*)(\s*->\s*)([a-zA-Z_][a-zA-Z0-9_]*)(\}?)#' ); *************** *** 81,90 **** function _addParseData ($code, $first_char_of_next_context = '') { ! geshi_dbg('GeSHiPHPDoubleStringContext::_addParseData(' . substr($code, 0, 15) . ')', GESHI_DBG_PARSE); while (true) { $earliest_data = array('pos' => false, 'len' => 0); foreach ($this->_regexes as $regex) { ! $data = geshi_get_position($code, $regex, 0); if ((false != $data['pos'] && false === $earliest_data['pos']) || (false !== $data['pos']) && --- 82,91 ---- function _addParseData ($code, $first_char_of_next_context = '') { ! geshi_dbg('GeSHiPHPDoubleStringContext::_addParseData(' . substr($code, 0, 15) . '...)', GESHI_DBG_PARSE); while (true) { $earliest_data = array('pos' => false, 'len' => 0); foreach ($this->_regexes as $regex) { ! $data = geshi_get_position($code, $regex, 0, false, true); // request table if ((false != $data['pos'] && false === $earliest_data['pos']) || (false !== $data['pos']) && *************** *** 100,121 **** } ! parent::_addParseData(substr($code, 0, $earliest_data['pos'])); // Now the entire possible var is in: ! $possible_var = substr($code, $earliest_data['pos'], $earliest_data['len']); geshi_dbg('Found variable at position ' . $earliest_data['pos'] . '(' . $possible_var . ')', GESHI_DBG_PARSE); // Check that the dollar sign that started this variable was not escaped ! $first_part = str_replace('\\\\', '', substr($code, 0, $earliest_data['pos'])); ! if ('\\' == substr($first_part, -1)) { // This variable has been escaped, so add the escaped dollar sign // as the correct context, and the rest of the variable (recurse to catch // other variables inside this possible variable) geshi_dbg('Variable was escaped', GESHI_DBG_PARSE); ! $this->_styler->addParseData('\\$', $this->_parentName . '/esc'); ! $this->_addParseData(substr($possible_var, 1)); } else { // Many checks could go in here... ! if (isset($earliest_data['tab'][5])) { $start_brace = '{'; } else { --- 101,135 ---- } ! // bugfix: because we match a var, it might have been escaped. ! // so only do to -1 so we can catch slash if it has been ! $pos = ($earliest_data['pos']) ? $earliest_data['pos'] - 1 : 0; ! $len = ($earliest_data['pos']) ? $earliest_data['len'] + 1 : $earliest_data['len']; ! parent::_addParseData(substr($code, 0, $pos)); // Now the entire possible var is in: ! $possible_var = substr($code, $pos, $len); geshi_dbg('Found variable at position ' . $earliest_data['pos'] . '(' . $possible_var . ')', GESHI_DBG_PARSE); // Check that the dollar sign that started this variable was not escaped ! //$first_part = str_replace('\\\\', '', substr($code, 0, $pos)); ! //if ('\\' == substr($first_part, -1)) { ! // If \\ before var and { is not next character after that... ! if ('\\' == substr($possible_var, 0, 1) && '{' != substr($possible_var, 1, 1)) { // This variable has been escaped, so add the escaped dollar sign // as the correct context, and the rest of the variable (recurse to catch // other variables inside this possible variable) geshi_dbg('Variable was escaped', GESHI_DBG_PARSE); ! $this->_styler->addParseData(substr($possible_var, 0, 2), $this->_parentName . '/esc'); ! $this->_addParseData(substr($possible_var, 2)); } else { + // Add first character that might have been a \\ but in fact isn't to the parent + // but only do it if we had to modify the position + if ('$' != substr($possible_var, 0, 1)) { + parent::_addParseData(substr($possible_var, 0, 1)); + $possible_var = substr($possible_var, 1); + } + // Many checks could go in here... ! /*if (isset($earliest_data['tab'][5])) { $start_brace = '{'; } else { *************** *** 129,134 **** $start_brace = ''; } } ! if (isset($earliest_data['tab'][5])) { // Then we matched off the second regex - the one that does objects --- 143,162 ---- $start_brace = ''; } + }*/ + + if ('{' == substr($possible_var, 0, 1)) { + if ('}' == substr($possible_var, -1)) { + $start_brace = '{'; + } else { + $start_brace = ''; + parent::_addParseData('{'); + // remove brace from $possible_var. This will only be used + // if the variable isn't an OO variable anyway... + $possible_var = substr($possible_var, 1); + } + } else { + $start_brace = ''; } ! if (isset($earliest_data['tab'][5])) { // Then we matched off the second regex - the one that does objects *************** *** 141,145 **** // The closing }, if any if ($earliest_data['tab'][5]) { ! $this->_styler->addParseData($earliest_data['tab'][5], $this->_parentName . '/var'); } } else { --- 169,177 ---- // The closing }, if any if ($earliest_data['tab'][5]) { ! if ($start_brace) { ! $this->_styler->addParseData($earliest_data['tab'][5], $this->_parentName . '/var'); ! } else { ! parent::_addParseData('}'); ! } } } else { |
From: Nigel M. <ora...@us...> - 2005-09-12 00:36:26
|
Update of /cvsroot/geshi/geshi-src/geshi/classes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23332/geshi/classes Modified Files: class.geshistringcontext.php Log Message: Minor debug output improvement when debugging the \\$ bug. Index: class.geshistringcontext.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/classes/class.geshistringcontext.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** class.geshistringcontext.php 25 Jul 2005 07:03:11 -0000 1.6 --- class.geshistringcontext.php 12 Sep 2005 00:36:09 -0000 1.7 *************** *** 109,113 **** function _addParseData ($code, $first_char_of_next_context = '') { ! geshi_dbg('GeSHiStringContext::_addParseData(' . substr($code, 0, 15) . ')', GESHI_DBG_PARSE); $length = strlen($code); --- 109,113 ---- function _addParseData ($code, $first_char_of_next_context = '') { ! geshi_dbg('GeSHiStringContext::_addParseData(' . substr($code, 0, 15) . '...)', GESHI_DBG_PARSE); $length = strlen($code); |
From: BenBE <be...@us...> - 2005-09-11 12:12:02
|
Update of /cvsroot/geshi/geshi-src/geshi/contexts/delphi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12744/geshi-src/geshi/contexts/delphi Modified Files: delphi.php Log Message: add: Most reserved words add: Highlighting for standard types fix: Some symbols for the context were grouped wrong fix: Fixed hex numbers, and int\hex char regexps Index: delphi.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/contexts/delphi/delphi.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** delphi.php 10 Sep 2005 01:15:18 -0000 1.3 --- delphi.php 11 Sep 2005 12:11:52 -0000 1.4 *************** *** 2,9 **** /** * GeSHi - Generic Syntax Highlighter ! * * For information on how to use GeSHi, please consult the documentation * found in the docs/ directory, or online at http://geshi.org/docs/ ! * * This file is part of GeSHi. * --- 2,9 ---- /** * GeSHi - Generic Syntax Highlighter ! * * For information on how to use GeSHi, please consult the documentation * found in the docs/ directory, or online at http://geshi.org/docs/ ! * * This file is part of GeSHi. * *************** *** 48,58 **** 0 => array( //@todo get keywords normal way ! 'function', 'begin', 'end', 'if', 'then', 'else', 'div', 'var', 'string', 'type', 'record', ! 'array', 'of', 'const', 'case', 'in', 'and', 'nil', 'try', 'finally', 'shr', 'while', ! 'do', 'asm', 'for', 'to', 'procedure', 'shl', 'with', 'repeat', 'until', 'unit', ! 'interface', 'uses', 'implementation', 'or' ), 1 => $CONTEXT . '/keywords', ! 2 => 'color:#ca8;font-weight:bold;', 3 => false, 4 => '' --- 48,151 ---- 0 => array( //@todo get keywords normal way ! //@todo handle special keyword cases for exports, read, write, index, default, stored, nodefault, message ... ! 'And', ! 'Array', ! 'As', ! 'Asm', ! 'Assembler', ! 'At', ! 'Begin', ! 'Case', ! 'Class', ! 'Const', ! 'Constructor', ! 'Contains', ! 'Destructor', ! 'Div', ! 'Do', ! 'DownTo', ! 'Else', ! 'End', ! 'Except', ! 'File', ! 'Finalization', ! 'Finally', ! 'For', ! 'Function', ! 'Goto', ! 'If', ! 'Implementation', ! 'In', ! 'Inherited', ! 'Initialization', ! 'Interface', ! 'Is', ! 'Mod', ! 'Nil', ! 'Not', ! 'Object', ! 'Of', ! 'On', ! 'Or', ! 'Packed', ! 'Package', ! 'Procedure', ! 'Program', ! 'Property', ! 'Raise', ! 'Record', ! 'Requires', ! 'Repeat', ! 'Set', ! 'Shl', ! 'Shr', ! 'Then', ! 'ThreadVar', ! 'To', ! 'Try', ! 'Type', ! 'Unit', ! 'Until', ! 'Uses', ! 'Var', ! 'While', ! 'With', ! 'Xor', ! ! 'Private', 'Protected', 'Public', 'Published', ! ! 'Virtual', 'Abstract', 'Override', 'Overload', ! ! 'cdecl', 'stdcall', 'register', 'pascal', 'safecall', 'near', 'far' ), 1 => $CONTEXT . '/keywords', ! 2 => 'color:#f00; font-weight:bold;', ! 3 => false, ! 4 => '' ! ), ! 1 => array( ! 0 => array( ! //@todo get keywords normal way ! 'Boolean', 'ByteBool', 'LongBool', 'WordBool', 'Bool', ! ! 'Byte', 'SmallInt', ! 'ShortInt', 'Word', ! 'Integer', 'Cardinal', ! 'LongInt', 'DWORD', ! 'Int64', ! ! 'Single', 'Double', 'Extended', ! 'Real48', 'Real', 'Comp', 'Currency', ! ! 'Pointer', ! ! 'Char', 'AnsiChar', 'WideChar', ! 'PChar', 'PAnsiChar', 'PWideChar', ! 'String', 'AnsiString', 'WideString', ! ! 'THandle' ! ), ! 1 => $CONTEXT . '/keytypes', ! 2 => 'color:#000; font-weight:bold;', 3 => false, 4 => '' *************** *** 70,74 **** 1 => array( 0 => array( ! ':', ';', '@' ), 1 => $CONTEXT . '/ctrlsym', --- 163,167 ---- 1 => array( 0 => array( ! ':', ';', ',' ), 1 => $CONTEXT . '/ctrlsym', *************** *** 91,95 **** 4 => array( 0 => array( ! '.', '^' ), 1 => $CONTEXT . '/oopsym', --- 184,188 ---- 4 => array( 0 => array( ! '.', '@', '^' ), 1 => $CONTEXT . '/oopsym', *************** *** 103,107 **** 0 => array( 0 => array( ! '/(#\$[0-9]+)/' ), 1 => '#', --- 196,200 ---- 0 => array( 0 => array( ! '/(#[0-9]+)/' ), 1 => '#', *************** *** 112,115 **** --- 205,217 ---- 1 => array( 0 => array( + '/(#\$[0-9a-fA-F]+)/' + ), + 1 => '#', + 2 => array( + 1 => array($CONTEXT . '/charhex', 'color:#db9;', false) + ) + ), + 2 => array( + 0 => array( '/(\$[0-9a-fA-F_]+)/' ), *************** *** 119,124 **** ) ), ! 2 => geshi_use_doubles($CONTEXT), ! 3 => geshi_use_integers($CONTEXT) ); --- 221,226 ---- ) ), ! 3 => geshi_use_doubles($CONTEXT), ! 4 => geshi_use_integers($CONTEXT) ); *************** *** 132,134 **** ); ! ?> --- 234,236 ---- ); ! ?> \ No newline at end of file |
From: BenBE <be...@us...> - 2005-09-11 12:09:40
|
Update of /cvsroot/geshi/geshi-src/geshi/contexts/delphi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12370/geshi-src/geshi/contexts/delphi Modified Files: asm.php Log Message: add: instruction set for I386 add: instruction set for 387 (FPU) add: instruction set for MMX add: instruction set for 3DNow add: instruction set for SSE todo: sort them to be each in the correct cathegory fix: some colors add: control directives (DB, DW, DD, PTR, OFFSET, ...) Index: asm.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/contexts/delphi/asm.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** asm.php 8 Sep 2005 06:23:40 -0000 1.2 --- asm.php 11 Sep 2005 12:09:26 -0000 1.3 *************** *** 2,9 **** /** * GeSHi - Generic Syntax Highlighter ! * * For information on how to use GeSHi, please consult the documentation * found in the docs/ directory, or online at http://geshi.org/docs/ ! * * This file is part of GeSHi. * --- 2,9 ---- /** * GeSHi - Generic Syntax Highlighter ! * * For information on how to use GeSHi, please consult the documentation * found in the docs/ directory, or online at http://geshi.org/docs/ ! * * This file is part of GeSHi. * *************** *** 30,34 **** * @copyright (C) 2005 Nigel McNie * @version $Id$ ! * */ --- 30,34 ---- * @copyright (C) 2005 Nigel McNie * @version $Id$ ! * */ *************** *** 46,61 **** ); ! $this->_styler->setStyle($CONTEXT, 'color:#22f;'); ! $this->_styler->setStartStyle($CONTEXT, 'color:#22f;font-weight:bold;'); ! $this->_styler->setEndStyle($CONTEXT, 'color:#22f;font-weight:bold;'); $this->_contextKeywords = array( 0 => array( 0 => array( ! 'mov', 'cmp', 'ja', 'jb', 'xor', 'inc', 'jmp', 'test', 'jz', 'not', 'setnz', ! 'call', 'push', 'cmovz', 'lea', 'db', 'sub', 'jnz', 'movzx', 'bt', 'setc' ), 1 => $CONTEXT . '/keywords', ! 2 => 'color:#880;font-weight:bold;', 3 => false, 4 => '' --- 46,228 ---- ); ! $this->_styler->setStyle($CONTEXT, 'color:#00f;'); ! $this->_styler->setStartStyle($CONTEXT, 'color:#f00;font-weight:bold;'); ! $this->_styler->setEndStyle($CONTEXT, 'color:#f00;font-weight:bold;'); $this->_contextKeywords = array( + //Assembler Directives 0 => array( 0 => array( ! 'db','dd','dw' ), 1 => $CONTEXT . '/keywords', ! 2 => 'color:#00f; font-weight:bold;', ! 3 => false, ! 4 => '' ! ), ! ! 1 => array( ! 0 => array( ! 'large', 'small', ! 'offset','vmtoffset','dmtindex', ! 'byte', 'word', 'dword', 'qword', 'tbyte', 'ptr' ! ), ! 1 => $CONTEXT . '/control', ! 2 => 'color:#00f; font-weight: bold;', ! 3 => false, ! 4 => '' ! ), ! ! //CPU i386 instructions ! 2 => array( ! 0 => array( ! /* ! // @todo order the i386 instruction set ! ! 'aaa','aad','aam','aas','adc','add','and','call','cbw','clc','cld','cli','cmc','cmp', ! 'cmps','cmpsb','cmpsw','cwd','daa','das','dec','div','esc','hlt','idiv','imul','in','inc', ! 'int','into','iret','ja','jae','jb','jbe','jc','jcxz','je','jg','jge','jl','jle','jmp', ! 'jna','jnae','jnb','jnbe','jnc','jne','jng','jnge','jnl','jnle','jno','jnp','jns','jnz', ! 'jo','jp','jpe','jpo','js','jz','lahf','lds','lea','les','lods','lodsb','lodsw','loop', ! 'loope','loopew','loopne','loopnew','loopnz','loopnzw','loopw','loopz','loopzw','mov', ! 'movs','movsb','movsw','mul','neg','nop','not','or','out','pop','popf','push','pushf', ! 'rcl','rcr','ret','retf','retn','rol','ror','sahf','sal','sar','sbb','scas','scasb','scasw', ! 'shl','shr','stc','std','sti','stos','stosb','stosw','sub','test','wait','xchg','xlat', ! 'xlatb','xor','bound','enter','ins','insb','insw','leave','outs','outsb','outsw','popa','pusha','pushw', ! 'arpl','lar','lsl','sgdt','sidt','sldt','smsw','str','verr','verw','clts','lgdt','lidt','lldt','lmsw','ltr', ! 'bsf','bsr','bt','btc','btr','bts','cdq','cmpsd','cwde','insd','iretd','iretdf','iretf', ! 'jecxz','lfs','lgs','lodsd','loopd','looped','loopned','loopnzd','loopzd','lss','movsd', ! 'movsx','movzx','outsd','popad','popfd','pushad','pushd','pushfd','scasd','seta','setae', ! 'setb','setbe','setc','sete','setg','setge','setl','setle','setna','setnae','setnb','setnbe', ! 'setnc','setne','setng','setnge','setnl','setnle','setno','setnp','setns','setnz','seto','setp', ! 'setpe','setpo','sets','setz','shld','shrd','stosd','bswap','cmpxchg','invd','invlpg', ! 'wbinvd','xadd','lock','rep','repe','repne','repnz','repz' ! */ ! 'AAA','AAD','AAM','AAS','ADC','ADD','AND','ARPL','BOUND','BSF','BSR','BSWAP','BT','BTC','BTR', ! 'BTS','CALL','CBW','CDQ','CLC','CLD','CLI','CLTS','CMC','CMP','CMPSB','CMPSD','CMPSW', ! 'CMPXCHG','CMPXCHG486','CMPXCHG8B','CPUID','CWD','CWDE', ! 'cmova','cmovae','cmovb','cmovbe','cmovc','cmovcxz','cmove','cmovg','cmovge','cmovl','cmovle', ! 'cmovna','cmovnae','cmovnb','cmovnbe','cmovnc','cmovne','cmovng','cmovnge','cmovnl','cmovnle', ! 'cmovno','cmovnp','cmovns','cmovnz','cmovo','cmovp','cmovpe','cmovpo','cmovs','cmovz', ! 'DAA','DAS','DEC','DIV','EMMS','ENTER','HLT','IBTS','ICEBP','IDIV','IMUL','IN','INC','INSB', ! 'INSD','INSW','INT','INT01','INT1','INT03','INT3','INTO','INVD','INVLPG','IRET','IRETD','IRETW', ! 'JCXZ','JECXZ','JMP','ja','jae','jb','jbe','jc','jcxz','je','jg','jge','jl','jle','jna','jnae', ! 'jnb','jnbe','jnc','jne','jng','jnge','jnl','jnle','jno','jnp','jns','jnz','jo','jp','jpe', ! 'jpo','js','jz','LAHF','LAR','LCALL','LDS','LEA','LEAVE','LES','LFS','LGDT','LGS','LIDT', ! 'LJMP','LLDT','LMSW','LOADALL','LOADALL286','LOCK','LODSB','LODSD','LODSW','LOOP','LOOPE', ! 'LOOPNE','LOOPNZ','LOOPZ','LSL','LSS','LTR','MOV','MOVD','MOVQ','MOVSB','MOVSD','MOVSW','MOVSX', ! 'MOVZX','MUL','NEG','NOP','NOT','OR','OUT','OUTSB','OUTSD','OUTSW','POP','POPA','POPAD','POPAW', ! 'POPF','POPFD','POPFW','PUSH','PUSHA','PUSHAD','PUSHAW','PUSHF','PUSHFD','PUSHFW','RCL','RCR', ! 'RDSHR','RDMSR','RDPMC','RDTSC','REP','REPE','REPNE','REPNZ','REPZ','RET','RETF','RETN','ROL', ! 'ROR','RSDC','RSLDT','RSM','SAHF','SAL','SALC','SAR','SBB','SCASB','SCASD','SCASW','SGDT', ! 'seta','setae','setb','setbe','setc','setcxz','sete','setg','setge','setl','setle','setna', ! 'setnae','setnb','setnbe','setnc','setne','setng','setnge','setnl','setnle','setno','setnp', ! 'setns','setnz','seto','setp','setpe','setpo','sets','setz', ! 'SHL','SHLD','SHR','SHRD','SIDT','SLDT','SMI','SMINT','SMINTOLD','SMSW','STC','STD','STI','STOSB', ! 'STOSD','STOSW','STR','SUB','SVDC','SVLDT','SVTS','SYSCALL','SYSENTER','SYSEXIT','SYSRET','TEST', ! 'UD1','UD2','UMOV','VERR','VERW','WAIT','WBINVD','WRSHR','WRMSR','XADD','XBTS','XCHG','XLAT', ! 'XLATB','XOR' ! ), ! 1 => $CONTEXT . '/instr_i386', ! 2 => 'color:#00f; font-weight:bold;', ! 3 => false, ! 4 => '' ! ), ! ! //FPU i387 instructions ! 3 => array( ! 0 => array( ! /* ! // @todo order the i387 instruction set ! 'f2xm1','fabs','fadd','faddp','fbld','fbstp','fchs','fclex','fcom','fcomp','fcompp','fdecstp', ! 'fdisi','fdiv','fdivp','fdivr','fdivrp','feni','ffree','fiadd','ficom','ficomp','fidiv', ! 'fidivr','fild','fimul','fincstp','finit','fist','fistp','fisub','fisubr','fld','fld1', ! 'fldcw','fldenv','fldenvw','fldl2e','fldl2t','fldlg2','fldln2','fldpi','fldz','fmul', ! 'fmulp','fnclex','fndisi','fneni','fninit','fnop','fnsave','fnsavew','fnstcw','fnstenv', ! 'fnstenvw','fnstsw','fpatan','fprem','fptan','frndint','frstor','frstorw','fsave', ! 'fsavew','fscale','fsqrt','fst','fstcw','fstenv','fstenvw','fstp','fstsw','fsub','fsubp', ! 'fsubr','fsubrp','ftst','fwait','fxam','fxch','fxtract','fyl2x','fyl2xp1', ! 'fsetpm','fcos','fldenvd','fnsaved','fnstenvd','fprem1','frstord','fsaved','fsin','fsincos', ! 'fstenvd','fucom','fucomp','fucompp' ! */ ! 'F2XM1','FABS','FADD','FADDP','FBLD','FBSTP','FCHS','FCLEX','FCMOVB','FCMOVBE','FCMOVE','FCMOVNB', ! 'FCMOVNBE','FCMOVNE','FCMOVNU','FCMOVU','FCOM','FCOMI','FCOMIP','FCOMP','FCOMPP','FCOS','FDECSTP', ! 'FDISI','FDIV','FDIVP','FDIVR','FDIVRP','FEMMS','FENI','FFREE','FIADD','FICOM','FICOMP','FIDIV', ! 'FIDIVR','FILD','FIMUL','FINCSTP','FINIT','FIST','FISTP','FISUB','FISUBR','FLD','FLD1','FLDCW', ! 'FLDENV','FLDL2E','FLDL2T','FLDLG2','FLDLN2','FLDPI','FLDZ','FMUL','FMULP','FNCLEX','FNDISI', ! 'FNENI','FNINIT','FNOP','FNSAVE','FNSTCW','FNSTENV','FNSTSW','FPATAN','FPREM','FPREM1','FPTAN', ! 'FRNDINT','FRSTOR','FSAVE','FSCALE','FSETPM','FSIN','FSINCOS','FSQRT','FST','FSTCW','FSTENV', ! 'FSTP','FSTSW','FSUB','FSUBP','FSUBR','FSUBRP','FTST','FUCOM','FUCOMI','FUCOMIP','FUCOMP', ! 'FUCOMPP','FWAIT','FXAM','FXCH','FXTRACT','FYL2X','FYL2XP1' ! ), ! 1 => $CONTEXT . '/instr_i387', ! 2 => 'color:#00f; font-weight:bold;', ! 3 => false, ! 4 => '' ! ), ! ! //MMX instruction set ! 4 => array( ! 0 => array( ! // @todo order the mmx instruction set ! ! 'FFREEP','FXRSTOR','FXSAVE','PREFETCHNTA','PREFETCHT0','PREFETCHT1','PREFETCHT2','SFENCE', ! 'MASKMOVQ','MOVNTQ','PAVGB','PAVGW','PEXTRW','PINSRW','PMAXSW','PMAXUB','PMINSW','PMINUB', ! 'PMOVMSKB','PMULHUW','PSADBW','PSHUFW', ! ! 'PACKSSDW','PACKSSWB','PACKUSWB','PADDB','PADDD','PADDSB','PADDSIW','PADDSW','PADDUSB','PADDUSW', ! 'PADDW','PAND','PANDN','PAVEB','PCMPEQB','PCMPEQD','PCMPEQW','PCMPGTB','PCMPGTD', ! 'PCMPGTW','PDISTIB','PFCMPEQ','PFCMPGE','PFCMPGT','PMACHRIW','PMADDWD', ! 'PMAGW','PMVGEZB','PMVLZB','PMVNZB','PMVZB', ! 'POR','PSLLD','PSLLQ','PSLLW','PSRAD','PSRAW','PSRLD','PSRLQ','PSRLW', ! 'PSUBB','PSUBD','PSUBSB','PSUBSIW','PSUBSW','PSUBUSB','PSUBUSW','PSUBW','PUNPCKHBW','PUNPCKHDQ', ! 'PUNPCKHWD','PUNPCKLBW','PUNPCKLDQ','PUNPCKLWD','PXOR' ! ), ! 1 => $CONTEXT . '/instr/mmx', ! 2 => 'color:#00f; font-weight:bold;', ! 3 => false, ! 4 => '' ! ), ! ! //SSE instruction set ! 5 => array( ! 0 => array( ! // @todo order the SSE instruction set ! 'ADDPS','ADDSS','ANDNPS','ANDPS','CMPEQPS','CMPEQSS','CMPLEPS','CMPLESS','CMPLTPS','CMPLTSS', ! 'CMPNEQPS','CMPNEQSS','CMPNLEPS','CMPNLESS','CMPNLTPS','CMPNLTSS','CMPORDPS','CMPORDSS', ! 'CMPUNORDPS','CMPUNORDSS','CMPPS','CMPSS','COMISS','CVTPI2PS','CVTPS2PI','CVTSI2SS','CVTSS2SI', ! 'CVTTPS2PI','CVTTSS2SI','DIVPS','DIVSS','LDMXCSR','MAXPS','MAXSS','MINPS','MINSS','MOVAPS', ! 'MOVHPS','MOVLHPS','MOVLPS','MOVHLPS','MOVMSKPS','MOVNTPS','MOVSS','MOVUPS','MULPS','MULSS', ! 'ORPS','RCPPS','RCPSS','RSQRTPS','RSQRTSS','SHUFPS','SQRTPS','SQRTSS','STMXCSR','SUBPS', ! 'SUBSS','UCOMISS','UNPCKHPS','UNPCKLPS','XORPS' ! ), ! 1 => $CONTEXT . '/instr/sse', ! 2 => 'color:#00f; font-weight:bold;', ! 3 => false, ! 4 => '' ! ), ! ! //3DNow instruction set ! 6 => array( ! 0 => array( ! // @todo order the 3Dnow! instruction set ! 'PAVGUSB','PF2ID','PFACC','PFADD','PFMUL','PFRCP','PFRCPIT1','PFRCPIT2','PFRSQIT1','PFRSQRT', ! 'PFSUB','PFSUBR','PFMAX','PFMIN','PI2FD','PMULHRIW','PMULHRWA','PMULHRWC','PMULHW','PMULLW', ! 'PREFETCH','PREFETCHW' ! ), ! 1 => $CONTEXT . '/instr/3Dnow', ! 2 => 'color:#00f; font-weight:bold;', ! 3 => false, ! 4 => '' ! ), ! ! //3DNowExt instruction set ! 7 => array( ! 0 => array( ! // @todo order the 3Dnow! Ext instruction set ! 'PFNACC','PFPNACC','PI2FW','PF2IW','PSWAPD' ! ), ! 1 => $CONTEXT . '/instr/3Dnow2', ! 2 => 'color:#00f; font-weight:bold;', 3 => false, 4 => '' *************** *** 66,70 **** 0 => array( 0 => array( ! ',', ';', '[', ']', '@', '.' ), 1 => $CONTEXT . '/sym', --- 233,237 ---- 0 => array( 0 => array( ! ',', ';', '[', ']', '.' ), 1 => $CONTEXT . '/sym', *************** *** 102,104 **** ); ! ?> --- 269,271 ---- ); ! ?> \ No newline at end of file |
From: Nigel M. <ora...@us...> - 2005-09-10 01:15:26
|
Update of /cvsroot/geshi/geshi-src/geshi/contexts/delphi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25364/geshi/contexts/delphi Modified Files: delphi.php Log Message: Added TODO about OCC naming. Index: delphi.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/contexts/delphi/delphi.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** delphi.php 30 Aug 2005 00:14:51 -0000 1.2 --- delphi.php 10 Sep 2005 01:15:18 -0000 1.3 *************** *** 33,36 **** --- 33,37 ---- */ + // @todo [blocking 1.1.1] Rename OCCs with parent's name in front for theming $this->_childContexts = array( new GeSHiContext('delphi', $DIALECT, 'multi_comment'), |
From: Nigel M. <ora...@us...> - 2005-09-09 04:14:49
|
Update of /cvsroot/geshi/geshi-src/geshi In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7280/geshi Modified Files: functions.geshi.php Log Message: Prevent warning in eclipse. Also testing acls and syncmail. Index: functions.geshi.php =================================================================== RCS file: /cvsroot/geshi/geshi-src/geshi/functions.geshi.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** functions.geshi.php 9 Sep 2005 03:22:59 -0000 1.13 --- functions.geshi.php 9 Sep 2005 04:14:41 -0000 1.14 *************** *** 149,152 **** --- 149,153 ---- // ADD SOME MORE: Return matching table (?) if ($need_table) { + $matches = array(); preg_match_all($regex, $string, $matches); //$table = $matches; |