Open GoogleCodeExporter opened 8 years ago
[deleted comment]
traceback
Original comment by venmathi...@gmail.com
on 23 Apr 2014 at 12:18
Attachments:
First, remove any .pkl file hanging around that can have your development path
hardcoded in the cache temporary files where font metrics are stored.
If the problem persist, you could use a function like get_install_dir() that
returns the base path of your app:
https://code.google.com/p/pyafipws/source/browse/utils.py#751
Then you can try:
app_path = get_install_dir()
font_path = os.path.join(app_path, 'font')
pdf.add_font('DejaVuB','', os.path.join(font_path,
'DejaVuSans-Bold.ttf'),uni=True)
Make sure you're packaging the font folder with the ttf files)
Original comment by reingart@gmail.com
on 25 Apr 2014 at 9:47
btw, fpdf already has options for pkl managing, for example in portable or
readonly installations you can disable font caching.
More deatails here https://code.google.com/p/pyfpdf/wiki/AddFont
Original comment by romiq...@gmail.com
on 7 Jan 2015 at 12:12
Original issue reported on code.google.com by
venmathi...@gmail.com
on 23 Apr 2014 at 12:11Attachments: