diff options
Diffstat (limited to 'Master/texmf-dist/tex/context/base/page-flt.lua')
-rw-r--r-- | Master/texmf-dist/tex/context/base/page-flt.lua | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/Master/texmf-dist/tex/context/base/page-flt.lua b/Master/texmf-dist/tex/context/base/page-flt.lua index ecd7004ae9f..68383f175f9 100644 --- a/Master/texmf-dist/tex/context/base/page-flt.lua +++ b/Master/texmf-dist/tex/context/base/page-flt.lua @@ -112,12 +112,12 @@ function floats.save(which,data) insert(stack,t) setcount("global","savednoffloats",#stacks[default]) if trace_floats then - report_floats("saving %s float %s in slot %s (%i,%i,%i)",which,noffloats,#stack,w,h,d) + report_floats("%s, category %a, number %a, slot %a, width %p, height %p, depth %p","saving",which,noffloats,#stack,w,h,d) else interfaces.showmessage("floatblocks",2,noffloats) end else - report_floats("unable to save %s float %s (empty)",which,noffloats) + report_floats("ignoring empty, category %a, number %a",which,noffloats) end end @@ -132,7 +132,7 @@ function floats.resave(which) insert(stack,1,last) setcount("global","savednoffloats",#stacks[default]) if trace_floats then - report_floats("resaving %s float %s in slot %s (%i,%i,%i)",which,noffloats,#stack,w,h,d) + report_floats("%s, category %a, number %a, slot %a width %p, height %p, depth %p","resaving",which,noffloats,#stack,w,h,d) else interfaces.showmessage("floatblocks",2,noffloats) end @@ -148,7 +148,7 @@ function floats.flush(which,n,bylabel) if t then local w, h, d = setdimensions(b) if trace_floats then - report_floats("flushing %s float %s from slot %s (%i,%i,%i)",which,t.n,n,w,h,d) + report_floats("%s, category %a, number %a, slot %a width %p, height %p, depth %p","flushing",which,t.n,n,w,h,d) else interfaces.showmessage("floatblocks",3,t.n) end @@ -168,7 +168,7 @@ function floats.consult(which,n) if t then local w, h, d = setdimensions(b) if trace_floats then - report_floats("consulting %s float %s in slot %s (%i,%i,%i)",which,t.n,n,w,h,d) + report_floats("%s, category %a, number %a, slot %a width %p, height %p, depth %p","consulting",which,t.n,n,w,h,d) end return t, b, n else @@ -243,11 +243,10 @@ local label = P(":") * C((1-S(",*: "))^0) local pattern = method * ( label * position + C("") * position - + label + + label * C("") * C("") + C("") * C("") * C("") ) + C("") * C("") * C("") * C("") - -- inspect { lpegmatch(pattern,"somewhere:blabla,crap") } -- inspect { lpegmatch(pattern,"somewhere:1*2") } -- inspect { lpegmatch(pattern,"somewhere:blabla:1*2") } @@ -262,6 +261,9 @@ end -- interface +local context = context +local setvalue = context.setvalue + commands.flushfloat = floats.flush commands.savefloat = floats.save commands.resavefloat = floats.resave @@ -278,8 +280,8 @@ function commands.doifelsesavedfloat(...) commands.doifelse(floats.nofstacked(.. function commands.analysefloatmethod(str) local method, label, row, column = floats.analysemethod(str) - context.setvalue("floatmethod",method) - context.setvalue("floatlabel", label ) - context.setvalue("floatrow", row ) - context.setvalue("floatcolumn",column) + setvalue("floatmethod",method) + setvalue("floatlabel", label ) + setvalue("floatrow", row ) + setvalue("floatcolumn",column) end |