* Blank page inserted when text reaches column's end
@ 2019-12-08 23:44 Thangalin
2019-12-09 8:41 ` Denis Maier
0 siblings, 1 reply; 6+ messages in thread
From: Thangalin @ 2019-12-08 23:44 UTC (permalink / raw)
To: mailing list for ConTeXt users
When text reaches the end of a column, it appears to trigger inserting
a blank page. In the following code, \dorecurse{3} causes a blank page
to appear but \dorecurse{2} does not. The only difference is that when
set to 3, the additional text is written on the last line of the last
column. This scenario results in a blank page.
Any ideas how the blank page can be suppressed?
\showgrid
\setuplayout[grid=yes]
\starttext
\startcolumnset[n=2]
\input knuth \input lorem \input lorem \input knuth
\dorecurse{3}{No TV and no beer make Homer something something.}
\stopcolumnset
\stoptext
Version:
$ context --version
mtx-context | ConTeXt Process Management 1.03
mtx-context |
mtx-context | main context file:
/opt/context/tex/texmf-context/tex/context/base/mkiv/context.mkiv
mtx-context | current version: 2019.06.11 19:20
Thank you!
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Blank page inserted when text reaches column's end
2019-12-08 23:44 Blank page inserted when text reaches column's end Thangalin
@ 2019-12-09 8:41 ` Denis Maier
2019-12-09 17:23 ` Wolfgang Schuster
0 siblings, 1 reply; 6+ messages in thread
From: Denis Maier @ 2019-12-09 8:41 UTC (permalink / raw)
To: ntg-context
Am 09.12.2019 um 00:44 schrieb Thangalin:
> When text reaches the end of a column, it appears to trigger inserting
> a blank page. In the following code, \dorecurse{3} causes a blank page
> to appear but \dorecurse{2} does not. The only difference is that when
> set to 3, the additional text is written on the last line of the last
> column. This scenario results in a blank page.
>
> Any ideas how the blank page can be suppressed?
>
> \showgrid
> \setuplayout[grid=yes]
>
> \starttext
> \startcolumnset[n=2]
> \input knuth \input lorem \input lorem \input knuth
> \dorecurse{3}{No TV and no beer make Homer something something.}
> \stopcolumnset
> \stoptext
>
> Version:
>
> $ context --version
> mtx-context | ConTeXt Process Management 1.03
> mtx-context |
> mtx-context | main context file:
> /opt/context/tex/texmf-context/tex/context/base/mkiv/context.mkiv
> mtx-context | current version: 2019.06.11 19:20
>
> Thank you!
>
What about:
\installpagebreakhandler{last}{}
(I have this in most of my documents, but I'm not sure it works with
columnsets.)
Best,
Denis
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Blank page inserted when text reaches column's end
2019-12-09 8:41 ` Denis Maier
@ 2019-12-09 17:23 ` Wolfgang Schuster
2019-12-10 2:37 ` Thangalin
0 siblings, 1 reply; 6+ messages in thread
From: Wolfgang Schuster @ 2019-12-09 17:23 UTC (permalink / raw)
To: mailing list for ConTeXt users, Denis Maier
Denis Maier schrieb am 09.12.2019 um 09:41:
> Am 09.12.2019 um 00:44 schrieb Thangalin:
>> When text reaches the end of a column, it appears to trigger inserting
>> a blank page. In the following code, \dorecurse{3} causes a blank page
>> to appear but \dorecurse{2} does not. The only difference is that when
>> set to 3, the additional text is written on the last line of the last
>> column. This scenario results in a blank page.
>>
>> Any ideas how the blank page can be suppressed?
>>
>> \showgrid
>> \setuplayout[grid=yes]
>>
>> \starttext
>> \startcolumnset[n=2]
>> \input knuth \input lorem \input lorem \input knuth
>> \dorecurse{3}{No TV and no beer make Homer something something.}
>> \stopcolumnset
>> \stoptext
>>
>> Version:
>>
>> $ context --version
>> mtx-context | ConTeXt Process Management 1.03
>> mtx-context |
>> mtx-context | main context file:
>> /opt/context/tex/texmf-context/tex/context/base/mkiv/context.mkiv
>> mtx-context | current version: 2019.06.11 19:20
>>
>> Thank you!
>>
> What about:
> \installpagebreakhandler{last}{}
>
> (I have this in most of my documents, but I'm not sure it works with
> columnsets.)
Better use this setup to get rid of the extra page in a doublesided
document.
\setuppagenumbering[page=no]
Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Blank page inserted when text reaches column's end
2019-12-09 17:23 ` Wolfgang Schuster
@ 2019-12-10 2:37 ` Thangalin
2019-12-11 1:51 ` Thangalin
0 siblings, 1 reply; 6+ messages in thread
From: Thangalin @ 2019-12-10 2:37 UTC (permalink / raw)
To: mailing list for ConTeXt users
Thank you both. Neither approach removes the blank page with either
version 2019.06.11 or 2019.12.06 on Linux. Is there a specific version
of ConTeXt required? The code to generate the document resembles:
\setuppagenumbering[alternative=doublesided,page=no]
\installpagebreakhandler{last}{}
\setuplayout[grid=yes]
\starttext
\startcolumnset[n=2]
\input knuth \input lorem \input lorem \input knuth
\dorecurse{3}{No TV and no beer make Homer something something.}
\stopcolumnset
\stoptext
The second page remains, regardless of doublesided/singlesided or
pagebreakhandler.
Henri Menke pointed out that "page-cst.mkiv" contains an explicit line
break associated with stoppagegrid:
https://github.com/contextgarden/context-mirror/blob/f74c4055713ab52a11d12435eb04040ec6553129/tex/context/base/mkiv/page-cst.mkiv#L199-L201
Could this be grid itself be problematic?
Cheers!
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Blank page inserted when text reaches column's end
2019-12-10 2:37 ` Thangalin
@ 2019-12-11 1:51 ` Thangalin
2019-12-11 4:55 ` Wolfgang Schuster
0 siblings, 1 reply; 6+ messages in thread
From: Thangalin @ 2019-12-11 1:51 UTC (permalink / raw)
To: mailing list for ConTeXt users
Commenting out the \page_grd_command_flush_page macro seems to have
reversed the effect. Any pages having columnar text that does not
extend to the last line are now suppressed. How would I go about
adding a conditional that checks to see whether the column is filled
before deciding if a page break is necessary?
\unprotect
\def\page_grd_stop{%
\endgraf % needed, else wrong vsize in one par case
\vfill % otherwise weird \placenotes[endnotes]
\page_grd_command_set_vsize % needed
\penalty\c_page_otr_eject_penalty
%\page_grd_command_flush_page
\page_otr_fill_and_eject_page
\page_grd_command_set_vsize % why here
\egroup
\page_otr_command_set_vsize
\page_otr_command_set_hsize}
\protect
Thank you!
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Blank page inserted when text reaches column's end
2019-12-11 1:51 ` Thangalin
@ 2019-12-11 4:55 ` Wolfgang Schuster
0 siblings, 0 replies; 6+ messages in thread
From: Wolfgang Schuster @ 2019-12-11 4:55 UTC (permalink / raw)
To: mailing list for ConTeXt users, Thangalin
Thangalin schrieb am 11.12.2019 um 02:51:
> Commenting out the \page_grd_command_flush_page macro seems to have
> reversed the effect. Any pages having columnar text that does not
> extend to the last line are now suppressed. How would I go about
> adding a conditional that checks to see whether the column is filled
> before deciding if a page break is necessary?
>
> \unprotect
> \def\page_grd_stop{%
> \endgraf % needed, else wrong vsize in one par case
> \vfill % otherwise weird \placenotes[endnotes]
> \page_grd_command_set_vsize % needed
> \penalty\c_page_otr_eject_penalty
> %\page_grd_command_flush_page
> \page_otr_fill_and_eject_page
> \page_grd_command_set_vsize % why here
> \egroup
> \page_otr_command_set_vsize
> \page_otr_command_set_hsize}
> \protect
Fails for the next example (the first page appears twice in the PDF and
the second page is missing):
\setuplayout[grid=yes]
\starttext
\startcolumnset[n=2]
\dorecurse{100}{Line #1\par}
\stopcolumnset
\stoptext
Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2019-12-11 4:55 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-08 23:44 Blank page inserted when text reaches column's end Thangalin
2019-12-09 8:41 ` Denis Maier
2019-12-09 17:23 ` Wolfgang Schuster
2019-12-10 2:37 ` Thangalin
2019-12-11 1:51 ` Thangalin
2019-12-11 4:55 ` Wolfgang Schuster
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).