%% %% This is file `cpctitle.mf', %% generated with the docstrip utility. %% %% The original source files were: %% %% pacioli.dtx (with options: `mfd') %% %% Copyright 1999 Peter R. Wilson %% %% This program is provided under the terms of the %% LaTeX Project Public License distributed from CTAN %% archives in directory macros/latex/base/lppl.txt. %% %% Author: Peter Wilson (CUA and NIST) %% now at: peter.r.wilson@boeing.com %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% MACRO SECTION %%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% def makebox(text rule) = for y=0,half_height,cap_height,body_height,x_height,-desc_depth,-body_depth: rule((l,y)t_,(r,y)t_); endfor % horizontals for x=l,r: rule((x,-body_depth)t_,(x,body_height)t_); endfor % verticals for x=u*(1+floor(1/u)) step u until r-1: rule((x,-body_depth)t_,(x,body_height)t_); endfor % more verticals if charic<>0: rule((r+charic*pt,h.o_),(r+charic*pt,.5h.o_)); fi % italic correction enddef; def proofpcbb(suffix $)(expr xoff, yoff) = if proofing > 0: x$bl = x$ - xoff; y$bl = y$ - yoff; % Bottom Left Hand Corner z$br = (x$bl+cap_height, y$bl); % BRHC z$tr = (x$bl+cap_height, y$bl+cap_height); % TRHC z$tl = (x$bl, y$bl+cap_height); % TLHC z$bc = 1/2[z$bl,z$br]; z$tc = 1/2[z$tl,z$tr]; % horizontal mid points pair hc, vc; hc = (2u,0); vc = (0,2u); pickup pensquare scaled 2; for s = z$bl, z$br, z$tr, z$tl, z$bc, z$tc: draw s-hc--s+hc; draw s-vc--s+vc; endfor fi enddef; let cm_arm=arm; vardef arm(suffix $,$$,@)(expr darkness, armjut) = % arm from |z$| to |z$$| numeric vjut_; vjut_= abs(bot y$l-bot y$$); x@0=good.x(x$$r-armjut); y@0=y$r; if serifs: y@1=y$l; z@1=z$$l+whatever*(z$$r-z@0); if x$$>=x$: x@2=x@1 - vjut_; else: x@2=x@1+vjut_; fi y@2=y$l; filldraw z$$l{z@1-z$$l}...darkness[z@1,.5[z@2,z$$l]]{z@2-z$$l}... z@2if x$$>=x$: {left} else: {right} fi ---z$l--z$r--z@0--z$$r..cycle; % arm and beak else: filldraw z$l--z$r--z@0--z$$r--cycle; fi % sans-serif arm penlabels(@0,@1,@2); enddef; vardef foot(suffix $, $$, @)(expr darkness, armjut) = % curved beak on E and L numeric vjut_; vjut_= abs(bot y$-bot y$$); x@0=good.x(x$$r-armjut); y@0=y$r; if serifs: y@1=y$l; z@1=z$$l+whatever*(z$$r-z@0); x@2=x@1-vjut_; y@2=y$l; filldraw z$$l{z@1-z$$l}...darkness[z@1,.5[z@2,z$$l] ]...z@2 ---z$l--z$r--z@0--z$$r--cycle; % arm and beak else: filldraw z$l--z$r--(x$$r,y$r)--(x$$r,y$l)--cycle; fi penlabels(@0,@1,@2); enddef; vardef pulled_super_arc.l(suffix $, $$)(expr darkness)= pair corner; if y$=y$r: corner=(x$l, y$$l); else: corner=(x$$l,y$l); fi z$l{corner-z$l}...(darkness)[corner, .5[z$l, z$$l]]{z$$l-z$l} ...{z$$l-corner}z$$l enddef; vardef pulled_super_arc.r(suffix $, $$)(expr darkness)= pair corner; if y$=y$r: corner=(x$r,y$$r); else: corner=(x$$r, y$r); fi z$r{corner-z$r}...(darkness)[corner, .5[z$r, z$$r]]{z$$r-z$r} ...z$$r{z$$r-corner} enddef; vardef pulled_arc@#(suffix $, $$)= pulled_super_arc@#($,$$)(eta) enddef; let cm_font_setup=font_setup; % Knuth's original font_setup def slim_font_setup = % trimmed font_setup for use with Pacioli caps only if monospace: let adjust_fit=mono_adjust_fit; def mfudged=fudged enddef; mono_charic#:=body_height#*slant; if mono_charic#<0: mono_charic#:=0; fi mono_charwd#:=9u#; define_whole_pixels(mono_charwd); else: let adjust_fit=normal_adjust_fit; def mfudged= enddef; fi define_pixels(u,width_adj,serif_fit,cap_serif_fit,jut,cap_jut,bar_height, dish,bracket,beak_jut,apex_o,apex_corr); define_whole_pixels(letter_fit,fine,crisp,tiny); define_whole_vertical_pixels(body_height,asc_height, cap_height,x_height,comma_depth,desc_depth); define_whole_blacker_pixels(hair,stem,cap_stem); define_whole_vertical_blacker_pixels(vair,dslab,slab); if slab.9fudge*$; fudged$:=fudged$+1; endfor endfor rule_thickness:=ceiling(rule_thickness#*hppp); heavy_rule_thickness:=ceiling(3rule_thickness#*hppp); oo:=vround(.5o#*hppp*o_correction)+eps; apex_oo:=vround(.5apex_o#*hppp*o_correction)+eps; lowres_fix(stem) 1.3; ess:=(ess#/stem#)*stem; cap_ess:=(cap_ess#/cap_stem#)*cap_stem; dw:=(curve#-stem#)*hppp; bold:=curve#*hppp+blacker; dh#:=.6designsize; more_super:=max(superness,sqrt .77superness); hein_super:=max(superness,sqrt .81225258superness); % that's $2^{-.3}$ clear_pen_memory; if fine=0: fine:=1; fi forsuffixes $=fine,crisp,tiny: %%% fine $ %%%% temporary formatting convention for MFT if $>fudged.hair: $:=fudged.hair; fi $.breadth:=$; pickup if $=0: nullpen else: pencircle scaled $; $:=$-eps fi; $.nib:=savepen; breadth_[$.nib]:=$; forsuffixes $$=lft,rt,top,bot: shiftdef($.$$,$$ 0); endfor endfor %%% @ $ %%%% restore ordinary formatting for $ min_Vround:=max(fine.breadth,crisp.breadth,tiny.breadth); if min_Vround