Edit report at http://bugs.php.net/bug.php?id=45176&edit=1

 ID:               45176
 Comment by:       sridevigara at gmail dot com
 Reported by:      heyond at yahoo dot com dot cn
 Summary:          Create image from ttf file failed
 Status:           No Feedback
 Type:             Bug
 Package:          GD related
 Operating System: windows 2003
 PHP Version:      5.2.6
 Assigned To:      pajoye

 New Comment:

Hi 

i am trying to create a image using hindi mangal (unicode) font text but
i am facing a problem that matras are coming properly .Can anyone help
me


Previous Comments:
------------------------------------------------------------------------
[2009-03-10 01:00:01] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".

------------------------------------------------------------------------
[2009-03-02 15:49:40] paj...@php.net

I need:

- a small script to reproduce what you are doing

- All fonts files you use with the script



Without that, I can't help you to solve this problem, if there is any.

------------------------------------------------------------------------
[2008-12-16 10:08:02] patrick dot landolt at artack dot ch

I also have the same problem with GD on PHP V5.2.6 installed. My font is
a chinese one.

------------------------------------------------------------------------
[2008-06-05 06:45:11] heyond at yahoo dot com dot cn

The completed script is:

<?php



define('BG1',  'DDD4BB');



header("Content-type: image/jpeg");



$word = 'abc';//$word = 'ºº×Ö'

$wordnum = 6;



$word = iconv('GBK', 'UTF-8', $word);



//$fontfile =
'./data/fonts/1.ttf';//http://www.guomo.com/data/fonts/1.ttf This file
'1.ttf' is normal

$fontfile =
'./data/fonts/174.ttf';//http://www.guomo.com/data/fonts/174.ttf This
file '174.ttf' is abnormal



$width = 30

$height = 40;



$fontsize = 20;

$x = 0;

$y = $fontsize + 10;



$im = imagecreate($wordnum * $width, $height);

$bgcolor = imagecolorallocate($im, hexdec(substr(BG1, 0, 2)),
hexdec(substr(BG1, 2, 2)), hexdec(substr(BG1, 4, 2)));

$fgcolor = imagecolorallocate($im, 0, 0, 0);

imagefill($im, 0, 0, $bgcolor);



imagettftext($im, $fontsize, 0, $x, $y, $fgcolor, $fontfile, $word);

imagejpeg($im);

imagedestroy($im);

exit;



?>

------------------------------------------------------------------------
[2008-06-05 06:38:14] heyond at yahoo dot com dot cn

http://www.guomo.com/data/fonts/174.ttf

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    http://bugs.php.net/bug.php?id=45176


-- 
Edit this bug report at http://bugs.php.net/bug.php?id=45176&edit=1

Reply via email to