in reply to Re^3: PDF::API2 font
in thread PDF::API2 font

I was using 'evince' to open the created pdf. As I told earlier, it was immediately closing then itself. In the terminal it showed the error "Error: Mismatch between font type and embedded font file". When I am opening it in Adobe Reader, it opens fine. No problem at all.

Thank you.

Replies are listed 'Best First'.
Re^5: PDF::API2 font
by shibu_pu (Acolyte) on Nov 07, 2009 at 05:21 UTC
    I am using

    PDF::API2::addFontDirs('home/username/fonts');

    my $font = $pdf->ttfont('myfont.ttf');
    $text->font($font, 14);
    $text->translate(300, 480);
    $text->text('HELLO WORLD!');

    I used different fonts as 'myfont'. But all times, the text displayed is very much expanded horizontally. Lot of space between the characters.
    Is there any options to be given to solve this problem?