Revision 3019,
1.2 KB
checked in by amuller, 14 years ago
(diff) |
Ticket #1135 - Corrigindo CSS e adicionando filemanager
|
Rev | Line | |
---|
[3019] | 1 | To embed TrueType fonts (.TTF) files, you need to extract the font metrics and
|
---|
| 2 | build the required tables using the provided utility (/fonts/ttf2ufm).
|
---|
| 3 |
|
---|
| 4 | TTF2UFM is a modified version of Mark Heath's TTF 2 PT1 converter
|
---|
| 5 | (http://ttf2pt1.sourceforge.net/) by Steven Wittens <steven@acko.net>
|
---|
| 6 | (http://www.acko.net/blog/ufpdf). ttf2ufm, is included in /ttf2ufm-src.
|
---|
| 7 | The /fonts/ttf2ufm folder contains a compiled Windows binary.
|
---|
| 8 | TTF 2 UFM is identical to TTF 2 PT1 except that it also generates a .ufm file
|
---|
| 9 | for usage with makefontuni.php.
|
---|
| 10 |
|
---|
| 11 |
|
---|
| 12 | Setting up a Truetype font for usage with TCPDF:
|
---|
| 13 | 1) Generate the font's .ufm metrics file by processing it with the provided
|
---|
| 14 | ttf2ufm program (modified ttf2pt1). For example:
|
---|
| 15 | $ ttf2ufm -a -F myfont.ttf
|
---|
| 16 | 2) Run makefontuni.php with the .ttf and .ufm filenames as argument:
|
---|
| 17 | $ php -q makefontuni.php myfont.ttf myfont.ufm
|
---|
| 18 | 3) Copy the resulting .php, .z and .ctg.z file to the TCPDF font directory.
|
---|
| 19 | 4) Rename php font files variations for bold and italic using the following schema:
|
---|
| 20 | [basic-font-name]b.php for bold variation
|
---|
| 21 | [basic-font-name]i.php for oblique variation
|
---|
| 22 | [basic-font-name]bi.php for bold oblique variation
|
---|
| 23 | 5) Convert all fonts filenames to lowercase.
|
---|
| 24 | |
---|
Note: See
TracBrowser
for help on using the repository browser.