* paper dimensions for TEXpage @ 2021-08-17 3:56 Pablo Rodriguez via ntg-context 2021-08-17 7:30 ` Hans Hagen via ntg-context 0 siblings, 1 reply; 5+ messages in thread From: Pablo Rodriguez via ntg-context @ 2021-08-17 3:56 UTC (permalink / raw) To: mailing list for ConTeXt users; +Cc: Pablo Rodriguez Dear list, I have the following sample: \definelayer[hi][x=.5\paperwidth, y=.5\paperheight] \setupbackgrounds[page][background=hi] \starttext \setlayer[hi]{hi} \startTEXpage[offset=10em] \null \stopTEXpage \stoptext I don’t get the layer in the TEXpage. How could I get it with the TEXpage dimensions? Many thanks for your help, Pablo -- http://www.ousia.tk ___________________________________________________________________________________ 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] 5+ messages in thread
* Re: paper dimensions for TEXpage 2021-08-17 3:56 paper dimensions for TEXpage Pablo Rodriguez via ntg-context @ 2021-08-17 7:30 ` Hans Hagen via ntg-context 2021-08-17 14:01 ` Pablo Rodriguez via ntg-context 0 siblings, 1 reply; 5+ messages in thread From: Hans Hagen via ntg-context @ 2021-08-17 7:30 UTC (permalink / raw) To: mailing list for ConTeXt users; +Cc: Hans Hagen, Pablo Rodriguez On 8/17/2021 5:56 AM, Pablo Rodriguez via ntg-context wrote: > Dear list, > > I have the following sample: > > \definelayer[hi][x=.5\paperwidth, y=.5\paperheight] > \setupbackgrounds[page][background=hi] > \starttext > \setlayer[hi]{hi} > \startTEXpage[offset=10em] > \null > \stopTEXpage > \stoptext > > I don’t get the layer in the TEXpage. > > How could I get it with the TEXpage dimensions? only by first boxing (using framed or so) and then taking those dimensions ----------------------------------------------------------------- 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] 5+ messages in thread
* Re: paper dimensions for TEXpage 2021-08-17 7:30 ` Hans Hagen via ntg-context @ 2021-08-17 14:01 ` Pablo Rodriguez via ntg-context 2021-08-18 14:25 ` Hans Hagen via ntg-context 0 siblings, 1 reply; 5+ messages in thread From: Pablo Rodriguez via ntg-context @ 2021-08-17 14:01 UTC (permalink / raw) To: Hans Hagen via ntg-context; +Cc: Pablo Rodriguez On 8/17/21 9:30 AM, Hans Hagen via ntg-context wrote: > On 8/17/2021 5:56 AM, Pablo Rodriguez via ntg-context wrote: >> [...] >> I don’t get the layer in the TEXpage. >> >> How could I get it with the TEXpage dimensions? > only by first boxing (using framed or so) and then taking those dimensions Many thanks for your reply, Hans. I’m afraid I don’t know how to make the commands work: \setupexternalfigures[location=default] \definelayer[hi] [x=.5\dimexpr\framedwidth\relax, y=.5\dimexpr\framedheight\relax] \setupbackgrounds[page][background={foreground, hi}] \starttext \startTEXpage \framed[frame=off, offset=none] {\setlayer[hi]{\color[red]{hi}} \externalfigure[cow-brown]\framedheight} \stopTEXpage \stoptext In this case, \getfiguredimensions would work, but I don’t know how to deal with a pure text box. BTW, is there a way to have TEXpages numbered? "pagestate=start" seems not to work here. Many thanks for your help, Pablo -- http://www.ousia.tk ___________________________________________________________________________________ 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] 5+ messages in thread
* Re: paper dimensions for TEXpage 2021-08-17 14:01 ` Pablo Rodriguez via ntg-context @ 2021-08-18 14:25 ` Hans Hagen via ntg-context 2021-08-19 17:52 ` Pablo Rodriguez via ntg-context 0 siblings, 1 reply; 5+ messages in thread From: Hans Hagen via ntg-context @ 2021-08-18 14:25 UTC (permalink / raw) To: mailing list for ConTeXt users; +Cc: Hans Hagen, Pablo Rodriguez On 8/17/2021 4:01 PM, Pablo Rodriguez via ntg-context wrote: > On 8/17/21 9:30 AM, Hans Hagen via ntg-context wrote: >> On 8/17/2021 5:56 AM, Pablo Rodriguez via ntg-context wrote: >>> [...] >>> I don’t get the layer in the TEXpage. >>> >>> How could I get it with the TEXpage dimensions? >> only by first boxing (using framed or so) and then taking those dimensions > > Many thanks for your reply, Hans. > > I’m afraid I don’t know how to make the commands work: > > \setupexternalfigures[location=default] > \definelayer[hi] > [x=.5\dimexpr\framedwidth\relax, y=.5\dimexpr\framedheight\relax] > \setupbackgrounds[page][background={foreground, hi}] > \starttext > \startTEXpage > \framed[frame=off, offset=none] > {\setlayer[hi]{\color[red]{hi}} > \externalfigure[cow-brown]\framedheight} > \stopTEXpage > \stoptext > > In this case, \getfiguredimensions would work, but I don’t know how to > deal with a pure text box. > > BTW, is there a way to have TEXpages numbered? "pagestate=start" seems > not to work here. for the wiki ... \starttext \definelayer[hi] \startTEXpage[background=hi] \setbox\scratchbox\hbox\framed [frame=off,offset=none,align=middle] {\input{tufte}}% \setuplayer [hi] [width=\wd\scratchbox,height=\htdp\scratchbox] \setlayer [hi][preset=middle] {\color[green]{there}} \box\scratchbox \stopTEXpage \defineoverlay[hi] \startTEXpage[background=hi] \defineoverlay [hi] [{\framed [frame=off,offset=overlay,width=\overlaywidth,height=\overlayheight] {\color[red]{there}}}] \framed [frame=off,offset=none,align=middle,background=hi] {\input{tufte}}% \stopTEXpage \stoptext ----------------------------------------------------------------- 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] 5+ messages in thread
* Re: paper dimensions for TEXpage 2021-08-18 14:25 ` Hans Hagen via ntg-context @ 2021-08-19 17:52 ` Pablo Rodriguez via ntg-context 0 siblings, 0 replies; 5+ messages in thread From: Pablo Rodriguez via ntg-context @ 2021-08-19 17:52 UTC (permalink / raw) To: Hans Hagen via ntg-context; +Cc: Pablo Rodriguez On 8/18/21 4:25 PM, Hans Hagen via ntg-context wrote: > On 8/17/2021 4:01 PM, Pablo Rodriguez via ntg-context wrote: >> [...] >> In this case, \getfiguredimensions would work, but I don’t know how to >> deal with a pure text box. >> >> BTW, is there a way to have TEXpages numbered? "pagestate=start" seems >> not to work here. Many thanks for your reply, Hans. "pagestate=start" works fine with TEXpages, but I don’t know why I didn’t noticed that when I checked it. > for the wiki ... Wikified at https://wiki.contextgarden.net/Layers#Layers_in_fitting_pages. Many thanks for your help, Pablo -- http://www.ousia.tk ___________________________________________________________________________________ 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] 5+ messages in thread
end of thread, other threads:[~2021-08-19 17:52 UTC | newest] Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2021-08-17 3:56 paper dimensions for TEXpage Pablo Rodriguez via ntg-context 2021-08-17 7:30 ` Hans Hagen via ntg-context 2021-08-17 14:01 ` Pablo Rodriguez via ntg-context 2021-08-18 14:25 ` Hans Hagen via ntg-context 2021-08-19 17:52 ` Pablo Rodriguez via ntg-context
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).