SDL::TTF::Font - Font object type for SDL_ttf
TTF, Structure
my $font = SDL::TTF::Font->new($font_file, $point_size); my $font = SDL::TTF::Font->new($font_file, $point_size, $face_index);
Load file for use as a font, at the given size. This can load TTF, OTF and FON files. You can specify the face index of a font file containing multiple faces.
Returns: a SDL::TTF::Font object. undef is returned on errors.
undef
Example:
use SDL::TTF::Font; my $font = SDL::TTF::Font->new('arial.ttf', 24);
See "AUTHORS" in SDL.
SDL::TTF
To install SDL, copy and paste the appropriate command in to your terminal.
cpanm
cpanm SDL
CPAN shell
perl -MCPAN -e shell install SDL
For more information on module installation, please visit the detailed CPAN module installation guide.