Commit f9eb499d authored by Elise's avatar Elise

first files

parents

Too many changes to show.

To preserve performance only 862 of 862+ files are displayed.

THE BBOLD SYMBOL FONT
6 APRIL 1994
This distribution contains the bbold symbol font:
INSTALL bbgreeku.mf bbold.dtx bbold17.mf bbold8.mf
README bbligs.mf bbold.mf bbold5.mf bbold9.mf
bbbase.mf bblower.mf bbold10.mf bbold6.mf bbparams.mf
bbgreekl.mf bbnum.mf bbold12.mf bbold7.mf bbpunc.mf
bbupper.mf
To install the fonts, you should:
* run METAFONT on the fonts, for example under Unix you say:
mf "\mode=localfont; input bbold5;"
mf "\mode=localfont; input bbold6;"
mf "\mode=localfont; input bbold7;"
mf "\mode=localfont; input bbold8;"
mf "\mode=localfont; input bbold9;"
mf "\mode=localfont; input bbold12;"
mf "\mode=localfont; input bbold17;"
* move bbold*.tfm into a TeX font metrics directory
* move bbold*.*pk into a TeX bitmaps directory
If you want to use the bbold font in LaTeX2e, you should:
* run LaTeX2e on bbold.dtx
* move bbold.sty and Ubbold.fd into a TeX inputs directory
* read the documentation in bbold.dvi
This file should only be distributed as part of the bbold
distribution.
Copyright 1994 Alan Jeffrey
THE BBOLD SYMBOL FONT
6 APRIL 1994
This directory contains the bbold symbol font. This is a geometric
sans serif blackboard bold font, for use in mathematics.
Read the INSTALL file for details of how to install the bbold
package.
Alan Jeffrey (alanje@cogs.susx.ac.uk)
% Blackboard bold base file, containing lots of horrible hacks.
% Alan Jeffrey, 12--18 Dec 1989.
% DIGITIZATION
% I'm doing all my own digitization, so I don't need help from MF.
autorounding := 0;
% To get the unsharp version of x#, say unsharp x#.
def unsharp = hppp * enddef;
% The only pen I'm working with is of size pen_size. This makes life
% rather easier. To find the x-coordinate whose left-hand edge is
% at hround x, say leftround x, and similarly for rightround,
% topround and bottomround.
def leftround expr x = hround x + 1/2 pen_size enddef;
def rightround expr x = hround x - 1/2 pen_size enddef;
def topround expr y = vround y - 1/2 pen_size enddef;
def bottomround expr y = vround y + 1/2 pen_size enddef;
% Using this, I can give the equivalent of define_whole_pixels...
def define_whole_top_pixels (text t) =
forsuffixes $ = t:
$ := topround unsharp $.#;
endfor
enddef;
def define_whole_bottom_pixels (text t) =
forsuffixes $ = t:
$ := bottomround unsharp $.#;
endfor
enddef;
% POINTS
% The point y~x is short for (x,y). The reason for switching the
% points around is that I find it easier to say Top~Left than
% (Left, Top).
primarydef x ~ y = (y,x) enddef;
% To find the average of two points, say p -+- q.
primarydef x ~ y = (y,x) enddef;
tertiarydef x -+- y = .5[x,y] enddef;
% To get the point 1/2fatness above p, say above p. This is useful
% for drawing lines fatness in width. Similarly we have commands
% below, leftof and rightof.
def above secondary p =
p + 1/2fatness * up
enddef;
def below secondary p =
p + 1/2fatness * down
enddef;
def leftof secondary p =
p + 1/2fatness * left
enddef;
def rightof secondary p =
p + 1/2fatness * right
enddef;
% The command farleftof is equivalent to leftof leftof, and similarly
% farrightof.
def farleftof secondary p =
p + fatness * left
enddef;
def farrightof secondary p =
p + fatness * right
enddef;
% To get curves with o-correction, we need to be able to move
% o pixels up or down.
def oabove secondary p =
p + o * up
enddef;
def obelow secondary p =
p + o * down
enddef;
% DECLARATIONS
% To declare a new variable foo of type T, say var (T) foo.
def var (text type) text declarations =
save declarations;
type declarations
enddef;
% PATHS
% Given a cyclic path p, outline p draws the path and fills the inside
% with white. This is stolen from the MF book, exercise 13.11.
def outline expr c =
begingroup
picture region;
region := nullpicture;
interim turningcheck := 0;
addto region contour c;
cull region dropping (0,0);
cullit;
addto currentpicture also -region;
cullit;
draw c
endgroup
enddef;
% Given a path p, leftside p is the path 1/2 fatness to its left,
% and similarly rightside.
def leftside primary apath =
apath shifted (1/2fatness * left)
enddef;
def rightside primary apath =
apath shifted (1/2fatness * right)
enddef;
% Given a path p, fatten p draws the leftside of p,
% the rightside of p, and joins them up with straight lines.
def fatten expr apath =
leftside apath
-- (reverse rightside apath)
-- cycle
enddef;
% Given a point p, splodge p draws an o-corrected circle of radius
% fatness around p.
def splodge expr apoint =
above apoint + o*up {right}
.. rightof apoint + o*right {down}
.. below apoint + o*down {left}
.. leftof apoint + o*left {up}
.. cycle
enddef;
% The command splodgel does the same, but doesn't close the cycle,
% and leaves the current point at the left of the circle.
def splodgel tertiary apoint =
leftof apoint + o*left {up}
.. above apoint + o*up {right}
.. rightof apoint + o*right {down}
.. below apoint + o*down {left}
.. leftof apoint + o*left {up}
enddef;
% Similarly, splodger leaves the current point at the right of the
% circle.
def splodger tertiary apoint =
rightof apoint + o*right {down}
.. below apoint + o*down {left}
.. leftof apoint + o*left {up}
.. above apoint + o*up {right}
.. rightof apoint + o*right {down}
enddef;
% CLIPPING
% sometime (p, q) gives the time along p when it intersects q.
def sometime (expr apath, bpath) =
xpart (apath intersectiontimes bpath)
enddef;
% othertime (p, q) gives another time at which p intersects q.
def othertime (expr apath, bpath) =
length apath - sometime (reverse apath) (reverse bpath)
enddef;
% firsttime (p, q) gives the smallest of sometime (p,q) and othertime (p,q).
def firsttime (expr apath, bpath) =
min (sometime (apath) (bpath), othertime (apath) (bpath))
enddef;
% lasttime (p, q) gives the largest of the two times.
def lasttime (expr apath, bpath) =
max (sometime (apath) (bpath), othertime (apath) (bpath))
enddef;
% We can then clip p with q by finding the subpath of p from 0 to
% the time p intersects q.
def cliponce (expr apath, clippath) =
subpath (0, sometime (apath) (clippath)) of apath
enddef;
% Similarly, if p intersects q twice, we can find the path between
% the two times it intersects with cliptwice.
def cliptwice (expr apath, clippath) =
subpath
(firsttime (apath) (clippath), lasttime (apath) (clippath))
of apath
enddef;
% Given a path p and two paths q and r which intersect p,
% we can find the path between when p crosses q and when p crosses r.
% someclipbetween (p, q, r) will always start at q and finish at r.
def someclipbetween (expr apath, firstclip, secondclip) =
subpath
(sometime (apath) (firstclip),
sometime (apath) (secondclip))
of
apath
enddef;
% firstclipbetween does the same, but if p intersects q and r more
% than once, it gives the first clipping.
def firstclipbetween (expr apath, firstclip, secondclip) =
subpath
(firsttime (apath) (firstclip),
firsttime (apath) (secondclip))
of
apath
enddef;
% lastclipbetween gives the last clipping.
def lastclipbetween (expr apath, firstclip, secondclip) =
subpath
(lasttime (apath) (firstclip),
lasttime (apath) (secondclip))
of
apath
enddef;
% We can join these together and clip fat lines.
def fatcliponce (expr apath, clippath) =
cliponce (leftside apath) (clippath)
-- someclipbetween (clippath) (leftside apath) (rightside apath)
-- reverse cliponce (rightside apath) (clippath)
-- cycle
enddef;
def fatcliptwice (expr apath, clippath) =
cliptwice (leftside apath) (clippath)
-- lastclipbetween (clippath) (leftside apath) (rightside apath)
-- cliptwice (rightside apath) (reverse clippath)
-- firstclipbetween (clippath) (rightside apath) (leftside apath)
-- cycle
enddef;
% BBCHAR.
% bbchar (c) (l#, w#, r#) (t#, b#) begins a character at code c,
% of width w# with l# gap at the left and r# gap at the right.
% It's topmost point is at t# and its bottommost point at b#.
% From these parameters we calculate Width (the width of the character
% in whole pixels) and hardTop and hardBottom (the exact top and bottom
% of the character). Top is then 1/2 pensize from the top of the character,
% and Bottom is 1/2 pensize from the bottom. This means if we draw a line
% through top, the top of it will exactly touch the top. We then calculate
% Left, Middle, and Right in the same way, using calculateLeftetc.
def bbchar
(expr code)
(expr sharphardLeft, sharpWidth, sharprightgap)
(expr sharphardTop, sharphardBottom) =
beginchar
(code)
(sharphardLeft + sharpWidth + sharprightgap)
(max (sharphardTop, 0pt#))
(max (-sharphardBottom, 0pt#));
save Top, Bottom, Horizon, hardTop, hardBottom,
Width, hardLeft, hardRight, Left, Right, Middle;
hardTop# = sharphardTop;
hardBottom# = sharphardBottom;
Width# = sharpWidth;
hardLeft# = sharphardLeft;
hardRight# = sharphardLeft + sharpWidth;
define_whole_pixels (Width);
define_whole_vertical_pixels (hardTop, hardBottom);
Top = topround hardTop;
Bottom = bottomround hardBottom;
Horizon = .5 [Top, Bottom];
calculateLeftetc;
pickup pencircle scaled pen_size;
enddef;
def calculateLeftetc =
hardLeft := floor (unsharp hardLeft#);
hardRight := hardLeft + Width;
Left := (hardLeft + 1/2pen_size);
Middle := (hardLeft + 1/2Width);
Right := (hardRight - 1/2pen_size);
enddef;
% bbcap is bbchar with the top at ATop# and the bottom at aBottom#.
def bbcap (expr code, leftgap, width, rightgap) =