Commit b71b1b3e16e66de08c0549226a9b4df923690772

Authored by Brian Manning
1 parent 7763e2ca33
Exists in master

pdflib_demo: added font search path config directive

Showing 1 changed file with 5 additions and 0 deletions Side-by-side Diff

... ... @@ -43,6 +43,11 @@
43 43 // set up some PDFlib options
44 44 $pdf->set_option("errorpolicy=return");
45 45 $pdf->set_option("stringformat=utf8");
  46 + // all paths in 'searchpath' need to be inside curly braces
  47 + // multiple curly-braced paths in $searchpath need to be separated with
  48 + // space characters
  49 + $searchpath = '{/usr/share/fonts/dejavu/}';
  50 + $pdf->set_option("searchpath={" . $searchpath . "}");
46 51  
47 52 if ($pdf->begin_document($outfile, "") == 0)
48 53 throw new Exception("Error: " . $pdf->get_errmsg());