%=== xslhz.mf====================================================== % WpH May 19, 1997 modified to be dashed % ick 98-05-22 modified constants for gap, dash, endlen. % thick#:=1pt#; stepwidth#:=4pt#; define_pixels(stepwidth); define_blacker_pixels(thick); picture pic; gap=thick; %was 1.5; WpH new parameter: gap length. ick dash=1.6thick; % 2.5; WpH new parameter: dash length. ick endlen=-0.0thick; % -1.0; WpH new: length of dash at ends measured to center of gap. ick if unknown makedotted: makedotted:=0; fi % WpH slope=1/100; for i=1 upto 100: beginchar((i-1),0,0,0); x3=-x1=.5i*stepwidth; x2=y1=y3=0; y2=slope*i*stepwidth; penpos1(thick,90); penpos2(thick,90); penpos3(thick,90); penstroke z1e..z2e..z3e; % % wph start of added block to make gaps. if makedotted<>1: % variable makedotted has not been given a value. % Dotted lines will not be made. else: cullit; pickup pencircle scaled gap; cl:=abs(z3-z1); xcount:=(cl-2endlen)/(gap+dash); % number of gaps. xcount:=floor(xcount + .5); %round to nearest int number. xinc:=(cl-2endlen)/xcount; for j=0 upto xcount-1: xcur:=x1+endlen+j*xinc; undraw (xcur,y1)..(xcur,y2+.6thick); endfor; cullit; fi % wph end of added block to make gaps. % pic:= currentpicture; endchar; beginchar((128+i-1),0,0,0); currentpicture:= pic reflectedabout(origin,right); endchar; endfor end