]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/font-interface.cc
* lily/font-interface.cc (get-font): take alist chain i.s.o. alist
[lilypond.git] / lily / font-interface.cc
index f8fbf0dfaf6ca81dcf0a000c0397ee8ff4d2c12c..65d4c6a5a89629fc40b4092a6a16f1014fa39c1b 100644 (file)
@@ -49,15 +49,10 @@ MAKE_SCHEME_CALLBACK(Font_interface, get_property_alist_chain, 1);
 SCM
 Font_interface::get_property_alist_chain (SCM grob)
 {
-
   Grob * g = unsmob_grob (grob);
   SCM_ASSERT_TYPE(g, grob, SCM_ARG1, __FUNCTION__, "grob");
   return  font_alist_chain (g);
-  
 }
-  
-  
-
 
 /*
   todo: split up this func, reuse in text_item? 
@@ -86,33 +81,28 @@ LY_DEFINE(ly_font_interface_get_default_font,
 }
 
 LY_DEFINE(ly_font_interface_get_font,"ly:get-font", 2, 0, 0,
-         (SCM grob, SCM alist),
-         "Return a font metric satisfying the font-qualifiers in @var{alist}.
-
-
-The font object represents the metric information of a font. Every font
-that is loaded into LilyPond can be accessed via Scheme. 
-
-LilyPond only needs to know the dimension of glyph to be able to process
-them. This information is stored in font metric files. LilyPond can read
-two types of font-metrics: @TeX{} Font Metric files (TFM files) and
-Adobe Font Metric files (AFM files).  LilyPond will always try to load
-AFM files first since they are more versatile.
-
-")
+         (SCM grob, SCM chain),
+         "Return a font metric satisfying the font-qualifiers in the alist chain @var{chain}.\n"
+"\n"
+"The font object represents the metric information of a font. Every font\n"
+"that is loaded into LilyPond can be accessed via Scheme. \n"
+"\n"
+"LilyPond only needs to know the dimension of glyph to be able to process\n"
+"them. This information is stored in font metric files. LilyPond can read\n"
+"two types of font-metrics: @TeX{} Font Metric files (TFM files) and\n"
+"Adobe Font Metric files (AFM files).  LilyPond will always try to load\n"
+"AFM files first since they are more versatile.\n"
+"\n"
+"An alist chain is a list of alists.\n")
 {
   Grob * gr  = unsmob_grob (grob);
   SCM_ASSERT_TYPE(gr, grob, SCM_ARG1, __FUNCTION__, "grob");
 
-  Font_metric*fm=
-    Font_interface::get_font (gr, gh_cons (alist,
-                                          Font_interface::font_alist_chain (gr)));
-
+  Font_metric*fm = Font_interface::get_font (gr, chain);
   return fm->self_scm();
 }
 
 
-
 Font_metric *
 Font_interface::get_font (Grob *me, SCM chain)
 {