[scribus] Font::TTFMetrics error - font metrics
andrew james
andrew at systemssingular.com
Fri Nov 6 05:59:39 CET 2009
Malay,
Though you had not responded, I continued to try solutions to the
problem. The one variant was the font. The file georgia.ttf returns
values, though I have not decoded font-units for my use, no errors.
georgia.ttf is attached.
As your program is dated 2003, I think you may have concern to know that
some fonts err. I attached the file DejaVuSerif.ttf that errs as
described pre.
I suggest the cause is some untested fonts are in code that defies your
programs algorithms.
If you please, state your intent to maintain your code. Explain briefly
details to the error for font DejaVuSerif.ttf. Perhaps someone else
will maintain the code, that others may use more fully.
For example, project scribus has multiple request for functions that
measure fonts.
Attached is the example-character-width.pl perl program that works to
calculate the width of character 'a' font georgia.ttf
regard,
Andrew
andrew james wrote:
> Malay, Hi
>
> Thank you for what may work as a useful program, if you will help me
> solve a problem.
>
> I want to use the module perl Font::TTFMetrics that you wrote.
>
> I wanted to calculate some character widths, but when I copied your
> examples, at the constructor the program failed. Even code this short
> errs ...
>
> ----
>
> #!/usr/bin/perl
> use strict;
> use warnings;
> use Font::TTFMetrics;
>
> my $metrics = Font::TTFMetrics->new("DejaVuSerif.ttf");
>
> ----
>
> The error is, negative length at .../TTFMetrics.pm line 634
>
> regards,
> Andrew
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: DejaVuSerif.ttf
Type: application/octet-stream
Size: 328908 bytes
Desc: not available
URL: <http://lists.scribus.net/pipermail/scribus/attachments/20091105/af173eb4/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: georgia.ttf
Type: application/octet-stream
Size: 142964 bytes
Desc: not available
URL: <http://lists.scribus.net/pipermail/scribus/attachments/20091105/af173eb4/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: example-character-width.pl
Type: text/x-perl
Size: 575 bytes
Desc: not available
URL: <http://lists.scribus.net/pipermail/scribus/attachments/20091105/af173eb4/attachment.pl>
More information about the scribus
mailing list