summaryrefslogtreecommitdiff
path: root/fonts/orkhun/orhant11.mf
blob: 2725200e96e9f5280b38c65b242356f59d2c34dd (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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
mode_def testing=
         pixels_per_inch:=300*4;
         blacker:=.1;
         o_correction:=1;
         fillin:=.01;
         proofing:=2;
         fontmaking:=0;
         tracingtitles:=1;
enddef;
if unknown mode:
mode:=testing; fi
mode_setup;
turningcheck := 0;

if mode=testing: screenstrokes; fi

% parameters that control what a wedge looks like.
font_identifier := "bard";
font_size 11pt#;
u# := 1.2pt#;
pw# := 2u#;
runew# := 2pw#;
runeh# := 4pw#;
letter_fit# := 2pw#/3;
font_normal_space := 2runew#;
font_normal_stretch := 2runew#/3;
font_normal_shrink := 4runew#/3;

pen_thick# := u#/3;

define_pixels(pw, runew, runeh, pen_thick, letter_fit)

def penoct = makepen((.866,.5)--(.5,.866)--(-.5,.866)--(-.866,.5)
    --(-.866,-.5)--(-.5,-.866)--(.5,-.866)--(.866,-.5)--cycle)
enddef;

def runepen = pickup penoct scaled pen_thick rotated 45; enddef;

def adjust_fit(expr left_adj, right_adj) =
    l := -hround(left_adj*hppp)-letter_fit;
    interim xoffset := -l;
    charwd := charwd+2letter_fit# + left_adj + right_adj;
    r := l+hround(charwd*hppp);
    w := r-hround(right_adj*hppp) - letter_fit;
enddef;

extra_beginchar := extra_beginchar & "runepen;adjust_fit(0,0);";

def makebox(text r) =
    r((-letter_fit,0), (w+letter_fit,0));
    r((-letter_fit,h), (w+letter_fit,h));
    r((-letter_fit,0), (-letter_fit,h));
    r((w+letter_fit,0), (w+letter_fit,h));
    r((0,0), (0,h));
    r((w,0), (w,h));
    if charic<>0:
       r((w+charic*hppp,h.o_),(w+charic*hppp,.5h.o_)); 
    fi
enddef;

% ============================================
% Number 0,                       19.07.93 jhl
% ============================================
beginchar("T",pw#,runeh#,0);
z3 = (w/2, 0);        %z3 = (w, 0);
z1 = (w/7, h/4);      %z1 = (0, h/2);
z2 = (w/2, h/2);      %z2 = (w, h);
z4 = (6w/7, h/4);     %z4 = (2w, h/2);
z6 = (0, 7h/10);      %z6 = (-w/5, 4h/5);
z7 = (w, 7h/10);      %z7 = (11w/5, 4h/5);
z5 = (w/2, h);        %z5 = (w, 11h/6);
draw z1--z2--z4--z3--z1;
draw z2--z5--z6;
draw z5--z7;
endchar;

beginchar("A",pw#,runeh#,0);
z1 = (0, h/5);     %z1 = (0, h/3);
z2 = (w/2, 0);     %z2 = (w, 0);
z3 = (w/2, h);     %z3 = (w, 11h/6);
z4 = (w, 4h/5);    %z4 = (2w, 3h/2);
draw z1--z2--z3--z4;
endchar;

beginchar("B",pw#,runeh#,0);
z1 = (0, 0);       %z1 = (w/4, 0);
z2 = (w, 0);       %z2 = (3w/4, 0);
z3 = (-w/4, h/3);  %z3 = (0, h/2);
z7 = (5w/4, h/3);  %z7 = (w, h/2);
z5 = (w/2, h);     %z5 = (w/2, h);
z4 =.5[z3,z5];     %z4 =.5[z3,z5];
z6 =.5[z5,z7];     %z6 =.5[z5,z7];
draw z1--z6;
draw z2--z4;
draw z3--z5--z7;
endchar;
end