From 16b713b9b9616d70c4a1b12506952098c01c5706 Mon Sep 17 00:00:00 2001 From: Han-Wen Nienhuys Date: Sun, 1 Jan 2006 18:54:10 +0000 Subject: [PATCH] * mf/GNUmakefile (NCSB_PATH): add vars for NCSB. (install-ncsb-ttf): new target. * scm/define-grobs.scm (all-grob-descriptions): add font-interface to LyricHyphen. * lily/lyric-hyphen.cc (print): multiply hyphen height by font-size --- ChangeLog | 13 +++++++++++++ VERSION | 2 +- lily/font-size-engraver.cc | 2 +- lily/lyric-hyphen.cc | 5 ++++- mf/GNUmakefile | 31 ++++++++++++++++++++++++------- scm/define-grobs.scm | 1 + 6 files changed, 44 insertions(+), 10 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3bd3023df7..52276ebd1b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,18 @@ +2006-01-01 Han-Wen Nienhuys + + * mf/GNUmakefile (NCSB_PATH): add vars for NCSB. + (install-ncsb-ttf): new target. + + * scm/define-grobs.scm (all-grob-descriptions): add font-interface + to LyricHyphen. + + * lily/lyric-hyphen.cc (print): multiply hyphen height by + font-size + 2005-12-31 Han-Wen Nienhuys + * VERSION: release 2.7.26 + * mf/GNUmakefile (install-fc-cache): remove old font.cache-1 files. 2005-12-30 Han-Wen Nienhuys diff --git a/VERSION b/VERSION index f7539f89a2..14c743e705 100644 --- a/VERSION +++ b/VERSION @@ -1,6 +1,6 @@ PACKAGE_NAME=LilyPond MAJOR_VERSION=2 MINOR_VERSION=7 -PATCH_LEVEL=26 +PATCH_LEVEL=27 MY_PATCH_LEVEL= diff --git a/lily/font-size-engraver.cc b/lily/font-size-engraver.cc index 6f39a4507e..25304bc713 100644 --- a/lily/font-size-engraver.cc +++ b/lily/font-size-engraver.cc @@ -52,7 +52,7 @@ Font_size_engraver::acknowledge_font (Grob_info gi) ADD_ACKNOWLEDGER (Font_size_engraver, font); ADD_TRANSLATOR (Font_size_engraver, - /* doc */ "Puts fontSize into font-relative-size grob property.", + /* doc */ "Puts fontSize into font-size grob property.", /* create */ "", /* accept */ "", /* read */ "fontSize", diff --git a/lily/lyric-hyphen.cc b/lily/lyric-hyphen.cc index 6988209c74..19f27a766d 100644 --- a/lily/lyric-hyphen.cc +++ b/lily/lyric-hyphen.cc @@ -49,7 +49,10 @@ Hyphen_spanner::print (SCM smob) Real lt = me->layout ()->get_dimension (ly_symbol2scm ("linethickness")); Real th = robust_scm2double (me->get_property ("thickness"), 1) * lt; - Real h = robust_scm2double (me->get_property ("height"), 0.5); + Real font_size_step = robust_scm2double (ly_chain_assoc_get (ly_symbol2scm ("font-size"), chain, SCM_BOOL_F), + 0.0); + Real h = robust_scm2double (me->get_property ("height"), 0.5) + * pow (2.0, font_size_step / 6.0); // interval? diff --git a/mf/GNUmakefile b/mf/GNUmakefile index 6c613432fa..4ecf990190 100644 --- a/mf/GNUmakefile +++ b/mf/GNUmakefile @@ -34,11 +34,10 @@ FETA_FONTS = $(FETA_MF_FILES:.mf=) SVG_FILES = $(OTF_FILES:%.otf=%.svg) $(ALL_FONTS:%=$(outdir)/%.svg) -$(outdir)/aybabtu.otf-table: $(BRACES:%=$(outdir)/feta-braces-%.otf-table) - cat $^ > $@ - -$(outdir)/aybabtu.otf-gtable: $(BRACES:%=$(outdir)/feta-braces-%.otf-gtable) - echo '(design_size . 20)' > $@ +NCSB_FILES=c059013l c059016l c059033l c059036l +NCSB_TTFS=$(addprefix $(outdir)/,$(addsuffix .ttf, $(NCSB_FILES))) +NCSB_PATH=/usr/share/fonts/default/Type1 +NCSB_INSTALL_DIR=$(local_lilypond_datadir)/fonts/otf LOG_FILES = $(FETA_MF_FILES:%.mf=$(outdir)/%.log) LISP_FILES = $(FETA_MF_FILES:%.mf=$(outdir)/%.lisp) @@ -52,6 +51,16 @@ FETA_LIST_FILES = $(FETA_MF_FILES:%.mf=$(outdir)/%list.ly) ENCODING_FILE=$(findstring $( $@ + +$(outdir)/aybabtu.otf-gtable: $(BRACES:%=$(outdir)/feta-braces-%.otf-gtable) + echo '(design_size . 20)' > $@ + + # only for fonts which # # 1. are mentioned in font.scm @@ -245,5 +254,13 @@ local-uninstall: -rm -f $(DESTDIR)$(local_lilypond_datadir)/dvips/map -rmdir $(DESTDIR)$(local_lilypond_datadir)/dvips -foe: - @echo mf:$(FETA_MF_FILES) + +$(outdir)/%.ttf: $(NCSB_PATH)/%.pfb + $(foreach i,$(NCSB_FILES), \ + $(FONTFORGE) -script $(buildscript-dir)/pfx2ttf.fontforge \ + $(NCSB_PATH)/$(i).pfb $(NCSB_PATH)/$(i).afm \ + $(outdir)/$(i).ttf && ) true + +install-ncsb-ttf: $(NCSB_TTFS) + $(INSTALL) -d $(DESTDIR)$(NCSB_INSTALL_DIR) + $(INSTALL) $(NCSB_TTFS) $(DESTDIR)$(NCSB_INSTALL_DIR) diff --git a/scm/define-grobs.scm b/scm/define-grobs.scm index 3970b861a2..96a7cc87a1 100644 --- a/scm/define-grobs.scm +++ b/scm/define-grobs.scm @@ -886,6 +886,7 @@ (Y-extent . (0 . 0)) (meta . ((class . Spanner) (interfaces . (lyric-interface + font-interface lyric-hyphen-interface spanner-interface)))))) -- 2.39.5