ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* overlay problem with textext
@ 2006-11-22 14:42 Peter Rolf
  2006-11-23  2:03 ` Mojca Miklavec
  0 siblings, 1 reply; 6+ messages in thread
From: Peter Rolf @ 2006-11-22 14:42 UTC (permalink / raw)


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

Hi all,

the attached example works with the version from 17.11.|20.11., but not
with the current (22.11.06, 11:02) one. The problem seems to be in the
use of textext, as it 'works' (background is visible) when I exchange

  p:= textext.rt(\MPstring{FunnyFrame}) ;

with

  p:= nullpicture ;

I couldn't test the current version on contextgarden (still 20.11.,
which works ok), so I'm unsure, if it's my messy tex tree or a general
problem.

Greetings, Peter


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

\setupoutput[pdftex]
\setupcolors[state=start]

\startuseMPgraphic{FunnyFrame}
picture p ;
numeric o ;
path a,b ;
pair c ;

p:= textext.rt(\MPstring{FunnyFrame}) ;
o:= BodyFontSize ;
a:= unitsquare xyscaled(OverlayWidth,OverlayHeight) ;
p:= p shifted(2o,OverlayHeight-ypart center p) ;

drawoptions(withpen pencircle scaled 1pt withcolor .625red) ;
b:= a superellipsed .95 ;
fill b withcolor .85white ;
draw b ;
b:= (boundingbox p) superellipsed .95 ;
fill b withcolor .85white ;
draw b ;
draw p withcolor black ;
setbounds currentpicture to a ;
\stopuseMPgraphic


\defineoverlay[FunnyFrame]
  [\useMPgraphic{FunnyFrame}]

\defineframedtext[FunnyText]
  [frame=off,
   background=FunnyFrame]

\def\StartFrame{\startFunnyText}
\def\StopFrame{\stopFunnyText}
\def\FrameTitle#1%
{\setMPtext{FunnyFrame}{\hbox spread1em{\hss\strut#1\hss}}}

\setMPtext{FunnyFrame}{}%initializethetextvariable


\starttext

\FrameTitle{Test}
\StartFrame

\input zapf\relax

\StopFrame


\stoptext

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

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

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

end of thread, other threads:[~2006-11-23 10:22 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-11-22 14:42 overlay problem with textext Peter Rolf
2006-11-23  2:03 ` Mojca Miklavec
2006-11-23  4:08   ` Mojca Miklavec
2006-11-23  8:59     ` Taco Hoekwater
2006-11-23 10:01       ` Hans Hagen
2006-11-23 10:22         ` Peter Rolf

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