ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Wolfgang Schuster <wolfgang.schuster.lists@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>,
	Context NTG <contextntg@gmail.com>
Subject: Re: Meptapost Drawing not showing-up in Context Letter Style
Date: Mon, 11 Mar 2019 21:55:15 +0100	[thread overview]
Message-ID: <3204c3cd-1284-36a0-f389-05f01a8a2ebd@gmail.com> (raw)
In-Reply-To: <CAPtmdbPbh0cz8+_kAf9tVA_cpCmbkf5r8q9KZab1YSF+gfMDwA@mail.gmail.com>

Context NTG schrieb am 10.03.19 um 16:59:
> I am trying to get a metapost drawing as logo added to right upper 
> corner of a DIN B style letterhead, but it does not show up, just the 
> letter itself. Is there anything to change to the layers for the MP toe 
> reveal itself?

The letter module uses local settings for the page background to place 
all the layer for the header, footer etc. and your own background setup 
is overloaded by the module.


What you can do in this case is to use the predefined but unused 
lettermain layer to place your logo in the background.


\usemodule[letter][style=dinb]

\startuseMPgraphic{mpglogo}
   path p;
   p := (0,0)--(100,0)--(100,100)--(0,100)--cycle ;
   path q;
   q := p cornered 30pt;
   draw q withcolor black withpen pencircle scaled 7pt ;
\stopuseMPgraphic

\startsetups[letter:layer:lettermain]
   \scale[width=25mm,height=25mm]{\useMPgraphic{mpglogo}}
\stopsetups

\setupletterlayer
   [lettermain]
   [alternative=setups,
    x=160mm,
    y=17mm]

\startletter
\dorecurse{3}{\input knuth \par}
\stopletter


Another way to place content in the background is to use the “paper” (or 
“text”) background which isn’t used by the letter module and your 
settings won’t be overloaded.

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
___________________________________________________________________________________

  reply	other threads:[~2019-03-11 20:55 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-10 15:59 Context NTG
2019-03-11 20:55 ` Wolfgang Schuster [this message]
2019-03-12 22:17   ` Fwd: " Jeroen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3204c3cd-1284-36a0-f389-05f01a8a2ebd@gmail.com \
    --to=wolfgang.schuster.lists@gmail.com \
    --cc=contextntg@gmail.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).