diff options
author | Hans Hagen <pragma@wxs.nl> | 2018-07-05 23:56:28 +0200 |
---|---|---|
committer | Context Git Mirror Bot <phg42.2a@gmail.com> | 2018-07-05 23:56:28 +0200 |
commit | d6dece4edc2ef86889f99f3dbe5a6d6ed3b68b02 (patch) | |
tree | c1469b80be7520b9f2159390f9a8106216086997 /tex/context/base/mkiv/font-ocl.lua | |
parent | 847821faaecf92833f1e1564e1ef9377758d4d45 (diff) | |
download | context-d6dece4edc2ef86889f99f3dbe5a6d6ed3b68b02.tar.gz |
2018-07-05 23:13:00
Diffstat (limited to 'tex/context/base/mkiv/font-ocl.lua')
-rw-r--r-- | tex/context/base/mkiv/font-ocl.lua | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/tex/context/base/mkiv/font-ocl.lua b/tex/context/base/mkiv/font-ocl.lua index fcafe99ed..fc9953d88 100644 --- a/tex/context/base/mkiv/font-ocl.lua +++ b/tex/context/base/mkiv/font-ocl.lua @@ -341,15 +341,15 @@ do else - -- todo: bypass backend and directly inject xforms - local openpdf = pdfe.new + ----- prefix = "data:application/pdf," function otf.storepdfdata(pdf) local done = hashed[pdf] if not done then nofstreams = nofstreams + 1 - local n = openpdf(pdf,#pdf,f_name(nofstreams)) + local f = f_name(nofstreams) + local n = openpdf(pdf,#pdf,f) done = f_used(n) hashed[pdf] = done end @@ -436,6 +436,8 @@ local function pdftovirtual(tfmdata,pdfshapes,kind) -- kind = sbix|svg dy = 0 end if data then + -- We can delay storage by a lua function in commands: but then we need to + -- be able to provide our own mem stream name (so that we can reserve it). local setcode, name, nilcode = storepdfdata(data) if name then local bt = unicode and getactualtext(unicode) @@ -459,8 +461,8 @@ local function pdftovirtual(tfmdata,pdfshapes,kind) -- kind = sbix|svg end local otfsvg = otf.svg or { } -otf.svg = otfsvg -otf.svgenabled = true +otf.svg = otfsvg +otf.svgenabled = true do |