summaryrefslogtreecommitdiff
path: root/tex/context/base/typo-pag.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2014-06-25 19:46:00 +0200
committerHans Hagen <pragma@wxs.nl>2014-06-25 19:46:00 +0200
commit1b5137f5fffe265b044838d6ee87d27070902180 (patch)
tree1282944b13996aa6aad9bd2800fbbff1bdae9f86 /tex/context/base/typo-pag.lua
parenta9c288d372917c485a2882593ed18c8044bf82f1 (diff)
downloadcontext-1b5137f5fffe265b044838d6ee87d27070902180.tar.gz
beta 2014.06.25 19:46
Diffstat (limited to 'tex/context/base/typo-pag.lua')
-rw-r--r--tex/context/base/typo-pag.lua23
1 files changed, 12 insertions, 11 deletions
diff --git a/tex/context/base/typo-pag.lua b/tex/context/base/typo-pag.lua
index 5b96e9c21..53f79fcfc 100644
--- a/tex/context/base/typo-pag.lua
+++ b/tex/context/base/typo-pag.lua
@@ -52,6 +52,9 @@ trackers.register("parbuilders.keeptogether", function(v) trace_keeptogether =
-- when no hlists are there ? ... maybe the local_par
function parbuilders.registertogether(line,specification) -- might change
+ if not specification then
+ return
+ end
if not enabled then
nodes.tasks.enableaction("finalizers","builders.paragraphs.keeptogether")
end
@@ -87,18 +90,16 @@ function parbuilders.registertogether(line,specification) -- might change
if trace_keeptogether then
local a = a or last
local c = cache[a]
- if trace_keeptogether then
- local noflines = specification.lineheight
- local height = c.height
- local depth = c.depth
- local slack = c.slack
- if not noflines or noflines == 0 then
- noflines = "unknown"
- else
- noflines = math.round((height + depth - slack) / noflines)
- end
- report_keeptogether("registered, index %s, height %p, depth %p, slack %p, noflines %a",a,height,depth,slack,noflines)
+ local noflines = specification.lineheight
+ local height = c.height
+ local depth = c.depth
+ local slack = c.slack
+ if not noflines or noflines == 0 then
+ noflines = "unknown"
+ else
+ noflines = math.round((height + depth - slack) / noflines)
end
+ report_keeptogether("registered, index %s, height %p, depth %p, slack %p, noflines %a",a,height,depth,slack,noflines)
end
end