% This file is part of vntex. License: GPL.
%
mode_setup;
font_setup;

if known debug:
    set_lowercase;
    input vnaccent.mf;
    input_li_fam;
    set_uppercase;
    input vnaccent.mf;
    input_ur_fam;
    let next=endinput
else:
    let next=\
fi
next;

input itall.mf;  % lower case (minuscules)
input romanu.mf; % upper case (majuscules)
input itald.mf;  % numerals
input italp.mf;  % ampersand, question marks, currency sign
input punct.mf;  % punctuation symbols common to roman and italic text

set_lowercase;
input vnaccent.mf;
input vnlai.mf;          % modified/accented "a"
input vnlei.mf;          % modified/accented "e"
input vnlii.mf;          % accented "i"
input vnloi.mf;          % modified/accented "o"
input vnlui.mf;          % modified/accented "u"
input vnlyi.mf;          % accented "y"
input vnldi.mf;          % d-bar

set_uppercase;
input vnaccent.mf;
input vnuar.mf;          % modified/accented "A"
input vnuer.mf;          % modified/accented "E"
input vnuir.mf;          % accented "I"
input vnuor.mf;          % modified/accented "O"
input vnuur.mf;          % modified/accented "U"
input vnuyr.mf;          % accented "Y"
input vnudr.mf;          % D-bar

input t1supp.mf;         % suplement for T1 encoding

font_coding_scheme := "Vietnamese TeX Font Encoding";
boundarychar := oct"027";
font_slant slant; 
font_x_height x_height#;
% font_cap_height cap_height#;
% font_asc_height asc_height#;
% font_acc_cap_height (cap_height# + acc_height#);
% font_desc_depth desc_depth#;
% font_max_height (max(asc_height#, body_height#, cap_height# + acc_height#));
% font_max_depth (max(desc_depth#, paren_depth#, the_ogonek_depth#));
% font_digit_width % set inside the digits file
% font_cap_stem % set after the programme of the capital I
% font_baselineskip max(1.2*designsize, body_height# + paren_depth#);

if monospace: 
    font_normal_space 9u#; % no stretching or shrinking
    font_quad 18u#;
    font_extra_space 9u#;
    letter_fit# := letter_fit := 0;
    input vnmligtb.mf; % do the ligature programmes for monospaced fonts
else: 
    font_normal_space 6u# + 2letter_fit#;
    font_normal_stretch 3u#;
    font_normal_shrink 2u#;
    font_quad 18u# + 4letter_fit#;
    font_extra_space 2u#;
    input vniligtb.mf; % do the ligature programmes for proportionally spaced fonts
fi

endinput;
