setLocale($locale); } // function setLocale() /** * Set details of the external library that PHPExcel should use for rendering charts * * @param string $libraryName Internal reference name of the library * e.g. PHPExcel_Settings::CHART_RENDERER_JPGRAPH * @param string $libraryBaseDir Directory path to the library's base folder * @return boolean Success or failure */ public static function setChartRenderer($libraryName, $libraryBaseDir) { if (!self::setChartRendererName($libraryName)) return FALSE; return self::setChartRendererPath($libraryBaseDir); } // function setChartRenderer() /** * Identify to PHPExcel the external library to use for rendering charts * * @param string $libraryName Internal reference name of the library * e.g. PHPExcel_Settings::CHART_RENDERER_JPGRAPH * @return boolean Success or failure */ public static function setChartRendererName($libraryName) { if (!in_array($libraryName,self::$_chartRenderers)) { return FALSE; } self::$_chartRendererName = $libraryName; return TRUE; } // function setChartRendererName() /** * Tell PHPExcel where to find the external library to use for rendering charts * * @param string $libraryBaseDir Directory path to the library's base folder * @return boolean Success or failure */ public static function setChartRendererPath($libraryBaseDir) { if ((file_exists($libraryBaseDir) === false) || (is_readable($libraryBaseDir) === false)) { return FALSE; } self::$_chartRendererPath = $libraryBaseDir; return TRUE; } // function setChartRendererPath() /** * Return the Chart Rendering Library that PHPExcel is currently configured to use (e.g. jpgraph) * * @return string|NULL Internal reference name of the Chart Rendering Library that PHPExcel is * currently configured to use * e.g. PHPExcel_Settings::CHART_RENDERER_JPGRAPH */ public static function getChartRendererName() { return self::$_chartRendererName; } // function getChartRendererName() /** * Return the directory path to the Chart Rendering Library that PHPExcel is currently configured to use * * @return string|NULL Directory Path to the Chart Rendering Library that PHPExcel is * currently configured to use */ public static function getChartRendererPath() { return self::$_chartRendererPath; } // function getChartRendererPath() /** * Set details of the external library that PHPExcel should use for rendering PDF files * * @param string $libraryName Internal reference name of the library * e.g. PHPExcel_Settings::PDF_RENDERER_TCPDF, * PHPExcel_Settings::PDF_RENDERER_DOMPDF * or PHPExcel_Settings::PDF_RENDERER_MPDF * @param string $libraryBaseDir Directory path to the library's base folder * @return boolean Success or failure */ public static function setPdfRenderer($libraryName, $libraryBaseDir) { if (!self::setPdfRendererName($libraryName)) return FALSE; return self::setPdfRendererPath($libraryBaseDir); } // function setPdfRenderer() /** * Identify to PHPExcel the external library to use for rendering PDF files * * @param string $libraryName Internal reference name of the library * e.g. PHPExcel_Settings::PDF_RENDERER_TCPDF, * PHPExcel_Settings::PDF_RENDERER_DOMPDF * or PHPExcel_Settings::PDF_RENDERER_MPDF * @return boolean Success or failure */ public static function setPdfRendererName($libraryName) { if (!in_array($libraryName,self::$_pdfRenderers)) { return FALSE; } self::$_pdfRendererName = $libraryName; return TRUE; } // function setPdfRendererName() /** * Tell PHPExcel where to find the external library to use for rendering PDF files * * @param string $libraryBaseDir Directory path to the library's base folder * @return boolean Success or failure */ public static function setPdfRendererPath($libraryBaseDir) { if ((file_exists($libraryBaseDir) === false) || (is_readable($libraryBaseDir) === false)) { return FALSE; } self::$_pdfRendererPath = $libraryBaseDir; return TRUE; } // function setPdfRendererPath() /** * Return the PDF Rendering Library that PHPExcel is currently configured to use (e.g. dompdf) * * @return string|NULL Internal reference name of the PDF Rendering Library that PHPExcel is * currently configured to use * e.g. PHPExcel_Settings::PDF_RENDERER_TCPDF, * PHPExcel_Settings::PDF_RENDERER_DOMPDF * or PHPExcel_Settings::PDF_RENDERER_MPDF */ public static function getPdfRendererName() { return self::$_pdfRendererName; } // function getPdfRendererName() /** * Return the directory path to the PDF Rendering Library that PHPExcel is currently configured to use * * @return string|NULL Directory Path to the PDF Rendering Library that PHPExcel is * currently configured to use */ public static function getPdfRendererPath() { return self::$_pdfRendererPath; } // function getPdfRendererPath() }