lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Metafont code cleanup


From: Janek Warchoł
Subject: Metafont code cleanup
Date: Fri, 6 Dec 2013 20:22:46 +0100

Sorry, i forgot that the first line will be email subject.

FYI: this patch doesn't (i.e. _shouldn't_) change anything in how the
font looks or in the code describing glyphs.  It aims to just change
organization a bit.

Please review!
(but if you have little time, i'd rather have you review the next one)

Janek

2013/12/6  <address@hidden>:
> Reviewers: wl_gnu.org, hanwenn, Bertrand Bordage,
>
> Message:
> Hi,
>
> I decided that it's a good time to clean the Metafont code a bit.  Apart
> from what i've done, it'd be nice to do one more thing: move files to
> subfolders.
>
> We have several "master files" (feta-flags-generic,
> feta-alphabet-generic, feta-braces-generic, feta-noteheads-generic,
> feta-other-generic, parmesan-noteheads-generic and
> parmesan-other-generic).  All other files are just included into these.
> I think that it would be good to have a subdir for each of these fonts -
> it would make things *much* clearer.
>
> However, this requires changes in the makefile and it seems that i
> cannot handle them (i have no experience with make whatsoever, and no
> time to learn it now :/).  Maybe someone'd like to help?  I suppose that
> for someone familiar with make it'd be 20-30 minutes of work.
>
> You can see the changes separated into commits on
> dev/janek/metafont-cleanup
>
> thanks!
> Janek
>
> Description:
> Commits (in reverse chronological order):
>
> font: abstract stuff away, unify, format
>
> * move common elements to separate input files,
> * move brace-drawing procedure to separate file,
> * rename feta-alphabet to feta-alphabet-generic
>   to conform to the convention,
> * rename feta-generic to feta-other-generic
>   (because this file is not for the whole font,
>   but just some glyphs that aren't in their own
>   subfonts); similarly parmesan-generic,
> * remove feta-test-generic.mf and other testing
>   files that were just polluting the code,
> * put testing code in one place,
> * remove spurious filename comments,
> * unify formatting and indentation.
>
>
> font: clean up staffline-display in testing mode
>
> Previous testing code was a mix of hideous copy&paste with
> non-obvious passing glyph outlines around, which attempted
> to produce additional glyphs in testing mode, so that there
> would be both on-staffline and on-staffspace variations.
>
> That code was completely unreadable and unmaintainable.
>
> Instead i've introduced a global variable that determines
> how the stafflines will be printed relative to the glyphs.
> To see alternative configuration, just change that value.
>
>
> font: rename draw_staff to draw_staff_if_debugging
>
> Previous name was confusing: the stafflines are actually
> not drawn unless 'test' is set to non-zero value.
>
>
> feta accidentals: split into several files
>
> Please review this at https://codereview.appspot.com/38530043/
>
> Affected files (+1473, -2501 lines):
>   A mf/common-modules-and-initialization.mf
>   A mf/debugging-settings.mf
>   A mf/declare-autometric-parameters.mf
>   M mf/feta-accidentals.mf
>   A mf/feta-accidentals/arrow.mf
>   A mf/feta-accidentals/flats.mf
>   A mf/feta-accidentals/naturals.mf
>   A mf/feta-accidentals/parenthesis.mf
>   A mf/feta-accidentals/sharps.mf
>   A mf/feta-alphabet-generic.mf
>   D mf/feta-alphabet.mf
>   M mf/feta-alphabet11.mf
>   M mf/feta-alphabet13.mf
>   M mf/feta-alphabet14.mf
>   M mf/feta-alphabet16.mf
>   M mf/feta-alphabet18.mf
>   M mf/feta-alphabet20.mf
>   M mf/feta-alphabet23.mf
>   M mf/feta-alphabet26.mf
>   M mf/feta-braces-a.mf
>   M mf/feta-braces-b.mf
>   M mf/feta-braces-c.mf
>   M mf/feta-braces-d.mf
>   M mf/feta-braces-e.mf
>   M mf/feta-braces-f.mf
>   M mf/feta-braces-g.mf
>   A mf/feta-braces-generic.mf
>   M mf/feta-braces-h.mf
>   M mf/feta-braces-i.mf
>   M mf/feta-braces.mf
>   M mf/feta-clefs.mf
>   M mf/feta-flags-generic.mf
>   M mf/feta-flags11.mf
>   M mf/feta-flags13.mf
>   M mf/feta-flags14.mf
>   M mf/feta-flags16.mf
>   M mf/feta-flags18.mf
>   M mf/feta-flags20.mf
>   M mf/feta-flags23.mf
>   M mf/feta-flags26.mf
>   D mf/feta-generic.mf
>   M mf/feta-macros.mf
>   M mf/feta-noteheads-generic.mf
>   M mf/feta-noteheads.mf
>   M mf/feta-noteheads11.mf
>   M mf/feta-noteheads13.mf
>   M mf/feta-noteheads14.mf
>   M mf/feta-noteheads16.mf
>   M mf/feta-noteheads18.mf
>   M mf/feta-noteheads20.mf
>   M mf/feta-noteheads23.mf
>   M mf/feta-noteheads26.mf
>   A mf/feta-other-generic.mf
>   M mf/feta-rests.mf
>   M mf/feta-scripts.mf
>   D mf/feta-test-generic.mf
>   D mf/feta-test11.mf
>   D mf/feta-test13.mf
>   D mf/feta-test16.mf
>   D mf/feta-test20.mf
>   D mf/feta-test23.mf
>   D mf/feta-test26.mf
>   M mf/feta-timesignatures.mf
>   M mf/feta11.mf
>   M mf/feta13.mf
>   M mf/feta14.mf
>   M mf/feta16.mf
>   M mf/feta18.mf
>   M mf/feta20.mf
>   M mf/feta23.mf
>   M mf/feta26.mf
>   M mf/parmesan-clefs.mf
>   D mf/parmesan-generic.mf
>   M mf/parmesan-noteheads-generic.mf
>   M mf/parmesan-noteheads11.mf
>   M mf/parmesan-noteheads13.mf
>   M mf/parmesan-noteheads14.mf
>   M mf/parmesan-noteheads16.mf
>   M mf/parmesan-noteheads18.mf
>   M mf/parmesan-noteheads20.mf
>   M mf/parmesan-noteheads23.mf
>   M mf/parmesan-noteheads26.mf
>   A mf/parmesan-other-generic.mf
>   M mf/parmesan11.mf
>   M mf/parmesan13.mf
>   M mf/parmesan14.mf
>   M mf/parmesan16.mf
>   M mf/parmesan18.mf
>   M mf/parmesan20.mf
>   M mf/parmesan23.mf
>   M mf/parmesan26.mf
>
>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]