\n";
SDV($GuiButtonsDirUrlFmt,"{$FarmPubDirUrl}/guibuttons");
SDV($SmileysFolder, "{$FarmPubDirUrl}/guibuttons");
# display smilie images
Markup("happy2","block","/\{happy\}/","");
Markup("wink2","block","/\{wink\}/","");
Markup("cool","block","/\{cool\}/","");
Markup("confused","block","/\{confused\}/","");
Markup("eek","block","/\{eek\}/","");
Markup("mad","block","/\{angry\}/","");
Markup("rolleyes","block","/\{rolleyes\}/","");
Markup("sad2","block","/\{sad\}/","");
Markup("tongue2","block","/\{tongue\}/","");
Markup("redface2","block","/\{redface\}/","");
Markup("biggrin2","block","/\{biggrin\}/","");
Markup("mad2","block","/\{mad\}/","");
$GUIButtonSpace1 = '$GuiButtonsDirUrlFmt/space1.gif';
$GUIButtonSpace2 = '$GuiButtonsDirUrlFmt/space2.gif';
$GUIButtonSpace3 = '$GuiButtonsDirUrlFmt/space3.gif';
$GUIButtonSpace4 = '$GuiButtonsDirUrlFmt/space4.gif';
$ArrayCount = 0;
$SpaceCount = 0;
SDVA($c_GUIButtons, array(
'italic' => array($ArrayCount++, "''", "''", '$[Emphasized]',
'$GuiButtonsDirUrlFmt/italic.gif"$[Emphasized (italic)]"',
'$[ak_em]'),
'bold' => array($ArrayCount++, "'''", "'''", '$[Strong]',
'$GuiButtonsDirUrlFmt/bold.gif"$[Strong (bold)]"',
'$[ak_strong]'),
'underline' => array($ArrayCount++, '{+', '+}', '$[Underlined Text]',
'$GuiButtonsDirUrlFmt/underline.gif"$[Underline]"'),
// 'extlink' => array($ArrayCount++, '[[', ']]', 'http:// | $[link text]',
// '$GuiButtonsDirUrlFmt/extlink.gif"$[Link to external page]"'),
'big' => array($ArrayCount++, "'+", "+'", '$[Big text]',
'$GuiButtonsDirUrlFmt/big.gif"$[Big text]"'),
'small' => array($ArrayCount++, "'-", "-'", '$[Small text]',
'$GuiButtonsDirUrlFmt/small.gif"$[Small text]"'),
'sup' => array($ArrayCount++, "'^", "^'", '$[Superscript]',
'$GuiButtonsDirUrlFmt/sup.gif"$[Superscript]"'),
'sub' => array($ArrayCount++, "'_", "_'", '$[Subscript]',
'$GuiButtonsDirUrlFmt/sub.gif"$[Subscript]"'),
'h4' => array($ArrayCount++, '\\n!!!! ', '\\n', '$[Heading]',
'$GuiButtonsDirUrlFmt/h.gif"$[Heading]"'),
'center' => array($ArrayCount++, '%25center%25', '', '',
'$GuiButtonsDirUrlFmt/center.gif"$[Center]"'),
'pagelink' => array($ArrayCount++, '[[', ']]', '$[Page link]',
'$GuiButtonsDirUrlFmt/pagelink.gif"$[Link to internal page]"'),
'code' => array($ArrayCount++, "[@", "@]", '$[Code]',
'$GuiButtonsDirUrlFmt/code.gif"$[Code]"'),
'textblue' => array($ArrayCount++, '%25blue%25', '%25%25', '$[Blue Text]',
'$GuiButtonsDirUrlFmt/hightextblue.gif"$[Blue Text]"'),
'textgreen' => array($ArrayCount++, '%25green%25', '%25%25', '$[Green Text]',
'$GuiButtonsDirUrlFmt/hightextgreen.gif"$[Green Text]"'),
'textred' => array($ArrayCount++, '%25red%25', '%25%25', '$[Red Text]',
'$GuiButtonsDirUrlFmt/hightextred.gif"$[Red Text]"'),
// 'textyellow' => array($ArrayCount++, '%25yellow%25', '%25%25', '$[Yellow Text]',
// '$GuiButtonsDirUrlFmt/hightextyellow.gif"$[Yellow Text]"'),
));
# smiley gui-edit buttons
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/spacer.gif');
$c_GUIButtons['happy'] = array($ArrayCount++, '\{happy\}', '', '',
'$GuiButtonsDirUrlFmt/happy.gif"$[Happy]"');
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/pixspace.gif');
$c_GUIButtons['wink'] = array($ArrayCount++, '\{wink\}', '', '',
'$GuiButtonsDirUrlFmt/wink.gif"$[Wink]"');
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/pixspace.gif');
$c_GUIButtons['cool'] = array($ArrayCount++, '\{cool\}', '', '',
'$GuiButtonsDirUrlFmt/cool.gif"$[Cool]"');
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/pixspace.gif');
$c_GUIButtons['confused'] = array($ArrayCount++, '\{confused\}', '', '',
'$GuiButtonsDirUrlFmt/confused.gif"$[Confused]"');
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/pixspace.gif');
$c_GUIButtons['eek'] = array($ArrayCount++, '\{eek\}', '', '',
'$GuiButtonsDirUrlFmt/eek.gif"$[Eek]"');
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/pixspace.gif');
$c_GUIButtons['rolleyes'] = array($ArrayCount++, '\{rolleyes\}', '', '',
'$GuiButtonsDirUrlFmt/rolleyes.gif"$[Roll eyes]"');
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/pixspace.gif');
$c_GUIButtons['sad'] = array($ArrayCount++, '\{sad\}', '', '',
'$GuiButtonsDirUrlFmt/sad.gif"$[Sad]"');
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/pixspace.gif');
$c_GUIButtons['mad'] = array($ArrayCount++, '\{mad\}', '', '',
'$GuiButtonsDirUrlFmt/mad.gif"$[Mad]"');
$c_GUIButtons [$SpaceCount++] = array($ArrayCount++, '', '', '',
'$GuiButtonsDirUrlFmt/pixspace.gif');
$c_GUIButtons['biggrin'] = array($ArrayCount++, '\{biggrin\}', '', '',
'$GuiButtonsDirUrlFmt/biggrin.gif"$[Big grin]"');
Markup('guibuttons', 'directives',
'/\\(:guibuttons:\\)/e',
"Keep(FmtPageName(GUIButtonsMarkup(\$pagename), \$pagename))");
function GUIButtonsMarkup($pagename) {
global $c_GUIButtons;
$cmpfn = create_function('$a,$b', 'return $a[0]-$b[0];');
usort($c_GUIButtons, $cmpfn);
$out = "';
return $out;
}