X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scripts%2Fbuild%2Fmf-to-table.py;fp=scripts%2Fbuild%2Fmf-to-table.py;h=3f7b3cbb2fc88ff969711bcb2a478e5dee09df09;hb=941dff9d2a67080e0dd8474f1e70f0c72ace6424;hp=2fe43d2c77a3bca4ddb4dd694216fb593b4643a3;hpb=5a22d6233a39d3164e1ca043244794c268be4ad0;p=lilypond.git diff --git a/scripts/build/mf-to-table.py b/scripts/build/mf-to-table.py index 2fe43d2c77..3f7b3cbb2f 100644 --- a/scripts/build/mf-to-table.py +++ b/scripts/build/mf-to-table.py @@ -1,10 +1,23 @@ #!@PYTHON@ -# mf-to-table.py -- convert spacing info in MF logs . +# mf-to-table.py -- convert spacing info in MF logs . + +# This file is part of LilyPond, the GNU music typesetter. +# +# Copyright (C) 1997--2011 Han-Wen Nienhuys +# +# LilyPond is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. # -# source file of the GNU LilyPond music typesetter +# LilyPond is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. # -# (c) 1997--2009 Han-Wen Nienhuys +# You should have received a copy of the GNU General Public License +# along with LilyPond. If not, see . import os import sys @@ -42,7 +55,7 @@ font_family = 'feta' def parse_logfile (fn): autolines, deps = read_log_file (fn) charmetrics = [] - + global_info = { 'filename' : os.path.splitext (os.path.basename (fn))[0] } @@ -99,7 +112,7 @@ def parse_logfile (fn): elif tags[0] == 'parameter': global_info[tags[1]] = tags[2]; - + return (global_info, charmetrics, deps) @@ -137,7 +150,7 @@ def global_lisp_table (global_info): keys = ['staffsize', 'stafflinethickness', 'staff_space', 'linethickness', 'black_notehead_width', 'ledgerlinethickness', - 'design_size', + 'design_size', 'blot_diameter' ] for k in keys: @@ -146,7 +159,7 @@ def global_lisp_table (global_info): return str - + def ps_encoding (name, global_info, charmetrics): encs = ['.notdef'] * 256 for m in charmetrics: @@ -207,9 +220,9 @@ for opt in options: depfile_nm = a elif o == '--outdir' or o == '-o': outdir_prefix = a - elif o == '--lisp': + elif o == '--lisp': char_lisp_nm = a - elif o == '--global-lisp': + elif o == '--global-lisp': global_lisp_nm = a elif o == '--enc': enc_nm = a @@ -229,6 +242,8 @@ for filenm in files: enc_name = 'FetaEncoding' if re.search ('parmesan', filenm): enc_name = 'ParmesanEncoding' + elif re.search ('feta-noteheads', filenm): + enc_name = 'FetaNoteheadsEncoding' elif re.search ('feta-brace', filenm): enc_name = 'FetaBraceEncoding' elif re.search ('feta-alphabet', filenm):