Closure operator now behaves as default argument operator, documentation.

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@965 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2008-06-03 18:33:17 +00:00
parent c5159ebcf7
commit d00beeb55f
11 changed files with 182 additions and 60 deletions
@@ -256,14 +256,15 @@ function autoformat__table($rows) {
function autoformat__line($line) {
$line = preg_replace("/'''(.*?)'''/", "<strong>\\1</strong>", $line);
$line = preg_replace("/''(.*?)''/", "<em>\\1</em>", $line);
$line = preg_replace_callback("/@(.*?)@/", "autoformat__code", $line);
$line = preg_replace_callback("/@(([^@]|@@)*)@/", "autoformat__code", $line);
$line = preg_replace_callback("/\[\[(.*?)\|(.*?)]]/", "autoformat__link_s", $line);
$line = preg_replace_callback("/\[\[(.*?)]](s?)/", "autoformat__link", $line);
return $line;
}
function autoformat__code($matches) {
return '<tt>' . syntax_highlight(htmlspecialchars($matches[1])) . '</tt>';
$code = str_replace('@@','@',$matches[1]);
return '<tt>' . syntax_highlight(htmlspecialchars($code)) . '</tt>';
}
function autoformat__link($matches) {