ID:               34670
 User updated by:  klaus at glashoff dot net
 Reported By:      klaus at glashoff dot net
-Status:           Feedback
+Status:           Open
 Bug Type:         GD related
 Operating System: Windows XP
 PHP Version:      5.0.5
 Assigned To:      pajoye
 New Comment:

1. The font can be downloaded from 
http://www.omkarananda-ashram.org/Sanskrit/itranslator2003.htm#dls

2. The expected result may be generated by any browser which can deal
with the Unicode sequence I gave: क्&2340;  What you will
see (if an appropriate font has been installed) is a single glyph which
is a conjunct of the glyph for "k" (&#2325) and "t" (&#2340).

3. The different results (text from the browser or image) may be seen
on my testpage
http://leuchtraum.de/translation/test/devatest.php?text=kt
Please see also the source of the page. 
Try also input of "krtsna" or other conjuncts. (This test page is not
perfect but hopefully sufficient to show the problem).

4. The Unicode directives for Devanagari are given in
http://www.unicode.org/versions/Unicode4.0.0/ch09.pdf
Table 9.2 on p. 229 is of relevance; also the pages before.


Previous Comments:
------------------------------------------------------------------------

[2005-09-28 12:49:26] [EMAIL PROTECTED]

Please provide links to:
- the font you use (Sanskrit2003.ttf)
  or are you using the font from www.omkarananda-ashram.org?
 
- expected results (using another program if required)
  as images

- actual result as images



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

[2005-09-28 11:50:56] klaus at glashoff dot net

Description:
------------
The results of imagettftext() are - at least for Indian languages - not
totally satisfying:  Consonant conjuncts appear as two consonants with
virama.  In order to display "kta" in Devanagari, imagettftext, for
example,  when given the argument " k + virama + t"
(क्त) should return the conjunct for "kt", but it
does not.

(Instead of the font Sanskrit2003.ttf, use any Unicode font containing
U+0900 - U+097F; for example mangal.ttf).



Reproduce code:
---------------
<?php
Header ("Content-type: image/png");
$string ="&#2325;&#2381;&#2340;";
$string=rawurldecode($string);
$im =  imagecreate (200, 25);
$white = ImageColorAllocate ($im,224,224,224);
$black = ImageColorAllocate ($im,50,100,100);

ImageTTFText ($im, 12, 0, 5, 15, $black, "Sanskrit2003.ttf", $string);
ImagePng ($im);
ImageDestroy ($im);
?>

Expected result:
----------------
The Devanagari conjunct glyph for "kt" should appear, not a separate
"k" with virama sign &#2381.



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


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

Reply via email to