From 07f57f0989b2d8ce23bbd08ca8e5d7ed793dcfd8 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Fri, 8 Dec 2006 23:41:43 +0000 Subject: metapost package textpath 1.5 git-svn-id: svn://tug.org/texlive/trunk@2643 c570f23f-e606-0410-a88d-b1316a301751 --- .../doc/metapost/textpath/textpathfigs.mp | 216 +++++++++++++++++++++ 1 file changed, 216 insertions(+) create mode 100644 Master/texmf-dist/doc/metapost/textpath/textpathfigs.mp (limited to 'Master/texmf-dist/doc/metapost/textpath/textpathfigs.mp') diff --git a/Master/texmf-dist/doc/metapost/textpath/textpathfigs.mp b/Master/texmf-dist/doc/metapost/textpath/textpathfigs.mp new file mode 100644 index 00000000000..0e09b6c3b23 --- /dev/null +++ b/Master/texmf-dist/doc/metapost/textpath/textpathfigs.mp @@ -0,0 +1,216 @@ +input latexmp +setupLaTeXMP(preamblefile="textpathfigs"); +input textpath + +prologues := 1; + +beginfig(1); + draw textpath("Greetings from MetaPost!", fullcircle scaled 50bp, 0) + withcolor (0.2,0.2,0.6); +endfig; + +beginfig(2); +path p; + p := reverse fullcircle rotated -90 scaled 50bp; + draw textpath("Greetings from MetaPost!", p, 0.5) withcolor (0.2,0.2,0.6); +endfig; + + +beginfig(3); +path p; + p := reverse fullcircle rotated -90; + draw textpathFont("\usefont{T1}{pzc}{m}{n}\huge", "Happy Birthday to", + p scaled 400bp, 0.5) withcolor (1, 0.6, 0.2); + draw textpathFont("\usefont{T1}{bch}{m}{n}\large", "Daisy Duck!", + p scaled 350bp, 0.5) withcolor (0.9, 0.3, 0.1); +endfig; + + +beginfig(4); +path p; + p := (origin--(1bp,0bp)) scaled 75bp; + draw p withcolor .8white; + draw textpath("Greetings from MetaPost!", p, 0.5) withcolor (0.2,0.2,0.6); + p := p shifted (0,-20bp); + draw p withcolor .8white; + textpathClip := 0; + draw textpath("Greetings from MetaPost!", p, 0.5) withcolor (0.2,0.2,0.6); +endfig; + +textpathClip := 1; + + +beginfig(5); +path p; +string f; + f := "\usefont{T1}{pzc}{m}{n}\Large"; + p := subpath (5.7,6.3) of fullcircle scaled 1400bp; + draw p withcolor .8white; + textpathRepeat := 3; + textpathStretch := 0; + textpathHSpace := 10pt; + draw textpathFont(f, "Happy Birthday", p, 0.5) withcolor (1, 0.6, 0.2); +endfig; + +textpathRepeat := 1; +textpathStretch := 1; + + +beginfig(6); +string f; +path p; +picture pic; +numeric lenp, lenpic, tb, k; +color daisy; + daisy := (0.9, 0.3, 0.1); + f := "\usefont{T1}{bch}{m}{n}\fontsize{40pt}{40pt}\selectfont"; + p := subpath (2.7,5.3) of reverse fullcircle rotated -90 scaled 100bp; + draw p withcolor .8white; + textpathAbsRotation := 1; + draw textpathFont(f, "Daisy", p, 0.5) withcolor (white-daisy) + 0.8daisy; + textpathAbsRotation := 0; + draw textpathFont(f, "Daisy", p, 0.5) withcolor daisy; + pic := strToPic(f & "\spaced{Daisy}"); + draw textpathPic(pic, p, 0.5, "debug"); +endfig; + + +beginfig(7); +string f, t; +path heart; + f := "\usefont{T1}{pzc}{m}{it}\tiny"; + t := "Love"; + heart := halfcircle shifted (-0.5bp,0bp)..{dir-50}(0bp,-1.5bp); + heart := heart--reverse heart reflectedabout ((0,0),(0,1))--cycle; + heart := heart scaled 60bp; + textpathRotation := 90; + textpathLetterSpace := 1pt; + textpathRepeat := 30; + draw textpathFont(f, t, heart, 0.5) withcolor red+0.1green; +endfig; + +textpathRepeat := 1; + + +beginfig(8); +path p; +string f, t; +picture pic; + f := "\usefont{T1}{fwb}{m}{n}\Large";% From the emerald package + t := "Don't panic! Don't panic! Don't panic!"; + p := origin + for i:=1 upto 20: ..(i, sind(i*45)) endfor; + p := p xscaled 20 yscaled 35; + textpathRotation := 0; + textpathAbsRotation := 1; + textpathLetterSpace := 6pt; + pic := textpathFont(f, t, p, 0); + background := black; + bboxmargin := 30bp; + unfill bbox pic; + draw pic withcolor red+green; +endfig; + +textpathAbsRotation := 0; +textpathLetterSpace := 0pt; + + +beginfig(9); +string f; +path p; + f := "\usefont{T1}{pzc}{m}{it}\fontsize{56pt}{56pt}\selectfont"; + p := reverse fullcircle rotated 33 scaled 150bp; + textpathLetterSpace := -3pt; + draw textpathFont(f, "Pro \&", p, 1) withcolor (1, 0.6, 0.2); + textpathLetterSpace := 0pt; + f := "\usefont{T1}{pzc}{m}{it}\fontsize{48pt}{48pt}\selectfont"; + p := fullcircle rotated 33 scaled 145bp; + draw textpathFont(f, "Con\<{\kern-2pt}tra", p, 0.0) withcolor (1, 0.6, 0.2); +endfig; + + +beginfig(10); +string f; +path p; +numeric r,h,w; +picture pic; +% Font Brush Script Italic is available on CTAN. + f := "\usefont{T1}{pbsi}{xl}{n}\fontsize{2.1pt}{2.1pt}\selectfont"; + w := 210bp; + h := .276w; + r := .19h; + p := (-.5w,0)--(-.5w,.5h-r)--quartercircle rotated -90 scaled (2r) + shifted (-.5w,.5h)--(0,.5h); + p := p--reverse p reflectedabout ((0,-1),(0,1)); + p := p--reverse p reflectedabout ((-1,0),(1,0))--cycle; + draw p withpen pensquare scaled 3.5pt; + textpathRepeat := 30; + textpathShift := -.6pt; + draw textpathFont(f, "Fa\ss' Dich kurz!", p, 0.5) withcolor white; + label(textext + ("\usefont{T1}{bfu}{mb}{n}\fontsize{22pt}{22pt}\selectfont Telephonzelle"), + origin);% Bitstream Futura +endfig; + +textpathRepeat := 1; +textpathShift := 0pt; + + +beginfig(11); +path p; + p := reverse fullcircle rotated -90 scaled 50bp; + draw p withcolor .8white; + draw textpathRaw("Greetings from MetaPost!", p, 0.5) withcolor (0.2,0.2,0.6); +endfig; + + +beginfig(12); +path p; + p := reverse halfcircle scaled 80bp; + draw p withcolor .8white; + draw textpathRaw("\LARGE$x^2+y^2=r^2$", p, 0.5) withcolor (0.2,0.2,0.6); +endfig; + + +beginfig(13); +path p; + p := reverse halfcircle xscaled 160bp yscaled 80; + draw p withcolor .8white; + textpathShift := 7pt; + draw textpathRaw("\Large$\frac{(x-u)^2}{a^2}+\frac{(y-v)^2}{b^2}=1$", p, 0.5) withcolor (0.2,0.2,0.6); +endfig; + + +beginfig(14); +path p; + p := reverse halfcircle xscaled 160bp yscaled 80; + draw p withcolor .8white; + textpathShift := 9pt; + textpathFancyStrokes := 0; + draw textpathRaw("\Large$y = v+b\sqrt{1-\frac{(x-u)^2}{a^2})}$", p, 0.5) withcolor (0.2,0.2,0.6); +endfig; + + +beginfig(15); +path p; + p := reverse halfcircle xscaled 160bp yscaled 80; + draw p withcolor .8white; + textpathShift := 9pt; + textpathFancyStrokes := 1; + textpathCureSqrt := 0; + draw textpathRaw("\Large$y = v+b\sqrt{1-\frac{(x-u)^2}{a^2})}$", p, 0.5) withcolor (0.2,0.2,0.6); +endfig; + +beginfig(16); +path p; + p := reverse halfcircle xscaled 160bp yscaled 80; + draw p withcolor .8white; + textpathShift := 9pt; + textpathFancyStrokes := 1; + textpathCureSqrt := 1; + draw textpathRaw("\Large$y = v+b\sqrt{1-\frac{(x-u)^2}{a^2})}$", p, 0.5) withcolor (0.2,0.2,0.6); +endfig; + +textpathShift := 0pt; + +end -- cgit v1.2.3