* Added hook in GIFBUILDER to preprocess configuration
[Packages/TYPO3.CMS.git] / typo3 / sysext / cms / tslib / class.tslib_gifbuilder.php
index c44b998..0f75191 100755 (executable)
@@ -132,6 +132,21 @@ class tslib_gifBuilder extends t3lib_stdGraphic {
                        $this->setup = $conf;
                        $this->data = $data;
 
+                       /* Hook preprocess gifbuilder conf 
+                        * Added by Julle for 3.8.0
+                        *
+                        * Let's you pre-process the gifbuilder configuration. for
+                        * example you can split a string up into lines and render each
+                        * line as TEXT obj, see extension julle_gifbconf
+                        */
+
+                       if (is_array($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/class.tslib_gifbuilder.php']['gifbuilder-ConfPreProcess']))    {
+                               foreach($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/class.tslib_gifbuilder.php']['gifbuilder-ConfPreProcess'] as $_funcRef)    {
+                                       $_params = $this->setup;
+                                       $this->setup = t3lib_div::callUserFunction($_funcRef,$_params,$this);
+                               }
+                       }
+
                                // Initializing global Char Range Map
                        $this->charRangeMap = array();
                        if (is_array($GLOBALS['TSFE']->tmpl->setup['_GIFBUILDER.']['charRangeMap.']))   {