X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=blobdiff_plain;f=lib%2Fdevices%2Fpdf.c;h=1e0d6a8b829cfc3041758ee56c947cca617aa3c7;hp=3183ce85042df0b17b7d7fa68b31427678ab3196;hb=df102d603f84e64cfd36aef0fddcf70fafac7ee2;hpb=405f7bcba3314e746fd3893565bd77d775f6547a diff --git a/lib/devices/pdf.c b/lib/devices/pdf.c index 3183ce8..1e0d6a8 100644 --- a/lib/devices/pdf.c +++ b/lib/devices/pdf.c @@ -389,10 +389,11 @@ void pdf_addfont(gfxdevice_t*dev, gfxfont_t*font) for(t=0;tglyphs[t].unicode = 32+t; } + font->max_unicode = 0; font->unicode2glyph = 0; gfxfont_save(font, filename); font->id=old_id; - + #ifdef RUN_TTX /* for testing the generated fonts: run everything through ttx (fonttools) */ char cmd[256]; @@ -404,13 +405,15 @@ void pdf_addfont(gfxdevice_t*dev, gfxfont_t*font) sprintf(cmd, "rm -f test.ttx");system(cmd); #endif - int l = strlen(font->id); + int l = strlen(fontname); for(t=0;tp, fontname2, l*2, "host", "embedding=true"); i->fontlist = gfxfontlist_addfont2(i->fontlist, font, (void*)(ptroff_t)fontid); + unlink(filename); } } }