summaryrefslogtreecommitdiff
path: root/fonts/bguq/bguq.mf
blob: e5d72aefe96c91475409eb4ed80dd40bf1679b4f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
% This file contains a single character, the Begriffsschrift
% universal quantifier (the code being the same as for the cm
% "blank space" symbol).
%
% $Id: bguq.mf,v 1.6 2012/07/22 23:12:01 jjg Exp $

% from mflogo/logo.mf, modified to have a variable superness

def super_half(suffix i,j,k)(expr s) =
 draw z.i{0, y.j-y.i}
    ... (s[x.j, x.i], s[y.i, y.j]){z.j-z.i}
    ... z.j{x.k-x.i,0}
    ... (s[x.j, x.k], s[y.k, y.j]){z.k-z.j}
    ... z.k{0, y.k-y.j}
enddef;

mode_setup;

proofing := 2;
define_pixels(u);
define_pixels(bglt);

% The width 14.4u# is chosen so that at 10pt (where u=20/36)
% the width is 8pt, as in the original begriff quantifier.
% The depth is the same as for the descender for the base
% font (fraktur in this case)

beginchar(oct"040", 14.4u# - 2bglt#, 0, desc_depth#);

  % the super value determines the shape of the bowl
  % which is a superellipse: 
  % - at 1.000 is a rectangle,
  % - at 0.707 (i.e., sqrt(2)/2) is an ellipse
  % - at 0.500 is a diamond
  % we use a value a little larger than 0.707 giving a
  % stroke which is noticably squarer than an ellipse

  numeric super;
  super := 0.77;
    
  y1 = y3 = bglt/2;
  y2 + d = bglt/2;
  x1 = w - x3 = -bglt/2;
  x2 = w/2;
    
  pickup pencircle scaled bglt;
  super_half(1,2,3,super);

  % clean off the ends of the (round pen) stroke  

  unfill
    (x1-bglt/2,y1) --
    (x3+bglt/2,y3) --
    (x3+bglt/2,y3+bglt/2) --
    (x1-bglt/2,y1+bglt/2) --
    cycle;
  
  penlabels(1,2,3);
  
endchar;

end

% fin