ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* layer disappears when showframe is set
@ 2021-08-26 12:46 juh via ntg-context
  2021-08-26 15:52 ` Wolfgang Schuster via ntg-context
  0 siblings, 1 reply; 3+ messages in thread
From: juh via ntg-context @ 2021-08-26 12:46 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: juh


[-- Attachment #1.1: Type: text/plain, Size: 627 bytes --]

Hi,

this sample shows that the image in a layer in header disappears if showframe is
set.

\setupexternalfigures[location=default]
\definelayer[Cow]
[x=0, y=0]

\setlayer[Cow]
[x=10em, y=0mm]
{\externalfigure[cow][height=\lineheight]}
\setupbackgrounds[header][background=Cow]

\showframe

\starttext
\input knuth
\stoptext

Mit freundlichen Grüßen
Jan Ulrich Hasecke

-- 
Autoren-Homepage: ......... http://literatur.hasecke.com
Satiren & Essays: ......... http://www.sudelbuch.de
Privater Blog: ............ http://www.hasecke.eu
Netzliteratur-Projekt: .... http://www.generationenprojekt.de



[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 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] 3+ messages in thread

* Re: layer disappears when showframe is set
  2021-08-26 12:46 layer disappears when showframe is set juh via ntg-context
@ 2021-08-26 15:52 ` Wolfgang Schuster via ntg-context
  2021-08-27  6:17   ` juh via ntg-context
  0 siblings, 1 reply; 3+ messages in thread
From: Wolfgang Schuster via ntg-context @ 2021-08-26 15:52 UTC (permalink / raw)
  To: juh, mailing list for ConTeXt users; +Cc: Wolfgang Schuster

juh via ntg-context schrieb am 26.08.2021 um 14:46:
> Hi,
>
> this sample shows that the image in a layer in header disappears if showframe is
> set.
>
> \setupexternalfigures[location=default]
> \definelayer[Cow]
> [x=0, y=0]
>
> \setlayer[Cow]
> [x=10em, y=0mm]
> {\externalfigure[cow][height=\lineheight]}
> \setupbackgrounds[header][background=Cow]
>
> \showframe
>
> \starttext
> \input knuth
> \stoptext

The \showframe command is just a wrapper for \setupbackgrounds to enable 
the frames on certain parts of the page.

One of the settings which are passed to \setupbacgrounds when you use 
\showframe is "background=" which resets all previous values of the 
background-key.

To keep the layer setting you have to move \showframe above your own 
\setupbackgrounds command because the reset of the background-key 
happens then before you pass your own value.

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] 3+ messages in thread

* Re: layer disappears when showframe is set
  2021-08-26 15:52 ` Wolfgang Schuster via ntg-context
@ 2021-08-27  6:17   ` juh via ntg-context
  0 siblings, 0 replies; 3+ messages in thread
From: juh via ntg-context @ 2021-08-27  6:17 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: juh


[-- Attachment #1.1: Type: text/plain, Size: 641 bytes --]

Hi Wolfgang,

thanks a lot for your help.

Am Thu, Aug 26, 2021 at 05:52:11PM +0200 schrieb Wolfgang Schuster:
> To keep the layer setting you have to move \showframe above your own
> \setupbackgrounds command because the reset of the background-key happens
> then before you pass your own value.

I wikified this hint here:
https://wiki.contextgarden.net/Command/showframe#See_also

juh



-- 
Autoren-Homepage: ......... http://literatur.hasecke.com
Satiren & Essays: ......... http://www.sudelbuch.de
Privater Blog: ............ http://www.hasecke.eu
Netzliteratur-Projekt: .... http://www.generationenprojekt.de



[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 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] 3+ messages in thread

end of thread, other threads:[~2021-08-27  6:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-26 12:46 layer disappears when showframe is set juh via ntg-context
2021-08-26 15:52 ` Wolfgang Schuster via ntg-context
2021-08-27  6:17   ` juh 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).