|
To my findings the real big thing in the dompdf fonts folder provided by Xlinesoft is the font file arialuni.ttf This one file alone is 22731 KB heavy. So I deleted that and edited dompdf_font_family_cache.dist.php to
<?php return array (
/* 'arial' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/arialuni',
'bold' => DOMPDF_DIR . '/lib/fonts/arialb',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/arialbi',
'italic' => DOMPDF_DIR . '/lib/fonts/ariali',
),*/
'glyphicons halflings' =>
array (
'normal' => DOMPDF_FONT_DIR . '/lib/fonts/glyphicons-halflings-regular',
),
'Source Sans Pro' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/arial',
'bold' => DOMPDF_DIR . '/lib/fonts/arialb',
'italic' => DOMPDF_DIR . '/lib/fonts/ariali',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/arialbi',
),
'Calibri' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/arial',
'bold' => DOMPDF_DIR . '/lib/fonts/arialb',
'italic' => DOMPDF_DIR . '/lib/fonts/ariali',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/arialbi',
),
'Candara' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/arial',
'bold' => DOMPDF_DIR . '/lib/fonts/arialb',
'italic' => DOMPDF_DIR . '/lib/fonts/ariali',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/arialbi',
),
'arial' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/arial',
'bold' => DOMPDF_DIR . '/lib/fonts/arialb',
'italic' => DOMPDF_DIR . '/lib/fonts/ariali',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/arialbi',
),
'sans-serif' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Helvetica',
'bold' => DOMPDF_DIR . '/lib/fonts/Helvetica-Bold',
'italic' => DOMPDF_DIR . '/lib/fonts/Helvetica-Oblique',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Helvetica-BoldOblique',
),
'times' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Times-Roman',
'bold' => DOMPDF_DIR . '/lib/fonts/Times-Bold',
'italic' => DOMPDF_DIR . '/lib/fonts/Times-Italic',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Times-BoldItalic',
),
'times-roman' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Times-Roman',
'bold' => DOMPDF_DIR . '/lib/fonts/Times-Bold',
'italic' => DOMPDF_DIR . '/lib/fonts/Times-Italic',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Times-BoldItalic',
),
'courier' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Courier',
'bold' => DOMPDF_DIR . '/lib/fonts/Courier-Bold',
'italic' => DOMPDF_DIR . '/lib/fonts/Courier-Oblique',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Courier-BoldOblique',
),
'helvetica' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Helvetica',
'bold' => DOMPDF_DIR . '/lib/fonts/Helvetica-Bold',
'italic' => DOMPDF_DIR . '/lib/fonts/Helvetica-Oblique',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Helvetica-BoldOblique',
),
'zapfdingbats' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/ZapfDingbats',
'bold' => DOMPDF_DIR . '/lib/fonts/ZapfDingbats',
'italic' => DOMPDF_DIR . '/lib/fonts/ZapfDingbats',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/ZapfDingbats',
),
'symbol' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Symbol',
'bold' => DOMPDF_DIR . '/lib/fonts/Symbol',
'italic' => DOMPDF_DIR . '/lib/fonts/Symbol',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Symbol',
),
'serif' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Times-Roman',
'bold' => DOMPDF_DIR . '/lib/fonts/Times-Bold',
'italic' => DOMPDF_DIR . '/lib/fonts/Times-Italic',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Times-BoldItalic',
),
'monospace' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Courier',
'bold' => DOMPDF_DIR . '/lib/fonts/Courier-Bold',
'italic' => DOMPDF_DIR . '/lib/fonts/Courier-Oblique',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Courier-BoldOblique',
),
'fixed' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/Courier',
'bold' => DOMPDF_DIR . '/lib/fonts/Courier-Bold',
'italic' => DOMPDF_DIR . '/lib/fonts/Courier-Oblique',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/Courier-BoldOblique',
),
'dejavu sans' =>
array (
'bold' => DOMPDF_DIR . '/lib/fonts/DejaVuSans-Bold',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSans-BoldOblique',
'italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSans-Oblique',
'normal' => DOMPDF_DIR . '/lib/fonts/DejaVuSans',
) ,
'dejavu sans light' =>
array (
'normal' => DOMPDF_DIR . '/lib/fonts/DejaVuSans-ExtraLight',
),
'dejavu sans condensed' =>
array (
'bold' => DOMPDF_DIR . '/lib/fonts/DejaVuSansCondensed-Bold',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSansCondensed-BoldOblique',
'italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSansCondensed-Oblique',
'normal' => DOMPDF_DIR . '/lib/fonts/DejaVuSansCondensed',
),
'dejavu sans mono' =>
array (
'bold' => DOMPDF_DIR . '/lib/fonts/DejaVuSansMono-Bold',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSansMono-BoldOblique',
'italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSansMono-Oblique',
'normal' => DOMPDF_DIR . '/lib/fonts/DejaVuSansMono',
),
'dejavu serif' =>
array (
'bold' => DOMPDF_DIR . '/lib/fonts/DejaVuSerif-Bold',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSerif-BoldItalic',
'italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSerif-Italic',
'normal' => DOMPDF_DIR . '/lib/fonts/DejaVuSerif',
),
'dejavu serif condensed' =>
array (
'bold' => DOMPDF_DIR . '/lib/fonts/DejaVuSerifCondensed-Bold',
'bold_italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSerifCondensed-BoldItalic',
'italic' => DOMPDF_DIR . '/lib/fonts/DejaVuSerifCondensed-Italic',
'normal' => DOMPDF_DIR . '/lib/fonts/DejaVuSerifCondensed',
),
) ?> plus I out-commented
define("DOMPDF_DEFAULT_FONT", "arial"); in dompdf_config.custom.inc.php This way everything works without any error messages and my upload is >20 MB lighter, which makes between 50 and 30% of my whole upload :-) Only problem that persists currently is, that the headers aren´t printed to PDF with a sans serif font, but with Times, which looks a bit funny. Any ideas?
|