예제 #1
0
	function getIconHtml() // {{{ for admin page
	{
		global $headerlib;
		
		if ((!empty($this->icon) && $this->icon !== 'img/icons/shading.png') || in_array($this->label, array('Autosave'))) {
			return parent::getIconHtml();
		}
		
		$headerlib->add_cssfile('lib/ckeditor/skins/kama/editor.css');
		$cls = strtolower($this->wysiwyg);
		$cls = str_replace(array('selectall', 'removeformat', 'spellchecker'), array('selectAll', 'removeFormat', 'checkspell'), $cls);	// work around some "features" in ckeditor icons.css
		$headerlib->add_css(
						'span.cke_skin_kama {border: none;background: none;padding:0;margin:0;}'.
						'.toolbars-admin .row li.toolbar > span.cke_skin_kama {display: inline-block;}'
		);
		return '<span class="cke_skin_kama"><span class="cke_button"><span class="cke_button_' . htmlentities($cls, ENT_QUOTES, 'UTF-8') . '"' .
						' title="' . htmlentities($this->getLabel(), ENT_QUOTES, 'UTF-8') . '">'.
						'<span class="cke_icon"> </span>'.
					'</span></span></span>';
	} // }}}
예제 #2
0
 function getIconHtml()
 {
     if (!empty($this->iconname)) {
         $smarty = TikiLib::lib('smarty');
         $smarty->loadPlugin('smarty_function_icon');
         return smarty_function_icon(['name' => $this->iconname, 'ititle' => ':' . htmlentities($this->getLabel(), ENT_QUOTES, 'UTF-8'), 'iclass' => 'tips'], $smarty);
     }
     if (!empty($this->icon) && $this->icon !== 'img/icons/shading.png' || in_array($this->label, array('Autosave'))) {
         return parent::getIconHtml();
     }
     global $prefs;
     $skin = $prefs['wysiwyg_toolbar_skin'];
     $headerlib = TikiLib::lib('header');
     $headerlib->add_cssfile('vendor/ckeditor/ckeditor/skins/' . $skin . '/editor.css');
     $cls = strtolower($this->wysiwyg);
     $headerlib->add_css('span.cke_skin_' . $skin . ' {border: none;background: none;padding:0;margin:0;}' . '.toolbars-admin .row li.toolbar > span.cke_skin_' . $skin . ' {display: inline-block;}');
     return '<span class="cke_skin_' . $skin . '"><a class="cke_button cke_ltr" style="margin-top:-5px"><span class="cke_button__' . htmlentities($cls, ENT_QUOTES, 'UTF-8') . '_icon"' . ' title="' . htmlentities($this->getLabel(), ENT_QUOTES, 'UTF-8') . '">' . '<span class="cke_icon"> </span>' . '</span></a></span>';
 }
예제 #3
0
 function getIconHtml()
 {
     global $headerlib, $prefs;
     if (!empty($this->icon) && $this->icon !== 'img/icons/shading.png' || in_array($this->label, array('Autosave'))) {
         return parent::getIconHtml();
     }
     $skin = $prefs['wysiwyg_toolbar_skin'];
     $headerlib->add_cssfile('vendor/ckeditor/ckeditor/skins/' . $skin . '/editor.css');
     $cls = strtolower($this->wysiwyg);
     $headerlib->add_css('span.cke_skin_' . $skin . ' {border: none;background: none;padding:0;margin:0;}' . '.toolbars-admin .row li.toolbar > span.cke_skin_' . $skin . ' {display: inline-block;}');
     return '<span class="cke_skin_' . $skin . '"><a class="cke_button cke_ltr"><span class="cke_button__' . htmlentities($cls, ENT_QUOTES, 'UTF-8') . '_icon"' . ' title="' . htmlentities($this->getLabel(), ENT_QUOTES, 'UTF-8') . '">' . '<span class="cke_icon"> </span>' . '</span></a></span>';
 }