pdf_findfont -- Prepare font for later use with pdf_setfont().
Description
int pdf_findfont ( resource pdfdoc, string fontname, string encoding [, int embed])
Prepare a font for later use with pdf_setfont(). The metrics will be loaded, and if embed is nonzero, the font file will be checked, but not yet used. encoding is one of builtin, macroman, winansi, host, a user-defined encoding name or the name of a CMap.
pdf_findfont() returns a font handle or FALSE on error.
Example 1. pdf_findfont() example
<?php
$font = pdf_findfont($pdf, "Times New Roman", "winansi", 1); if ($font) { pdf_setfont($pdf, $font, 10); }
Deliver First Class Web Sites: 101 Essential Checklists Want to learn how to make your web sites usable and accessible? Want to ensure that your sites meet current best practice, without spending hours trawling through incomprehensible specifications and recommendations from dozens of different books, research papers, and web sites? Want to make sure that the sites you build are "right the first time," requiring no costly redevelopments?