Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: OpenType Fonts support in CPAN

by talexb (Chancellor)
on Dec 10, 2007 at 14:51 UTC ( [id://656124]=note: print w/replies, xml ) Need Help??


in reply to OpenType Fonts support in CPAN

As a first guess, what does $img->font(..) return? I would check the return value amd see if there is any information there. I'd also like to see a test to prove that the font file exists.

Apart from that, does GD::Simple's code reveal anything more about the return value of the font method call? I suggest that since the man page doesn't reveal anything about the return code (bad form, IMO).

Alex / talexb / Toronto

"Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds

Replies are listed 'Best First'.
Re^2: OpenType Fonts support in CPAN
by sanPerl (Friar) on Dec 10, 2007 at 15:08 UTC
    Dear talexb
    Thanks for the reply. The real program is checking existance of font file before feeding to $img->font(...),when I say it dosen't work, it dosen't provide "Hello World" text with the requested Font on screen, inspite of font file being present in the location. It gives blank page
    I am trying to build a Font library for my company, where user will get sense of Font looks and he/she can order Font from the library. This is to take care of all licensing issues and to ensure if we can check all fonts anytime.

      OK, but what about the return code from the font method call? That's the very first place I'd look for information, with the next place being the module code.

      Alex / talexb / Toronto

      "Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds

        I just checked it with
        if ($img->font('C:\WINNT\aaaZemestrostd-bk.otf')) { print "Done"; };
        It returns prints "Done" even the file "C:\WINNT\aaaZemestrostd-bk.otf" dosen't exists. Also i checked with the documentation of GD::Simple, it says "The font to use when drawing text. Both built-in bitmapped fonts and TrueType fonts are supported". I am Not sure if built-in bitmapped fonts include OTF fonts (my knowldge in this subject is very limited)

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://656124]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (6)
As of 2024-04-23 21:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found