X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;ds=sidebyside;f=lily%2Ffont-metric.cc;h=12d8807831d5d57023ef905de5bdb501a8d46972;hb=c96554f25f55ed14f893e492a6d8e2317d26b244;hp=03625cc946b6bd9c405bb157611c82d2a0fbbf41;hpb=d8082113a0df616e7beabc0417c3590a3fac7320;p=lilypond.git diff --git a/lily/font-metric.cc b/lily/font-metric.cc index 03625cc946..12d8807831 100644 --- a/lily/font-metric.cc +++ b/lily/font-metric.cc @@ -3,7 +3,7 @@ source file of the GNU LilyPond music typesetter - (c) 1999--2006 Han-Wen Nienhuys + (c) 1999--2009 Han-Wen Nienhuys Mats Bengtsson (the ugly TeX parsing in text_dimension) */ @@ -31,7 +31,7 @@ Font_metric::design_size () const Stencil Font_metric::find_by_name (string s) const { - replace_all (s, '-', 'M'); + replace_all (&s, '-', 'M'); int idx = name_to_index (s); Box b; @@ -40,7 +40,7 @@ Font_metric::find_by_name (string s) const { expr = scm_list_3 (ly_symbol2scm ("named-glyph"), self_scm (), - scm_makfrom0str (s.c_str ())); + ly_string2scm (s)); b = get_indexed_char (idx); } @@ -185,14 +185,10 @@ Font_metric::word_stencil (string str) const } Stencil -Font_metric::text_stencil (string str) const +Font_metric::text_stencil (string /* str */) const { - SCM lst = scm_list_3 (ly_symbol2scm ("text"), - this->self_scm (), - scm_makfrom0str (str.c_str ())); - - Box b = text_dimension (str); - return Stencil (b, lst); + programming_error("Cannot get a text stencil from this font"); + return Stencil (Box (), SCM_EOL); } Box