source file of the GNU LilyPond music typesetter
- (c) 1999--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+ (c) 1999--2005 Han-Wen Nienhuys <hanwen@xs4all.nl>
*/
#include "all-font-metrics.hh"
Pango_font *
All_font_metrics::find_pango_font (PangoFontDescription *description,
Real magnification,
- Real output_scale)
+ Real output_scale
+ )
{
pango_font_description_set_size (description,
gint (magnification *
{
if (be_verbose_global)
progress_indication ("[" + String (pango_fn));
-
+
Pango_font *pf = new Pango_font (pango_ft2_fontmap_,
- RIGHT,
description,
- output_scale);
+ output_scale
+ );
+
val = pf->self_scm ();
pango_dict_->set (key, val);
pf->unprotect ();
if (path.length () > 0)
return path;
- SCM kpath = ly_lily_module_constant ("ly:kpathsea-find-file");
- if (ly_is_procedure (kpath))
+ static SCM proc;
+ if (!proc)
+ {
+ SCM module = scm_c_resolve_module ("scm kpathsea");
+ proc = scm_c_module_lookup (module, "ly:kpathsea-find-file");
+ proc = scm_variable_ref (proc);
+ }
+
+ if (ly_is_procedure (proc))
{
- SCM kp_result = scm_call_1 (kpath, scm_makfrom0str (name.to_str0 ()));
+ SCM kp_result = scm_call_1 (proc, scm_makfrom0str (name.to_str0 ()));
if (scm_is_string (kp_result))
return ly_scm2string (kp_result);
}