From e0c6872cf40896c7be36b11dcc744620f10adf1d Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Mon, 2 Sep 2019 13:46:59 +0900 Subject: Initial commit --- fonts/recycle/recycle.mf | 167 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 167 insertions(+) create mode 100644 fonts/recycle/recycle.mf (limited to 'fonts/recycle/recycle.mf') diff --git a/fonts/recycle/recycle.mf b/fonts/recycle/recycle.mf new file mode 100644 index 0000000000..bbe03382b6 --- /dev/null +++ b/fonts/recycle/recycle.mf @@ -0,0 +1,167 @@ +% file recycle.mf, for recycling logo +% a quick hack (November 92) +% +% this code is totally unsupported! +% +% Ian Green (img@ai.ed.ac.uk) +% Mathematical Reasoning Group +% Department of AI, University of Edinburgh +% +% See copyright notice at the end of this file please. +% +mode_setup; +%mode:=smoke; +tracingonline :=1; + +def openit = openwindow currentwindow + from origin to (screen_rows,screen_cols) at (-50,600) +enddef; + +beginchar("A",1in#,1in# *.48/.52,0); +interim autorounding:=0; interim smoothing:=0; +if odd(w-h): h:=h-1; fi +thick := .02*w; + +curve := .05*w; %.07*(h-baseline); +ss := .3w; % main thickness of arrow; +hs := (8*thick+ss); % distance accorss tips of arrowhead + +forsuffixes $ = a,b,c: transform $; + forsuffixes e=l,r: path $e,$'e;endfor endfor; + +penpos.a1(thick,90); penpos.a2(thick,90); +penpos.a3(thick,30); penpos.a6(whatever,120); + +penpos.a9(thick,-150); penpos.a10(thick,-150); +penpos.a12(thick,-90); penpos.a13(thick,-30); penpos.a14(thick,-30); +penpos.a16(thick,60); penpos.a18(thick,150); penpos.a19(whatever,120); +penpos.a20(thick,150); + +%top edge +y.a1r = h; +x.a1 = x.a9r = .5*w; +y.a7r = y.a6r; +y.a6l = thick+y.a6r = y.a7l; + +pickup pencircle scaled .05pt; +z.a9r = z.a19l; % known intersection +% define curves at top +z.a1 - z.a12 = z.a2 - z.a1; +y.a13 = y.a10 = y.a20 = y.a3; +z.a2 - z.a12 = z.a3 - z.a10 = z.a20 - z.a13; +z.a3 - z.a2 = (curve,0) + ((curve,0)rotated -60); +z.a20 - z.a2 =(-curve,0) + ((curve,0)rotated -120); +z.a13 - z.a12 = (z.a3 - z.a2) rotated -120; + +%construct an imaginary point to ensure that the fold +% is in the correct place. this gives a9 +z.a20l - z.a9r = (t2,0) rotated 60; +z.a10r - z.a9r = (t2,0) rotated 120; +z.a20l - z.a17l = (whatever,0) rotated 60; + +%bottom edge, rotation point +z21 = (.5w,.5h); +z.a6r = (.5[z.a10,z.a3]) + (whatever,0) rotated -60; +z.a6r - z21 = (whatever,0) rotated 30; + +y.a16l = y.a6r + (2 * thick); + +z.a13l - z.a15l = (d1,0) rotated 60; +z.a13r - z.a15r = (d1-thick,0) rotated 60; +z.a17l - z.a15l = (ss,0) rotated -30; +z.a17r - z.a15r = (ss-(2 * thick),0) rotated -30; +z.a16l = 0.5[z.a17l,z.a15l]; +z.a9r = whatever[z.a17l,z.a20l]; +z.a19r - z.a17r = whatever * (z.a19l - z.a17l); +z.a4r - z.a8r = (ss,0) rotated 30; + +z.a5r - z.a7r = (hs,0) rotated 30; +z.23 = 0.5[z.a5r,z.a7r]; +z.24 = 0.5[z.a10,z.a3]; +z.23 = z.24 + (whatever,0) rotated -60; + +z.a8r - z.a9r = (whatever,0) rotated -60; +z.a4r - z.a3r = (whatever,0) rotated -60; +z.a8l = z.a9l + (whatever,0) rotated -60; +z.a4l = z.a3l + (whatever,0) rotated -60; + + +z.a8r = os[z.a7r, z.a5r]; +z.a4r = os[z.a5r, z.a7r]; +z.a5r - z.a4r = (whatever,0) rotated 30; + +% long base of arrow head: known points! +z.a6r - z.a5r = (whatever,0) rotated -120; + +z.a4l - z.a8l = (whatever,0) rotated 30; +z.a4l - z.a5l = z.a7l - z.a8l; +z.a8r - z.a7r = z.a5r - z.a4r; +z.a0 = z.a7r + (thick/(sind(30)/cosd(30)),0); + +z.a7l - z.a0 = (whatever,0) rotated 30; +z.a5l = z.a7l + whatever * (z.a5r - z.a7r); +z.a5l = z.a5r + (thick,0) rotated(60+90) + + whatever * (z.a5r - z.a6r); + +fill z.a12l -- z.a1r -- z.a1l -- z.a12r --cycle; + +fill z.a1r --- z.a2r ... z.a3r --- z.a4r -- z.a5r -- z.a6r -- z.a7r + -- z.a8r -- z.a9r --- z.a10r ... z.a12r ... z.a13r -- z.a15r + -- z.a15r -- z.a17r -- z.a19r + + -- z.a19l -- z.a17l-- z.a15l -- z.a15l --- z.a13l ... + z.a12l ... z.a10l --- z.a9l -- z.a8l -- z.a7l + -- z.a6l -- z.a5l -- z.a4l -- z.a3l ... + z.a2l --- z.a1l -- cycle; +% i like this bit + b = identity %shifted (0,whatever) + rotatedaround (z21,-120); + c = identity %shifted (whatever,0) + rotatedaround (z21,-240); + + for n = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19: + forsuffixes e = l,,r: forsuffixes $ = b,c: + z.$[n]e = z.a[n]e transformed $; endfor endfor endfor; + +fill z.b12l -- z.b1r -- z.b1l -- z.b12r --cycle; +fill z.b1r --- z.b2r ... z.b3r --- z.b4r -- z.b5r -- z.b6r -- z.b7r + -- z.b8r -- z.b9r --- z.b10r ... z.b12r ... z.b13r -- z.b15r + -- z.b15r -- z.b17r -- z.b19r + + -- z.b19l -- z.b17l-- z.b15l -- z.b15l --- z.b13l ... + z.b12l ... z.b10l --- z.b9l -- z.b8l -- z.b7l + -- z.b6l -- z.b5l -- z.b4l -- z.b3l ... + z.b2l --- z.b1l -- cycle; + +fill z.c12l -- z.c1r -- z.c1l -- z.c12r --cycle; +fill z.c1r --- z.c2r ... z.c3r --- z.c4r -- z.c5r -- z.c6r -- z.c7r + -- z.c8r -- z.c9r --- z.c10r ... z.c12r ... z.c13r -- z.c15r + -- z.c15r -- z.c17r -- z.c19r + + -- z.c19l -- z.c17l-- z.c15l -- z.c15l --- z.c13l ... + z.c12l ... z.c10l --- z.c9l -- z.c8l -- z.c7l + -- z.c6l -- z.c5l -- z.c4l -- z.c3l ... + z.c2l --- z.c1l -- cycle; + + for n = 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23: + forsuffixes e = l,,r: forsuffixes $ = a,b,c: + labels($[n]e); endfor endfor endfor + +endchar; +bye +% Copyright (C) 1993 Ian Green +% +% This program is free software; you can redistribute it and/or modify +% it under the terms of the GNU General Public License as published by +% the Free Software Foundation; either version 1, or (at your option) +% any later version. +% +% This program is distributed in the hope that it will be useful, +% but WITHOUT ANY WARRANTY; without even the implied warranty of +% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +% GNU General Public License for more details. +% +% You should have received a copy of the GNU General Public License +% along with this program; if not, write to the Free Software +% Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + -- cgit v1.2.3