47 protected $pluginButtons =
'formattext, bidioverride, big, bold, citation, code, definition, deletedtext, emphasis, insertedtext, italic, keyboard, quotation, sample, small, span, strikethrough, strong, subscript, superscript, underline, variable';
50 'formattext' =>
'FormatText',
51 'bidioverride' =>
'BiDiOverride',
54 'citation' =>
'Citation',
56 'definition' =>
'Definition',
57 'deletedtext' =>
'DeletedText',
58 'emphasis' =>
'Emphasis',
59 'insertedtext' =>
'InsertedText',
61 'keyboard' =>
'Keyboard',
62 'monospaced' =>
'MonoSpaced',
63 'quotation' =>
'Quotation',
67 'strikethrough' =>
'StrikeThrough',
69 'subscript' =>
'Subscript',
70 'superscript' =>
'Superscript',
71 'underline' =>
'Underline',
72 'variable' =>
'Variable' 76 'none' =>
'No markup',
78 'bdo' =>
'BiDi override',
79 'big' =>
'Large text',
82 'del' =>
'Deleted text',
83 'dfn' =>
'Definition',
86 'ins' =>
'Inserted text',
90 'small' =>
'Small text',
91 'span' =>
'Style container',
92 'strike' =>
'Strike-through',
93 'strong' =>
'Strong emphasis',
95 'sup' =>
'Superscript',
96 'tt' =>
'Monospaced text',
101 protected $defaultInlineElementsOrder =
'none, bidioverride, big, bold, citation, code, definition, deletedtext, emphasis, insertedtext, italic, keyboard, 102 monospaced, quotation, sample, small, span, strikethrough, strong, subscript, superscript, underline, variable';
106 'bidioverride' =>
'bdo',
109 'citation' =>
'cite',
111 'definition' =>
'dfn',
112 'deletedtext' =>
'del',
114 'insertedtext' =>
'ins',
117 'monospaced' =>
'tt',
122 'strikethrough' =>
'strike',
123 'strong' =>
'strong',
124 'subscript' =>
'sub',
125 'superscript' =>
'sup',
138 $registerRTEinJavascriptString =
'';
139 if (in_array(
'formattext', $this->toolbar)) {
140 if (!is_array($this->thisConfig[
'buttons.']) || !is_array($this->thisConfig[
'buttons.'][
'formattext.'])) {
141 $registerRTEinJavascriptString .=
' 142 RTEarea[' . $RTEcounter .
'].buttons.formattext = new Object();';
145 $hideItems = array();
146 $restrictTo = array(
'*');
148 $prefixLabelWithTag = FALSE;
149 $postfixLabelWithTag = FALSE;
151 if (is_array($this->thisConfig[
'buttons.']) && is_array($this->thisConfig[
'buttons.'][
'formattext.'])) {
153 if ($this->thisConfig[
'buttons.'][
'formattext.'][
'removeItems']) {
157 if ($this->thisConfig[
'buttons.'][
'formattext.'][
'restrictTo']) {
159 } elseif ($this->thisConfig[
'buttons.'][
'formattext.'][
'restrictToItems']) {
163 if ($this->thisConfig[
'buttons.'][
'formattext.'][
'orderItems']) {
164 $inlineElementsOrder =
'none,' . $this->thisConfig[
'buttons.'][
'formattext.'][
'orderItems'];
166 $prefixLabelWithTag = $this->thisConfig[
'buttons.'][
'formattext.'][
'prefixLabelWithTag'] ? TRUE : $prefixLabelWithTag;
167 $postfixLabelWithTag = $this->thisConfig[
'buttons.'][
'formattext.'][
'postfixLabelWithTag'] ? TRUE : $postfixLabelWithTag;
169 $inlineElementsOrder = array_diff(\
TYPO3\CMS\Core\Utility\
GeneralUtility::trimExplode(
',', $this->htmlAreaRTE->cleanList($inlineElementsOrder), TRUE), $hideItems);
170 if (!in_array(
'*', $restrictTo)) {
171 $inlineElementsOrder = array_intersect($inlineElementsOrder, $restrictTo);
174 $inlineElementsOptions = array();
175 foreach ($inlineElementsOrder as $item) {
176 if ($this->htmlAreaRTE->is_FE()) {
177 $inlineElementsOptions[$this->buttonToInlineElement[$item]] = $TSFE->getLLL($this->defaultInlineElements[$this->buttonToInlineElement[$item]], $this->LOCAL_LANG);
179 $inlineElementsOptions[$this->buttonToInlineElement[$item]] = $LANG->getLL($this->defaultInlineElements[$this->buttonToInlineElement[$item]]);
181 $inlineElementsOptions[$this->buttonToInlineElement[$item]] = ($prefixLabelWithTag && $item !=
'none' ? $this->buttonToInlineElement[$item] .
' - ' :
'') . $inlineElementsOptions[$this->buttonToInlineElement[$item]] . ($postfixLabelWithTag && $item !=
'none' ?
' - ' . $this->buttonToInlineElement[$item] :
'');
183 $first = array_shift($inlineElementsOptions);
185 if (!is_array($this->thisConfig[
'buttons.']) || !is_array($this->thisConfig[
'buttons.'][
'formattext.']) || !$this->thisConfig[
'buttons.'][
'formattext.'][
'orderItems']) {
186 asort($inlineElementsOptions);
189 $JSInlineElements = array();
190 $JSInlineElements[] = array($first,
'none');
191 foreach ($inlineElementsOptions as $item => $label) {
192 $JSInlineElements[] = array($label, $item);
194 if ($this->htmlAreaRTE->is_FE()) {
195 $GLOBALS[
'TSFE']->csConvObj->convArray($JSInlineElements, $this->htmlAreaRTE->OutputCharset,
'utf-8');
197 $registerRTEinJavascriptString .=
' 198 RTEarea[' . $RTEcounter .
'].buttons.formattext.options = ' . json_encode($JSInlineElements) .
';';
200 return $registerRTEinJavascriptString;
$defaultInlineElementsOrder
buildJavascriptConfiguration($RTEcounter)
static trimExplode($delim, $string, $removeEmptyValues=FALSE, $limit=0)
$relativePathToLocallangFile
$convertToolbarForHtmlAreaArray
if(!defined('TYPO3_MODE')) $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_userauth.php']['logoff_pre_processing'][]