[NTG-context] Unwanted whitespace for tables and enumerations after \inmargin headings

Rik rik at panix.com
Sat Apr 19 17:46:35 CEST 2014


On 2014-04-19 04:55, Wolfgang Schuster wrote:
> \setuphead
>   [section]
>   [alternative=text,
>    command=\SectionCommand,
>    distance=0pt,
>    insidesection={\blank[overlay]}]
>
> \define[2]\SectionCommand
>   {\inmargin{#1 -- #2}}
>
> \setuplayout[backspace=4cm]
>
> \starttext
>
> \startsection[title={First}]
>
> \input ward
>
> \stopsection
>
> \startsection[title={Second}]
>
> \startitemize
> \item One
> \item Two
> \stopitemize
>
> \stopsection
>
> \startsection[title={Third}]
>
> \starttabulate
> \NC Knuth \NC \input{knuth} \NC\NR
> \NC Tufte \NC \input{tufte} \NC\NR
> \stoptabulate
>
> \stopsection
>
> \stoptext
>
> Wolfgang

Thank you, Wolfgang. This works mostly, but not completely, for 
start/stop sectioning (not for classic sectioning).

I do notice that there is still a problem with tabulations if you add a 
horizontal line (\HL or \FL) to the beginning of the table. New example, 
building on yours:

    \setuphead
       [section]
       [alternative=text,
        command=\SectionCommand,
        distance=0pt,
        insidesection={\blank[overlay]}]

    \define[2]\SectionCommand
       {\inmargin{#1 -- #2}}

    \setuplayout[backspace=4cm]

    \starttext

    \startsection[title={Okay with text here}]

    Text here
    \starttabulate
    \FL \NC Knuth \NC \input{knuth} \NC\NR
    \NC Tufte \NC \input{tufte} \NC\NR
    \stoptabulate

    \stopsection

    \startsection[title={Fails with no text}]

    \starttabulate
    \FL \NC Knuth \NC \input{knuth} \NC\NR
    \NC Tufte \NC \input{tufte} \NC\NR
    \stoptabulate

    \stopsection

    \stoptext


-- 
RIk Kabel

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.ntg.nl/pipermail/ntg-context/attachments/20140419/e58c797a/attachment.html>


More information about the ntg-context mailing list