summaryrefslogtreecommitdiff
path: root/tex/context/base/typo-dua.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/typo-dua.lua')
-rw-r--r--tex/context/base/typo-dua.lua19
1 files changed, 14 insertions, 5 deletions
diff --git a/tex/context/base/typo-dua.lua b/tex/context/base/typo-dua.lua
index 91a27a30e..73b00f033 100644
--- a/tex/context/base/typo-dua.lua
+++ b/tex/context/base/typo-dua.lua
@@ -80,6 +80,7 @@ local getfield = nuts.getfield
local setfield = nuts.setfield
local remove_node = nuts.remove
+local copy_node = nuts.copy
local insert_node_after = nuts.insert_after
local insert_node_before = nuts.insert_before
@@ -106,7 +107,7 @@ local maximum_stack = 60 -- probably spec but not needed
local directions = typesetters.directions
local setcolor = directions.setcolor
-local a_directions = attributes.private('directions')
+----- a_directions = attributes.private('directions')
local remove_controls = true directives.register("typesetters.directions.one.removecontrols",function(v) remove_controls = v end)
@@ -708,20 +709,26 @@ local function apply_to_list(list,size,head,pardir)
elseif id == glue_code then
if enddir and getsubtype(current) == parfillskip_code then
-- insert the last enddir before \parfillskip glue
- head = insert_node_before(head,current,new_textdir(enddir))
+ local d = new_textdir(enddir)
+-- setfield(d,"attr",copy_node(getfield(current,"attr")))
+ head = insert_node_before(head,current,d)
enddir = false
done = true
end
elseif id == whatsit_code then
if begindir and getsubtype(current) == localpar_code then
-- local_par should always be the 1st node
- head, current = insert_node_after(head,current,new_textdir(begindir))
+ local d = new_textdir(begindir)
+-- setfield(d,"attr",copy_node(getfield(current,"attr")))
+ head, current = insert_node_after(head,current,d)
begindir = nil
done = true
end
end
if begindir then
- head = insert_node_before(head,current,new_textdir(begindir))
+ local d = new_textdir(begindir)
+-- setfield(d,"attr",copy_node(getfield(current,"attr")))
+ head = insert_node_before(head,current,d)
done = true
end
local skip = entry.skip
@@ -731,7 +738,9 @@ local function apply_to_list(list,size,head,pardir)
end
end
if enddir then
- head, current = insert_node_after(head,current,new_textdir(enddir))
+ local d = new_textdir(enddir)
+-- setfield(d,"attr",copy_node(getfield(current,"attr")))
+ head, current = insert_node_after(head,current,d)
done = true
end
if not entry.remove then