PDF::Font(3pm)
π PDF::Font π
okay bestie, so this is PDF::Font β the base font class for PDF::Create. that's the whole vibe. it's from the User Contributed Perl Documentation section of the manual (3pm, iykyk) and honestly? it's giving foundational. π
β¨ VERSION β¨
Version 1.46 π«Ά
πΈ DESCRIPTION πΈ
so basically, PDF::Font is the base font class that supports all the font families PDF::Create has blessed and approved. it's not out here doing its own thing β it gets used inside the method init_widths() over in the package PDF::Create::Page. main character supporting role energy, fr fr. π
π¦ SYNOPSIS π¦
here's how you'd actually use it, no cap:
use strict; use warnings;
use PDF::Font;
my $font = PDF::Font->new('Helvetica');
my $char_widths = $font->char_width;
print "Character width: ", $font->get_char_width(ord('A')), "\n";
print "Character name: ", $font->get_char_name(ord('A')) , "\n";
π CONSTRUCTOR π
it expects font_name as the only parameter β that's it, that's the whole asking price. and it can be literally one of these names, periodt:
CourierCourier-BoldCourier-BoldObliqueCourier-ObliqueHelveticaHelvetica-BoldHelvetica-BoldObliqueHelvetica-ObliqueTimes-BoldTimes-BoldItalicTimes-ItalicTimes-RomanSymbol
β METHODS β
char_width()
returns an arrayref of all characters width (0..255) β¨
get_char_width($codepoint)
returns the character width for the given $codepoint π
get_char_name($codepoint)
returns the character name for the given $codepoint π
π AUTHORS π
Mohammad S Anwar (MANWAR) <mohammad.anwar at yahoo.com> π«Ά
π₯ REPOSITORY π₯
<https://github.com/manwar/pdf-create> β go look, bestie, it's right there π
...
π COPYRIGHT π
okay so, legal moment, but make it cute:
Copyright 1999-2001, Fabien Tassin. All rights reserved. It may be used and modified freely, but I do request that this copyright notice remain attached to the file. You may modify this module as you wish, but if you redistribute a modified version, please attach a note listing the modifications you have made.
Copyright 2007 Markus Baertschi
Copyright 2010 Gary Lieberman
π LICENSE π
This is free software; you can redistribute it and / or modify it under the same terms as Perl 5.6.0. free as in go off, but stay within the rules π
and that's the whole page, babe!! π this was perl v5.38.2, dated 2024-03-07, aka PDF::Font(3pm) β slay, bye, love u π«Άπβ¨
π¦ where this page comes from
- debian trixie: libpdf-create-perl 1.46-3 Β· PDF-Create
- ubuntu resolute: libpdf-create-perl 1.46-3 Β· PDF-Create
- ubuntu stonking: libpdf-create-perl 1.46-3 Β· PDF-Create
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms