summaryrefslogtreecommitdiff
path: root/tex/context/base/lxml-tab.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2009-10-19 14:43:00 +0200
committerHans Hagen <pragma@wxs.nl>2009-10-19 14:43:00 +0200
commite95ec93b5fe70c7d0e16071a1df8777cb9289d3b (patch)
tree3ea17776ea748226d95e52b420a5f30394e2d1eb /tex/context/base/lxml-tab.lua
parentea36ada779b87db193b865429d5db510713038a4 (diff)
downloadcontext-e95ec93b5fe70c7d0e16071a1df8777cb9289d3b.tar.gz
beta 2009.10.19 14:43
Diffstat (limited to 'tex/context/base/lxml-tab.lua')
-rw-r--r--tex/context/base/lxml-tab.lua10
1 files changed, 10 insertions, 0 deletions
diff --git a/tex/context/base/lxml-tab.lua b/tex/context/base/lxml-tab.lua
index faafa4462..15ed7a26f 100644
--- a/tex/context/base/lxml-tab.lua
+++ b/tex/context/base/lxml-tab.lua
@@ -960,6 +960,16 @@ function xml.content(root) -- bugged
return (root and root.dt and xml.tostring(root.dt)) or ""
end
+function xml.name(root)
+ if not root then
+ return ""
+ elseif root.ns == "" then
+ return root.tg
+ else
+ return root.ns .. ":" .. root.tg
+ end
+end
+
--[[ldx--
<p>The next helper erases an element but keeps the table as it is,
and since empty strings are not serialized (effectively) it does