* Adjusting parameters for a single page @ 2021-05-10 15:15 denis.maier 2021-05-10 22:12 ` Hans Hagen 0 siblings, 1 reply; 6+ messages in thread From: denis.maier @ 2021-05-10 15:15 UTC (permalink / raw) To: ntg-context [-- Attachment #1.1: Type: text/plain, Size: 537 bytes --] Hi everyone, I know it is possible to make local changes by enclosing text in \start \stop pairs to make local changes. Then, there are also commands that only affect the next/current paragraph, such as \looseness. But is there a similar mechanism for page-layout changes? For example your penalty settings allow widows and orphans, but on one particular page you want to change the penalties. Or, you use \setupalign[height], but on one page you want to use \setupalign[bottom] instead. Is there a way to do this ? Best, Denis [-- Attachment #1.2: Type: text/html, Size: 2305 bytes --] [-- Attachment #2: Type: text/plain, Size: 493 bytes --] ___________________________________________________________________________________ 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: Adjusting parameters for a single page 2021-05-10 15:15 Adjusting parameters for a single page denis.maier @ 2021-05-10 22:12 ` Hans Hagen 2021-05-11 8:26 ` denis.maier 2021-05-11 8:29 ` denis.maier 0 siblings, 2 replies; 6+ messages in thread From: Hans Hagen @ 2021-05-10 22:12 UTC (permalink / raw) To: mailing list for ConTeXt users, denis.maier On 5/10/2021 5:15 PM, denis.maier@ub.unibe.ch wrote: > Hi everyone, > > I know it is possible to make local changes by enclosing text in \start > \stop pairs to make local changes. Then, there are also commands that > only affect the next/current paragraph, such as \looseness. > > But is there a similar mechanism for page-layout changes? For example > your penalty settings allow widows and orphans, but on one particular > page you want to change the penalties. Or, you use \setupalign[height], > but on one page you want to use \setupalign[bottom] instead. Is there a > way to do this ? it works per paragraph so then you need to adapt it for a specific paragraph when the par starts, the properties are stored (in lmtx it's configured that way); you can change properties in the middle of a paragraph but then you need to explicitly freeze them, as demonstrated in the examples below; tracing will show you all stored properties (default tex behaviour is that the last setting counts which can be somewhat unexpected) \starttext \tracingoutput1 \tracingonline1 \pretolerance9000 test \pretolerance8000 test \par \pretolerance9000 test \pretolerance7000 \updateparagraphproperties test \par \pretolerance9000 test \pretolerance6000 \snapshotpar\frozentolerancecode test \par \stoptext the log shows ... \par[newgraf][16=1,17=1], .... pretolerance 9000, .... \par[newgraf][16=1,17=1], .... pretolerance 7000, .... \par[newgraf][16=1,17=1], .... pretolerance 6000, .... now, as you probably don't want to be persistent you can group: \def\MyHack {\bgroup \pretolerance5000 \snapshotpar\frozentolerancecode \egroup} test \MyHack test works ok because the snapshotting applies to the current paragraph (it's actually described in some manual) so, basically, you have a lot of control, all together some 36 parameters (pablo probably loves the somewhat secret on the fly adjustspacing step, stretch and shrink tweakability) Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl ----------------------------------------------------------------- ___________________________________________________________________________________ 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: Adjusting parameters for a single page 2021-05-10 22:12 ` Hans Hagen @ 2021-05-11 8:26 ` denis.maier 2021-05-11 8:29 ` denis.maier 1 sibling, 0 replies; 6+ messages in thread From: denis.maier @ 2021-05-11 8:26 UTC (permalink / raw) To: j.hagen, ntg-context Thanks, Hans, really interesting stuff. > so, basically, you have a lot of control, all together some 36 parameters > (pablo probably loves the somewhat secret on the fly adjustspacing step, > stretch and shrink tweakability) Any hints where I can find these 36 parameters? Thanks for your help, 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: Adjusting parameters for a single page 2021-05-10 22:12 ` Hans Hagen 2021-05-11 8:26 ` denis.maier @ 2021-05-11 8:29 ` denis.maier 2021-05-11 8:41 ` luigi scarso 1 sibling, 1 reply; 6+ messages in thread From: denis.maier @ 2021-05-11 8:29 UTC (permalink / raw) To: j.hagen, ntg-context -----Ursprüngliche Nachricht----- > Von: Hans Hagen <j.hagen@xs4all.nl> > Gesendet: Dienstag, 11. Mai 2021 00:13 > An: mailing list for ConTeXt users <ntg-context@ntg.nl>; Maier, Denis > Christian (UB) <denis.maier@ub.unibe.ch> > Betreff: Re: [NTG-context] Adjusting parameters for a single page > > On 5/10/2021 5:15 PM, denis.maier@ub.unibe.ch wrote: > > Hi everyone, > > > > I know it is possible to make local changes by enclosing text in > > \start \stop pairs to make local changes. Then, there are also > > commands that only affect the next/current paragraph, such as \looseness. > > > > But is there a similar mechanism for page-layout changes? For example > > your penalty settings allow widows and orphans, but on one particular > > page you want to change the penalties. Or, you use > > \setupalign[height], but on one page you want to use > > \setupalign[bottom] instead. Is there a way to do this ? > it works per paragraph so then you need to adapt it for a specific paragraph So, that means you cannot make changes to a page, but only to paragraph. If a paragraph goes over page boundaries, you cannot add stretch or shrink interlinespace for just one page... correct? ___________________________________________________________________________________ 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: Adjusting parameters for a single page 2021-05-11 8:29 ` denis.maier @ 2021-05-11 8:41 ` luigi scarso 2021-05-11 9:37 ` denis.maier 0 siblings, 1 reply; 6+ messages in thread From: luigi scarso @ 2021-05-11 8:41 UTC (permalink / raw) To: mailing list for ConTeXt users [-- Attachment #1.1: Type: text/plain, Size: 1482 bytes --] On Tue, May 11, 2021 at 10:29 AM <denis.maier@ub.unibe.ch> wrote: > -----Ursprüngliche Nachricht----- > > Von: Hans Hagen <j.hagen@xs4all.nl> > > Gesendet: Dienstag, 11. Mai 2021 00:13 > > An: mailing list for ConTeXt users <ntg-context@ntg.nl>; Maier, Denis > > Christian (UB) <denis.maier@ub.unibe.ch> > > Betreff: Re: [NTG-context] Adjusting parameters for a single page > > > > On 5/10/2021 5:15 PM, denis.maier@ub.unibe.ch wrote: > > > Hi everyone, > > > > > > I know it is possible to make local changes by enclosing text in > > > \start \stop pairs to make local changes. Then, there are also > > > commands that only affect the next/current paragraph, such as > \looseness. > > > > > > But is there a similar mechanism for page-layout changes? For example > > > your penalty settings allow widows and orphans, but on one particular > > > page you want to change the penalties. Or, you use > > > \setupalign[height], but on one page you want to use > > > \setupalign[bottom] instead. Is there a way to do this ? > > it works per paragraph so then you need to adapt it for a specific > paragraph > > So, that means you cannot make changes to a page, but only to paragraph. > If a paragraph goes over page boundaries, you cannot add stretch or shrink > interlinespace for just one page... correct? > this looks more a otr technique, e.g. https://www.tug.org/TUGboat/tb11-1/tb27salomon.pdf (or grep the context code for otr) -- luigi [-- Attachment #1.2: Type: text/html, Size: 2342 bytes --] [-- Attachment #2: Type: text/plain, Size: 493 bytes --] ___________________________________________________________________________________ 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: Adjusting parameters for a single page 2021-05-11 8:41 ` luigi scarso @ 2021-05-11 9:37 ` denis.maier 0 siblings, 0 replies; 6+ messages in thread From: denis.maier @ 2021-05-11 9:37 UTC (permalink / raw) To: ntg-context [-- Attachment #1.1: Type: text/plain, Size: 1880 bytes --] Von: ntg-context <ntg-context-bounces@ntg.nl> Im Auftrag von luigi scarso Gesendet: Dienstag, 11. Mai 2021 10:41 An: mailing list for ConTeXt users <ntg-context@ntg.nl> Betreff: Re: [NTG-context] Adjusting parameters for a single page On Tue, May 11, 2021 at 10:29 AM <denis.maier@ub.unibe.ch<mailto:denis.maier@ub.unibe.ch>> wrote: -----Ursprüngliche Nachricht----- > Von: Hans Hagen <j.hagen@xs4all.nl<mailto:j.hagen@xs4all.nl>> > Gesendet: Dienstag, 11. Mai 2021 00:13 > An: mailing list for ConTeXt users <ntg-context@ntg.nl<mailto:ntg-context@ntg.nl>>; Maier, Denis > Christian (UB) <denis.maier@ub.unibe.ch<mailto:denis.maier@ub.unibe.ch>> > Betreff: Re: [NTG-context] Adjusting parameters for a single page > > On 5/10/2021 5:15 PM, denis.maier@ub.unibe.ch<mailto:denis.maier@ub.unibe.ch> wrote: > > Hi everyone, > > > > I know it is possible to make local changes by enclosing text in > > \start \stop pairs to make local changes. Then, there are also > > commands that only affect the next/current paragraph, such as \looseness. > > > > But is there a similar mechanism for page-layout changes? For example > > your penalty settings allow widows and orphans, but on one particular > > page you want to change the penalties. Or, you use > > \setupalign[height], but on one page you want to use > > \setupalign[bottom] instead. Is there a way to do this ? > it works per paragraph so then you need to adapt it for a specific paragraph So, that means you cannot make changes to a page, but only to paragraph. If a paragraph goes over page boundaries, you cannot add stretch or shrink interlinespace for just one page... correct? this looks more a otr technique, e.g. https://www.tug.org/TUGboat/tb11-1/tb27salomon.pdf (or grep the context code for otr) Thanks for the hint. I have TeX by Topic open at the moment :-) Denis [-- Attachment #1.2: Type: text/html, Size: 4946 bytes --] [-- Attachment #2: Type: text/plain, Size: 493 bytes --] ___________________________________________________________________________________ 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:[~2021-05-11 9:37 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2021-05-10 15:15 Adjusting parameters for a single page denis.maier 2021-05-10 22:12 ` Hans Hagen 2021-05-11 8:26 ` denis.maier 2021-05-11 8:29 ` denis.maier 2021-05-11 8:41 ` luigi scarso 2021-05-11 9:37 ` denis.maier
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).