ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Layers
@ 2012-08-06 18:06 Bill Meahan
  2012-08-06 18:47 ` Layers luigi scarso
  0 siblings, 1 reply; 4+ messages in thread
From: Bill Meahan @ 2012-08-06 18:06 UTC (permalink / raw)
  To: ConTeXt Mailing List


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

Is there any issue with "stacking" layers on top of each other?

What I want to do is create a newsletter nameplate consisting of a base 
layer containing a JPEG graphic of a logo, a partially-transparent layer 
above that to screen the graphic and a top layer containing the 
newsletter name in a large and fancy font ala' *The New York Times" & al.

I've already created a nameplate in Inkscape and can simply place the 
resultant graphic but I'd like to do the whole thing in ConTeXt if I can 
as I could easily use the technique in other situations.

I'll wikify any answers.

Thanks.
-- 
Bill Meahan, Westland, Michigan USA

“Writing is a combination of intangible
   creative fantasy and appallingly
   hard work.”

           —Anthony Powell


This message is digitally signed with an X.509 certificate
to prove it is from me and has not been altered since it was sent.


[-- Attachment #1.2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4933 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] 4+ messages in thread

* Re: Layers
  2012-08-06 18:06 Layers Bill Meahan
@ 2012-08-06 18:47 ` luigi scarso
  2012-08-06 19:27   ` Layers Bill Meahan
  0 siblings, 1 reply; 4+ messages in thread
From: luigi scarso @ 2012-08-06 18:47 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

On Mon, Aug 6, 2012 at 8:06 PM, Bill Meahan <wmeahan94@gmail.com> wrote:

> Is there any issue with "stacking" layers on top of each other?
>
> What I want to do is create a newsletter nameplate consisting of a base
> layer containing a JPEG graphic of a logo, a partially-transparent layer
> above that to screen the graphic and a top layer containing the newsletter
> name in a large and fancy font ala' *The New York Times" & al.
>
> I've already created a nameplate in Inkscape and can simply place the
> resultant graphic but I'd like to do the whole thing in ConTeXt if I can as
> I could easily use the technique in other situations.
>
> I'll wikify any answers.
>
>
http://archive.contextgarden.net/message/20090628.103925.be696f95.en.html


-- 
luigi

[-- Attachment #1.2: Type: text/html, Size: 1210 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] 4+ messages in thread

* Re: Layers
  2012-08-06 18:47 ` Layers luigi scarso
@ 2012-08-06 19:27   ` Bill Meahan
  0 siblings, 0 replies; 4+ messages in thread
From: Bill Meahan @ 2012-08-06 19:27 UTC (permalink / raw)
  To: ntg-context


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

On 08/06/2012 02:47 PM, luigi scarso wrote:

>
> http://archive.contextgarden.net/message/20090628.103925.be696f95.en.html
>

I'll add that to the wiki under Layers where it will be a little easier 
to find. :)

Many, many thanks!

-- 
Bill Meahan, Westland, Michigan USA

“Writing is a combination of intangible
   creative fantasy and appallingly
   hard work.”

           —Anthony Powell


This message is digitally signed with an X.509 certificate
to prove it is from me and has not been altered since it was sent.


[-- Attachment #1.2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4933 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] 4+ messages in thread

* layers
@ 2001-08-27 15:36 Hans Hagen
  0 siblings, 0 replies; 4+ messages in thread
From: Hans Hagen @ 2001-08-27 15:36 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 3265 bytes --]

At 01:50 PM 8/26/2001 +0100, Christopher Tipper wrote:

  >> with some notion of z-coordinates to allow layers to be superimposed
  >> using some notion of priority. Such a concept would not appear to
  >> be possible in the existing TeX architectural model, and is a
  >> significant barrier, in my view to commercial acceptance.

actually, it *can* be done in context sincethere is a layering model, and
actually one can do pretty sophisticated things with it -)

 >Page 1: The line passes through the central float. No doubt some solution
 >could be found whereby a blank white graphic is used as a background to
 >the float, but this is useless if the size of the text box is not known in
 >advance, and must be recalculated for every

This is indeed a good solution, just put a background there, how is the
text typeset now? Put it in a \framed and there you got your background.

 >instance. This is just not sensible, and points out the need for a more
 >general float mechanism. btw I have read Frank Mittelbach's work on
 >xo-pfloat for LaTeX 3, and forgive my obtuseness, but what this guy calls
 >'floats' are just too limited to be useful: for instance I saw no evidence
 >of floats that can be arbitrarily positioned on the page in a
 >deterministic manner.

the new multi column otr will give you some of the control that you want,
including spread graphics and so

 >Page 2: This issue arose during compilation of XML and involves a float in
 >the ConTeXt sense of the word i.e. a graphic. The problem is that the text
 >does not flow accurately past the graphic on the page, and this sort of
 >result would be extremely embarrassing if it were to be published. There
 >is nothing I as a publisher can do to solve this issue, which looks like
 >the result of a flawed algorithm.

\setuptolerance[verytolerant,stretch]

is your friend here.

 >Page 3 and 4: This is more of a question, and may not be an issue at all,
 >but would obviously benefit from a streamlined float handling interface.
 >Page 3 is the XSLT output for the web-page of this article (printed from
 >IE using Acrobat Distiller). Page 4 is the limited rendition I have with
 >the Context from the same XML source. As you can see I have a photograph
 >which has a rather long caption attached. Postioning the caption is
 >trivial in HTML, and I have written XSL templates to transform:

 >   {\placefigure[\XMLpar{image}{align}{}]%
 >     {none}%

 >How may one deal with the <caption> tags in a manner similar to the web
 >layout on page 3?

just put the caption text instead of {none}

or use \startcombination[1*1] {graphic} {text} \stopcombination

this kind of things are doable.

So, live is  not that hard, all you need is a bit of faith: see attachment
for an example of layering; you can imagine that there can be multiple
layers, you can also moves things around on layers, repeat them, etc etc;
[it's a nice mental exercise to figure out hwo this is done.] Now, given
that you can also hook in metapost code, imagine what you can do with
graphics spanning layers.

The issue is not so much if/how it can be done [since much more can be done
that people are made to believe, but to start thinking in how to apply
these techniques. I'm still in the proces of learning.

Hans

[-- Attachment #2: test.tex --]
[-- Type: text/plain, Size: 658 bytes --]

% output=pdftex

\starttext 

\setupcolors[state=start]

\definelayer[test][position=yes]
\defineoverlay[test][\composedlayer{test}]

\setupbackgrounds[page][background=test]

\useexternalfigure[koe 1][koe]
  [width=3cm,
   background=color,backgroundcolor=red,
   backgroundoffset=2cm]

\useexternalfigure[koe 2][koe]
  [width=3cm,
   background=color,backgroundcolor=green,
   backgroundoffset=2cm]

\input tufte 

\placefigure{}{\externalfigure[koe 1]} 

\input tufte 

\placefigure{}{\setlayer[test]{\externalfigure[koe 2]}}

\input tufte 

\placefigure{}{\setlayer[test][hoffset=-2cm]{\externalfigure[koe 2]}}

\input tufte 

\typefile{test}

\stoptext

[-- Attachment #3: Type: text/plain, Size: 373 bytes --]

-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------

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

end of thread, other threads:[~2012-08-06 19:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-06 18:06 Layers Bill Meahan
2012-08-06 18:47 ` Layers luigi scarso
2012-08-06 19:27   ` Layers Bill Meahan
  -- strict thread matches above, loose matches on Subject: below --
2001-08-27 15:36 layers Hans Hagen

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).