]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/open-type-font.cc (load_scheme_table): new function
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Sun, 12 Dec 2004 22:30:35 +0000 (22:30 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Sun, 12 Dec 2004 22:30:35 +0000 (22:30 +0000)
* lily/open-type-font.cc (attachment_point): new function.
(load_table): read LILC table

ChangeLog
buildscripts/mf-to-table.py
lily/open-type-font.cc

index bb164bac127469e8e1709f8d8c5a0603c8ee3b83..4595736b8665f947d10c5da5e5081bf6d2b7b673 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 2004-12-12  Han-Wen Nienhuys  <hanwen@xs4all.nl>
 
+       * lily/open-type-font.cc (load_scheme_table): new function
+
        * lily/dots.cc (print): replace - 
 
        * lily/open-type-font.cc (attachment_point): new function.
index e75b7c2efa1562287f1b1226b75b60c264bfc934..bd3ec180da591f6dbdbc5205db9d5e399056827d 100644 (file)
@@ -191,7 +191,8 @@ def write_global_lisp_table (file, global_info):
                'blot_diameter'
                ]
        for k in keys:
-               str = str + "(%s . %s)\n" % (k,global_info[k])
+               if global_info.has_key (k):
+                       str = str + "(%s . %s)\n" % (k,global_info[k])
 
        file.write (str)
 
index 50710eb3afce9e601bfbe10bcd1491c77be0a02a..c09e60ba8fbf7d3d355380d37e15ce4751dfa691 100644 (file)
@@ -43,7 +43,7 @@ SCM
 load_scheme_table (char const *tag_str, FT_Face face)
 {
   FT_ULong length = 0;
-  FT_Byte* buffer =load_table ("LILC", face, &length);
+  FT_Byte* buffer =load_table (tag_str, face, &length);
 
   SCM tab = SCM_EOL;
   if (buffer)
@@ -99,7 +99,7 @@ Offset
 Open_type_font::attachment_point (String glyph_name) const
 {
   SCM sym = ly_symbol2scm (glyph_name.to_str0 ());
-  SCM entry =  scm_hashq_ref (lily_character_table_, sym, SCM_BOOL_F);
+  SCM entry = scm_hashq_ref (lily_character_table_, sym, SCM_BOOL_F);
 
   Offset o;
   if  (entry == SCM_BOOL_F)
@@ -156,5 +156,5 @@ Open_type_font::name_to_index (String nm) const
 Real
 Open_type_font::design_size () const
 {
-  return 20.0;
+  return scm_to_double (scm_hashq_ref (lily_global_table_, ly_symbol2scm ("staffsize"), SCM_BOOL_F));
 }