ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Is there “toffset” option for \setupbackgrounds in context
@ 2016-02-26 11:44 Bou Salim
  2016-02-26 12:03 ` Wolfgang Schuster
  0 siblings, 1 reply; 2+ messages in thread
From: Bou Salim @ 2016-02-26 11:44 UTC (permalink / raw)
  To: ntg-context


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

I'm trying to learn `context`, and I'm satisfied with their capacities.

I read in  contextgarden
<http://wiki.contextgarden.net/Command/setupbackgrounds> that options of
`\setupbackgrounds` inherit from `\setupframed`, but if I setup
`toffset=5mm` for  `\setupbackgrounds[text][text][frame=on,toffset=5mm]` I
have no effect?

With `frameoffset` you can modify the four directions but how about a
single direction?

Code

    \setuppapersize[A4]
    \setuppagenumbering[state=none]

    \setupbackgrounds[text][text][frame=on,toffset=5mm]

    \starttext

    \input knuth


    \stoptext

[-- Attachment #1.2: Type: text/html, Size: 889 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re:  Is there “toffset” option for \setupbackgrounds in context
  2016-02-26 11:44 Is there “toffset” option for \setupbackgrounds in context Bou Salim
@ 2016-02-26 12:03 ` Wolfgang Schuster
  0 siblings, 0 replies; 2+ messages in thread
From: Wolfgang Schuster @ 2016-02-26 12:03 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

> Bou Salim <mailto:salimcollo7@gmail.com>
> 26. Februar 2016 um 12:44
> I'm trying to learn `context`, and I'm satisfied with their capacities.
>
> I read in contextgarden 
> <http://wiki.contextgarden.net/Command/setupbackgrounds> that options 
> of `\setupbackgrounds` inherit from `\setupframed`, but if I setup 
> `toffset=5mm` for 
>  `\setupbackgrounds[text][text][frame=on,toffset=5mm]` I have no effect?
>
> With `frameoffset` you can modify the four directions but how about a 
> single direction?
The background mechanism for the text areas supports only a fraction of 
the normal framed options but you can do a lot when you use Metapost to 
draw the background.

\startuniqueMPgraphic{TextBackground}
     path p ; p := unitsquare xscaled OverlayWidth yscaled OverlayHeight ;
     draw p topenlarged 5mm ;
     setbounds currentpicture to OverlayBox ;
\stopuniqueMPgraphic

\defineoverlay[TextBackground][\uniqueMPgraphic{TextBackground}]

\setuppapersize[A4]
\setuppagenumbering[state=none]

\setupbackgrounds[text][text][background=TextBackground]

\starttext

\input knuth

\stoptext

BTW: It’s rude to crosspost without mentioning this 
(http://tex.stackexchange.com/questions/296037/is-there-toffset-option-for-setupbackgrounds-in-context)

Wolfgang

[-- Attachment #1.2: Type: text/html, Size: 2650 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-02-26 12:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-26 11:44 Is there “toffset” option for \setupbackgrounds in context Bou Salim
2016-02-26 12:03 ` 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).