diff options
Diffstat (limited to 'Master/texmf-dist/tex/context/base/mkiv/strc-ren.mkiv')
-rw-r--r-- | Master/texmf-dist/tex/context/base/mkiv/strc-ren.mkiv | 46 |
1 files changed, 19 insertions, 27 deletions
diff --git a/Master/texmf-dist/tex/context/base/mkiv/strc-ren.mkiv b/Master/texmf-dist/tex/context/base/mkiv/strc-ren.mkiv index 01464ad8649..89aa6f55a1a 100644 --- a/Master/texmf-dist/tex/context/base/mkiv/strc-ren.mkiv +++ b/Master/texmf-dist/tex/context/base/mkiv/strc-ren.mkiv @@ -120,7 +120,7 @@ \setheadmarking \doresetstructureheadnumbercontent \ifconditional\c_strc_sectioning_empty - \setbox\b_strc_rendering_head\hpack \headreferenceattributes to \zeropoint{\strut}% + \setbox\b_strc_rendering_head\hbox \headreferenceattributes to \zeropoint{\strut}% \else \docheckheadreference \setbox\b_strc_rendering_head\hbox \headreferenceattributes @@ -139,7 +139,7 @@ \dosetstructureheadnumbercontent \doresetstructureheadnumbercontent \ifconditional\c_strc_sectioning_empty - \setbox\b_strc_rendering_head\hpack \headreferenceattributes to \zeropoint{\strut}% + \setbox\b_strc_rendering_head\hbox \headreferenceattributes to \zeropoint{\strut}% \else % = needed \docheckheadreference \setbox\b_strc_rendering_head\hbox \headreferenceattributes @@ -151,7 +151,7 @@ \strc_rendering_stop_placement} \unexpanded\def\strc_rendering_place_head_empty - {\hpack\headreferenceattributes{\getheadsyncs}} + {\hbox\headreferenceattributes{\getheadsyncs}} % \hpack ? %D \starttyping %D \def\StretchedBox#1% @@ -197,13 +197,14 @@ \def\strc_rendering_start_placement {\bgroup \setsystemmode\currenthead + % \strc_rendering_initialize_alternatives \strc_rendering_initialize_dimensions + % \strc_rendering_initialize_line_state \reseteverypar % needed indeed \noindent % ipv \whitespace elders, na \forgetall ! \bgroup - \synctexpushline \edef\p_aligntitle{\headparameter\c!aligntitle}% \ifx\p_aligntitle\v!yes \strc_rendering_initialize_hsize_local @@ -324,9 +325,7 @@ % kind of special, we want to snap heads also according to local specs local \setbox\b_strc_rendering_head\hbox {\hskip\dimexpr\d_strc_rendering_local_leftoffset+\headparameter\c!margin\relax - \box\b_strc_rendering_head - \getheadsyncs % a latelua why not in the box - }% + \box\b_strc_rendering_head}% \ifgridsnapping \applygridmethod {\headparameter\c!grid}% @@ -346,14 +345,14 @@ \nointerlineskip \dosomebreak\nobreak \fi -% \getheadsyncs % a latelua why not in the box + \getheadsyncs \else % somehow this goes ok even when we push in the margin probably because we gobble pars % in the process of collecting index entries etc \strut \flushnotes % new, here since we're in par mode \unhbox\b_strc_rendering_head - \getheadsyncs % a latelua + \getheadsyncs \ifconditional\headissomewhere \strc_sectioning_stay_on_this_line % test case: alternative=margintext and \startparagraph .. \else @@ -371,7 +370,6 @@ \fi \fi \fi - \synctexpopline \egroup \egroup \ifconditional\headisdisplay @@ -530,14 +528,8 @@ \def\fakedheadnumber{\vphantom{0}} % needed for mathplus -% \unexpanded\def\fakeheadnumbercontent -% {\hbox to \zeropoint{\let\getheadnumber\fakedheadnumber\headnumbercontent}} - \unexpanded\def\fakeheadnumbercontent - {\edef\p_hidenumber{\headparameter\c!hidenumber}% - \ifx\p_hidenumber\v!yes\else - \hbox to \zeropoint{\let\getheadnumber\fakedheadnumber\headnumbercontent}% - \fi} + {\hbox to \zeropoint{\let\getheadnumber\fakedheadnumber\headnumbercontent}} \unexpanded\def\strc_rendering_inject_number_and_text {\edef\p_command{\headparameter\c!command}% assumes \unexpanded definition @@ -785,18 +777,18 @@ \startsetups[\??headrenderings:\v!bottom] \ifconditional\headshownumber - \setbox\scratchboxone\hbox { + \setbox0\hbox { \headnumbercontent } - \setbox\scratchboxtwo\vbox { + \setbox2\vbox { \headsetupspacing - \advance\hsize-\wd\scratchboxone\relax + \advance\hsize-\wd0\relax \headtextcontent } \hbox { - \box\scratchboxone + \box0 \hskip\headnumberdistance - \box\scratchboxtwo + \box2 } \else \vbox { @@ -814,18 +806,18 @@ \startsetups[\??headrenderings:\v!top] \ifconditional\headshownumber - \setbox\scratchboxone\hbox { + \setbox0\hbox { \headnumbercontent } - \setbox\scratchboxtwo\vtop { + \setbox2\vtop { \headsetupspacing - \advance\hsize-\wd\scratchboxone\relax + \advance\hsize-\wd0\relax \headtextcontent } \hbox { - \box\scratchboxone + \box0 \hskip\headnumberdistance - \box\scratchboxtwo + \box2 } \else \vtop{ |