X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Fincludes%2Fclass.graphic.inc;h=da537dd5caa00b8ea00a854ed37c0f265c39718f;hb=af9e628479b38b0cd7972044ab02902b020211e9;hp=7b7d32e9d886341116b634244a058e9d05274147;hpb=f8377d0cb0e9f06bf8de4a00e6ce8f83408a6045;p=fa-stable.git diff --git a/reporting/includes/class.graphic.inc b/reporting/includes/class.graphic.inc index 7b7d32e9..da537dd5 100644 --- a/reporting/includes/class.graphic.inc +++ b/reporting/includes/class.graphic.inc @@ -160,7 +160,7 @@ class graph // You can also use another UTF-8 font and put it in config.php with the name in $UTF8_fontfile $this->fontfile = $this->encoding == 'UTF-8' ? (isset($SysPrefs->UTF8_fontfile) && $SysPrefs->UTF8_fontfile != "" ? $path.$SysPrefs->UTF8_fontfile : $path.'FreeSans.ttf') : $path.'LiberationSans-Regular.ttf'; - + $this->x = $this->y = $this->z = array(); $this->biggest_x = NULL; $this->biggest_y = NULL; @@ -1000,6 +1000,12 @@ class graph $size = 12; $y += $size + 3; $angle = 0; + + if ($this->encoding == 'UTF-8' && is_arabic($string)) + { + $size += 2; + $string = str_replace(" ", " ", $string); + } imagettftext($img, $size, $angle, $x, $y + $alt, $col, $this->fontfile, $string); }