Hi All
I have been struggling to do a task in Perl for a while, and would appreciate any help or tips. I have searched endlessly for some code snippets or examples, I haven't found the module documentation much help.
What I am trying to do is simply create a .png with a number, specified by my perl program:
e.g.
$number = 223;
use GD;
use GD::Text;
$gd_text = GD::Text->new(
text => $number,
font => 'verdana.ttf',
ptsize => 14,
);
I really have no idea how to actually output the data, I have tried everything form BINMODE $gd_text to trying to put the $gd_text into a GD new subroutine..
Any help would be fantastic, thank you
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.