On Tue, 10 Nov 2020 at 18:25, Wolfgang Schuster <wolfgang.schuster.lists@gmail.com> wrote:
Sylvain Hubert schrieb am 10.11.2020 um 18:06:

> Thanks for the suggestion, but as illustrated by the second example,
> copied here, where the section title is at the top of the page:
>
>      \starttext
>      \showframe
>      \dorecurse{50}{a }
>      \startsection[title=spec][before={\blank[preference,big]},
> after={\blank[samepage,big]}]

Your settings in the second argument of \startsection make no sense
because the optional argument is for userdata (values like author etc.)

>      \startxtable
>      \startxrow
>      \startxcell[ny=30]a\stopxcell\startxcell 1\stopxcell
>      \stopxrow
>      \dorecurse{29}{\startxrow\startxcell 2\stopxcell\stopxrow}
>      \stopxtable
>      \stoptext
>
> it is sometimes difficult to predict how much remaining space should
> trigger a line break.

You can either reformat your table or put the table in a float
environment to move it to a place where it fits.

Wolfgang

Weirdly enough, "\hskip 0pt" solves the problem.

    \setuphead[section][after={\blank[samepage]\hskip 0pt}]
    \starttext
    \showframe
    \dorecurse{50}{a }
    \startsection[title=spec]
    \startxtable
    \startxrow
    \startxcell[ny=30]a\stopxcell\startxcell 1\stopxcell
    \stopxrow
    \dorecurse{29}{\startxrow\startxcell 2\stopxcell\stopxrow}
    \stopxtable
    \stoptext

Sylvain