summaryrefslogtreecommitdiff
path: root/tex
diff options
context:
space:
mode:
Diffstat (limited to 'tex')
-rw-r--r--tex/context/base/cont-new.mkii2
-rw-r--r--tex/context/base/cont-new.mkiv2
-rw-r--r--tex/context/base/context-version.pdfbin4095 -> 4092 bytes
-rw-r--r--tex/context/base/context-version.pngbin106555 -> 104764 bytes
-rw-r--r--tex/context/base/context.mkii2
-rw-r--r--tex/context/base/context.mkiv2
-rw-r--r--tex/context/base/lpdf-swf.lua66
-rw-r--r--tex/context/base/lpdf-wid.lua16
-rw-r--r--tex/context/base/scrn-fld.mkvi8
-rw-r--r--tex/context/base/status-files.pdfbin23872 -> 23873 bytes
-rw-r--r--tex/context/base/status-lua.pdfbin162212 -> 162210 bytes
-rw-r--r--tex/context/base/syst-aux.mkiv4
-rw-r--r--tex/generic/context/luatex/luatex-fonts-merged.lua2
13 files changed, 81 insertions, 23 deletions
diff --git a/tex/context/base/cont-new.mkii b/tex/context/base/cont-new.mkii
index cd2d9dc23..67293ba0e 100644
--- a/tex/context/base/cont-new.mkii
+++ b/tex/context/base/cont-new.mkii
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2011.08.19 15:44}
+\newcontextversion{2011.08.20 01:39}
%D This file is loaded at runtime, thereby providing an
%D excellent place for hacks, patches, extensions and new
diff --git a/tex/context/base/cont-new.mkiv b/tex/context/base/cont-new.mkiv
index 4126b4dba..419cde1d3 100644
--- a/tex/context/base/cont-new.mkiv
+++ b/tex/context/base/cont-new.mkiv
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2011.08.19 15:44}
+\newcontextversion{2011.08.20 01:39}
%D This file is loaded at runtime, thereby providing an
%D excellent place for hacks, patches, extensions and new
diff --git a/tex/context/base/context-version.pdf b/tex/context/base/context-version.pdf
index 0c9566b18..b8c6d79f7 100644
--- a/tex/context/base/context-version.pdf
+++ b/tex/context/base/context-version.pdf
Binary files differ
diff --git a/tex/context/base/context-version.png b/tex/context/base/context-version.png
index d8e17946a..99232f0ca 100644
--- a/tex/context/base/context-version.png
+++ b/tex/context/base/context-version.png
Binary files differ
diff --git a/tex/context/base/context.mkii b/tex/context/base/context.mkii
index 76b2bec18..78d85d19e 100644
--- a/tex/context/base/context.mkii
+++ b/tex/context/base/context.mkii
@@ -20,7 +20,7 @@
%D your styles an modules.
\edef\contextformat {\jobname}
-\edef\contextversion{2011.08.19 15:44}
+\edef\contextversion{2011.08.20 01:39}
%D For those who want to use this:
diff --git a/tex/context/base/context.mkiv b/tex/context/base/context.mkiv
index a8328dbe2..746d784d7 100644
--- a/tex/context/base/context.mkiv
+++ b/tex/context/base/context.mkiv
@@ -20,7 +20,7 @@
%D your styles an modules.
\edef\contextformat {\jobname}
-\edef\contextversion{2011.08.19 15:44}
+\edef\contextversion{2011.08.20 01:39}
%D For those who want to use this:
diff --git a/tex/context/base/lpdf-swf.lua b/tex/context/base/lpdf-swf.lua
index aadbbd639..c3e83dc69 100644
--- a/tex/context/base/lpdf-swf.lua
+++ b/tex/context/base/lpdf-swf.lua
@@ -30,6 +30,10 @@ local nodeinjections = backends.pdf.nodeinjections
local pdfannotation_node = nodes.pool.pdfannotation
+local trace_swf = false trackers.register("backend.swf", function(v) trace_swf = v end)
+
+local report_swf = logs.reporter("backend","swf")
+
local activations = {
click = "XA",
page = "PO",
@@ -87,27 +91,79 @@ local function insertswf(spec)
},
}
+ -- todo: check op subpath figuur (relatief)
+
if resources then
local names = configuration.Assets.Names
- local function add(filename)
+ local root = file.dirname(filename)
+ local prefix = format("^%s/",root)
+ local function add(filename,strip)
local filename = gsub(filename,"%./","")
- local embeddedreference = codeinjections.embedfile { file = filename, keepdir = true }
+ local usedname = strip and gsub(filename,prefix,"") -- always when relative
+ local embeddedreference = codeinjections.embedfile {
+ file = filename,
+ usedname = usedname,
+ keepdir = true,
+ }
names[#names+1] = pdfstring(filename)
names[#names+1] = embeddedreference
+ if trace_swf then
+ if usedname == filename then
+ report_swf("embedding file '%s'",filename)
+ else
+ report_swf("embedding file '%s' as '%s'",filename,usedname)
+ end
+ end
+ end
+ local relativepaths = resources.relativepaths
+ if relativepaths then
+ if trace_swf then
+ report_swf("checking %s relative paths",#relativepaths)
+ end
+ for i=1,#relativepaths do
+ local relativepath = relativepaths[i]
+ if trace_swf then
+ report_swf("checking path '%s' relative to '%s'",relativepath,root)
+ end
+ local path = file.join(root,relativepath)
+ local files = dir.glob(path .. "/**")
+ for i=1,#files do
+ add(files[i],true)
+ end
+ end
end
local paths = resources.paths
if paths then
+ if trace_swf then
+ report_swf("checking %s paths",#paths)
+ end
for i=1,#paths do
- local files = dir.glob(paths[i] .. "/**")
+ local path = paths[i]
+ if trace_swf then
+ report_swf("checking path '%s'",path)
+ end
+ local files = dir.glob(path .. "/**")
for i=1,#files do
- add(files[i])
+ add(files[i],false)
end
end
end
+ local relativefiles = resources.relativefiles
+ if relativefiles then
+ if trace_swf then
+ report_swf("checking %s relative files",#relativefiles)
+ end
+ for i=1,#relativefiles do
+ add(relativefiles[i],true)
+ end
+ end
local files = resources.files
if files then
+ if trace_swf then
+ report_swf("checking %s files",#files)
+ end
for i=1,#files do
- add(files[i])
+ add(files[i],false)
end
end
end
diff --git a/tex/context/base/lpdf-wid.lua b/tex/context/base/lpdf-wid.lua
index 2b1a241e6..0d73c56ba 100644
--- a/tex/context/base/lpdf-wid.lua
+++ b/tex/context/base/lpdf-wid.lua
@@ -200,12 +200,13 @@ end
lpdf.registerdocumentfinalizer(flushembeddedfiles,"embeddedfiles")
function codeinjections.embedfile(specification)
- local data = specification.data
- local filename = specification.file
- local name = specification.name or ""
- local title = specification.title or ""
- local hash = specification.hash or filename
- local keepdir = specification.keepdir -- can change
+ local data = specification.data
+ local filename = specification.file
+ local name = specification.name or ""
+ local title = specification.title or ""
+ local hash = specification.hash or filename
+ local keepdir = specification.keepdir -- can change
+ local usedname = specification.usedname
if filename == "" then
filename = nil
end
@@ -243,7 +244,8 @@ function codeinjections.embedfile(specification)
end
end
end
- local basename = keepdir == true and filename or file.basename(filename)
+ usedname = usedname ~= "" and usedname or filename
+ local basename = keepdir == true and usedname or file.basename(usedname)
local basename = gsub(basename,"%./","")
local savename = file.addsuffix(name ~= "" and name or basename,"txt") -- else no valid file
local a = pdfdictionary { Type = pdfconstant("EmbeddedFile") }
diff --git a/tex/context/base/scrn-fld.mkvi b/tex/context/base/scrn-fld.mkvi
index 6e4d6ba85..f296b6a55 100644
--- a/tex/context/base/scrn-fld.mkvi
+++ b/tex/context/base/scrn-fld.mkvi
@@ -165,7 +165,7 @@
\def\scrn_field_check_category
{\edef\currentfieldbodycategory{\fieldbodyparameter\c!category}%
\ifx\currentfieldbodycategory\empty
- letfieldbodyparameter\s!parent\??fd
+ \letfieldbodyparameter\s!parent\??fd
%\setevalue{\currentfieldbodyhash\s!parent}{\namedfieldcategoryhash\empty}% to WS: not hash !
\else
\normalexpanded{\setfieldbodyparameter{\s!parent}{\??fd\currentfieldbodycategory}}%
@@ -398,7 +398,7 @@
\setupfieldcontentframed
[\c!align=\v!flushleft,
\c!strut=\v!no,
- \s!parent=\??ol]
+ \s!parent=\??ol] % needs checking
\setupfieldcontentframed % independent
[\c!alternative=\v!normal,
@@ -414,13 +414,13 @@
[\c!style=,
\c!color=,
\c!align=\v!flushleft,
- \s!parent=\??ol]
+ \s!parent=\??ol] % needs checking
\setupfieldtotalframed
[%\c!alternative={\v!label,\v!frame,\v!horizontal},
\c!strut=\v!no,
\c!align=,
- \s!parent=\??ol]
+ \s!parent=\??ol] % needs checking
% \setupcurrent
diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf
index a5ed9b1f8..02c9c5bc9 100644
--- a/tex/context/base/status-files.pdf
+++ b/tex/context/base/status-files.pdf
Binary files differ
diff --git a/tex/context/base/status-lua.pdf b/tex/context/base/status-lua.pdf
index 10b93574c..b24a70205 100644
--- a/tex/context/base/status-lua.pdf
+++ b/tex/context/base/status-lua.pdf
Binary files differ
diff --git a/tex/context/base/syst-aux.mkiv b/tex/context/base/syst-aux.mkiv
index 1aae19ee1..571ca05b9 100644
--- a/tex/context/base/syst-aux.mkiv
+++ b/tex/context/base/syst-aux.mkiv
@@ -1196,8 +1196,8 @@
%D complicated arguments, for instance arguments that
%D consist of two or more expandable tokens.
-\def\getfirstcharacter #1{\ctxcommand{getfirstcharacter(\!!bs#1\e!!es)}}
-\def\doiffirstcharelse#1#2{\ctxcommand{doiffirstcharelse(\!!bs#1\e!!es,\!!bs#2\e!!es)}} % chr str
+\def\getfirstcharacter #1{\ctxcommand{getfirstcharacter(\!!bs#1\!!es)}}
+\def\doiffirstcharelse#1#2{\ctxcommand{doiffirstcharelse(\!!bs#1\!!es,\!!bs#2\!!es)}} % chr str
%D \macros
%D {doifinstringelse, doifincsnameelse}
diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua
index 39891c656..432a83a8d 100644
--- a/tex/generic/context/luatex/luatex-fonts-merged.lua
+++ b/tex/generic/context/luatex/luatex-fonts-merged.lua
@@ -1,6 +1,6 @@
-- merged file : luatex-fonts-merged.lua
-- parent file : luatex-fonts.lua
--- merge date : 08/19/11 15:44:39
+-- merge date : 08/20/11 01:39:23
do -- begin closure to overcome local limits and interference