summaryrefslogtreecommitdiff
path: root/tex/context/base/mkxl/math-noa.lmt
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2022-10-15 12:19:43 +0200
committerContext Git Mirror Bot <phg@phi-gamma.net>2022-10-15 12:19:43 +0200
commitc0c1dea1daf21f2c21f6d8094f54f67138998baf (patch)
tree1c9ea4021dd831004eaa41cb4bef34798fae7f46 /tex/context/base/mkxl/math-noa.lmt
parent0aa93a6d31a45d8df2d8516567b98967ce04f183 (diff)
downloadcontext-c0c1dea1daf21f2c21f6d8094f54f67138998baf.tar.gz
2022-10-15 10:34:00
Diffstat (limited to 'tex/context/base/mkxl/math-noa.lmt')
-rw-r--r--tex/context/base/mkxl/math-noa.lmt11
1 files changed, 7 insertions, 4 deletions
diff --git a/tex/context/base/mkxl/math-noa.lmt b/tex/context/base/mkxl/math-noa.lmt
index 30b7b0448..a53810437 100644
--- a/tex/context/base/mkxl/math-noa.lmt
+++ b/tex/context/base/mkxl/math-noa.lmt
@@ -2469,7 +2469,6 @@ do
local traversehlist = nuts.traversers.hlist
local texgetdimen = tex.getdimen
- local texgetglue = tex.getglue
local texgetcount = tex.getcount
local newrule = nuts.pool.outlinerule
@@ -2478,12 +2477,16 @@ do
local a_mathsnap = attributes.private("mathsnap")
+ local d_mathstrutht = tex.isdimen("mathstrutht")
+ local d_mathstrutdp = tex.isdimen("mathstrutdp")
+ local c_mathnesting = tex.iscount("mathnestinglevel")
+
local trace_snapping = false registertracker("math.snapping", function(v) trace_snapping = v end)
local report_snapping = logreporter("mathematics","snapping")
function handlers.snap(h,_,_,_,_,level)
-- if not level or level == 0 then
- if texgetcount("mathnestinglevel") == 1 then
+ if texgetcount(c_mathnesting) == 1 then
local trace_color
if trace_snapping == "frame" then
trace_color = "darkgray"
@@ -2498,8 +2501,8 @@ do
if step then
local done = false
if not dd then
- ht = texgetdimen("mathstrutht")
- dp = texgetdimen("mathstrutdp")
+ ht = texgetdimen(d_mathstrutht)
+ dp = texgetdimen(d_mathstrutdp)
hd = ht + dp
-- lineskip can be large in alignments
-- dd = hd / 12