Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

errors in load_font.php #1

Open
schel4ok opened this issue Feb 11, 2017 · 3 comments
Open

errors in load_font.php #1

schel4ok opened this issue Feb 11, 2017 · 3 comments

Comments

@schel4ok
Copy link

I try to add cyrillic font to DOMPDF 0.7 but always errors.

First of all I had this when run load_font.php in command line

Fatal error: Uncaught exception 'Dompdf\Exception' with message 'Unable to read '/vendor/dompdf/dompdf/arialuni.ttf'.' in D:\OpenServer\domains\site.new\vendor\dompdf\dompdf\load_font.php:85
Stack trace:
#0 [internal function]: install_font_family(Object(Dompdf\Dompdf), 'Arialuni', '/vendor/dompdf/...')
#1 D:\OpenServer\domains\site.new\vendor\dompdf\dompdf\load_font.php(200): call_user_func_array('install_font_fa...', Array)
#2 {main}
  thrown in D:\OpenServer\domains\site.new\vendor\dompdf\dompdf\load_font.php on line 85

Then I go to autoload.inc.php and found that there is

require_once __DIR__ . '/lib/php-font-lib/src/FontLib/Autoloader.php';
require_once __DIR__ . '/lib/php-svg-lib/src/autoload.php';

But checking manually I didn't find these folders under lib

ё@OFFICE d:\OpenServer\domains\site.new\vendor\dompdf\dompdf\lib
> ls -a
.  ..  Cpdf.php  fonts  html5lib  res

Then I commented these lines, but one more error

> php load_font.php Arialuni arialuni.ttf
Unable to find bold face file.
Unable to find italic face file.
Unable to find bold_italic face file.
Copying arialuni.ttf to D:\OpenServer\domains\site.new\vendor\dompdf\dompdf\lib\fonts/arialuni.ttf...
Generating Adobe Font Metrics for D:\OpenServer\domains\site.new\vendor\dompdf\dompdf\lib\fonts/arialuni...

Fatal error: Class 'FontLib\Font' not found in D:\OpenServer\domains\site.new\vendor\dompdf\dompdf\load_font.php on line 153
@bsweeney
Copy link
Member

It looks like we need to update the script to appropriately handle Composer installations.

@HimakarPV
Copy link

HimakarPV commented Sep 16, 2017

@bsweeney Still this issue exists. I am using 0.8.1 version. May I know by which version this will fixed. Thankyou.

@bsweeney
Copy link
Member

I'll be addressing any outstanding issues in the utils project once I finalize the 0.8.1 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants