リビジョン | 79f4cd4e6836f4105968001e426498fbae6e7bfe (tree) |
---|---|
日時 | 2000-01-11 04:29:36 |
作者 | John Cristy <duc.sequere.aut.de.via.decede@gmai...> |
コミッター | John Cristy |
*** empty log message ***
@@ -27,7 +27,7 @@ | ||
27 | 27 | ++$test; |
28 | 28 | print("Draw text using font ...\n"); |
29 | 29 | $infile = 'input.ttf'; |
30 | -$md5 = '886fe1492fb466210e91566f5d314e04'; | |
30 | +$md5 = '729377f88d2dfcef65d2e07c1ea62274'; | |
31 | 31 | $md5_16 = 'df41d2a022b6b0cc79923a52ba33d834'; |
32 | 32 | |
33 | 33 | $image=Image::Magick->new; |
@@ -485,18 +485,13 @@ | ||
485 | 485 | } |
486 | 486 | TT_Get_Face_Properties(face,&face_properties); |
487 | 487 | TT_Get_Instance_Metrics(instance,&instance_metrics); |
488 | - canvas.width=2; | |
488 | + canvas.width=4; | |
489 | 489 | for (i=0; i < length; i++) |
490 | 490 | { |
491 | 491 | if (glyphs[unicode[i]].z == (TT_Glyph *) NULL) |
492 | 492 | continue; |
493 | 493 | TT_Get_Glyph_Metrics(glyphs[unicode[i]],&glyph_metrics); |
494 | - if (i == (length-1)) | |
495 | - { | |
496 | - canvas.width+=(glyph_metrics.bbox.xMin+glyph_metrics.bbox.xMax)/64; | |
497 | - continue; | |
498 | - } | |
499 | - canvas.width+=glyph_metrics.advance/64; | |
494 | + canvas.width+=(glyph_metrics.advance >> 6)+1; | |
500 | 495 | } |
501 | 496 | canvas.width=(canvas.width+3) & -4; |
502 | 497 | canvas.rows=instance_metrics.y_ppem*(face_properties.horizontal->Ascender- |
@@ -56,11 +56,6 @@ | ||
56 | 56 | #include "defines.h" |
57 | 57 | |
58 | 58 | #if defined(HasTTF) |
59 | -#if defined(HAVE_FREETYPE_FREETYPE_H) | |
60 | -#include "freetype/freetype.h" | |
61 | -#else | |
62 | -#include "freetype.h" | |
63 | -#endif | |
64 | 59 | /* |
65 | 60 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
66 | 61 | % % |