]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/include/open-type-font.hh (count): New method.
authorJan Nieuwenhuizen <janneke@gnu.org>
Fri, 17 Dec 2004 09:24:21 +0000 (09:24 +0000)
committerJan Nieuwenhuizen <janneke@gnu.org>
Fri, 17 Dec 2004 09:24:21 +0000 (09:24 +0000)
* mf/aybabtu.pe.in: Typo.

* lily/include/guile-compatibility.hh (SCM_HASHTABLE_P): Add compat.

ChangeLog
lily/include/guile-compatibility.hh
lily/include/open-type-font.hh
lily/open-type-font.cc
lily/system-start-delimiter.cc
mf/aybabtu.pe.in

index 0a094a71706e902629b23c49bc34f755b062b01c..bb21ff56fea75c33ee401ead54614146be7f7a12 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2004-12-17  Jan Nieuwenhuizen  <janneke@gnu.org>
+
+       * lily/include/open-type-font.hh (count): New method.
+
+       * mf/aybabtu.pe.in: Typo.
+
+       * Documentation/user/out/lilypond-internals.nexi (Scheme
+       functions): Typo.
+
+       * lily/include/guile-compatibility.hh (SCM_HASHTABLE_P): Add compat.
+
 2004-12-17  Han-Wen Nienhuys  <hanwen@xs4all.nl>
 
        * buildscripts/gen-bigcheese-scripts.py (i): use symbols for
index 6d3046570a59c5c39847b730d3e8ee2b326de9df..a0db2d3ff886bbf8482470721800dcb95502b2a4 100644 (file)
@@ -35,6 +35,7 @@ inline SCM scm_caadr (SCM x) { return SCM_CAADR (x); }
 inline SCM scm_cadar (SCM x) { return SCM_CADAR (x); }
 #define scm_gc_unregister_collectable_memory(a, b, c) scm_done_free (b)
 #define scm_gc_register_collectable_memory(a, b, c) scm_done_malloc (b)
+#define SCM_HASHTABLE_P(x) (SCM_VECTORP (x))
 #define SCM_VECTOR_REF(v, i) (SCM_VELTS ((v))[(i)])
 #define scm_from_bool(x) (x ? SCM_BOOL_T : SCM_BOOL_F)
 #define scm_from_int(x) SCM_MAKINUM (x)
index 1f9890e3429623573183d079f3eebc16df66053f..251868bc0ac5202734df9a4afd6c3968df516257 100644 (file)
@@ -36,6 +36,7 @@ public:
   static SCM make_otf (String);
   virtual ~Open_type_font();
   virtual Offset attachment_point (String) const;
+  virtual int count () const;
   virtual Box get_indexed_char (int) const;
   virtual int name_to_index (String) const;
   //virtual unsigned glyph_name_to_charcode (String) const;
index 9d0154a771fedaf681d8a637fbbc24e3e330ca7e..e17fbc1bd09f5aa966aa044513593676b0b7da5a 100644 (file)
@@ -138,7 +138,6 @@ Open_type_font::attachment_point (String glyph_name) const
   return point_constant * ly_scm2offset (att_scm);
 }
 
-
 Box
 Open_type_font::get_indexed_char (int signed_idx) const
 {
@@ -212,6 +211,12 @@ Open_type_font::glyph_name_to_index (String glyph_name) const
 }
 #endif
 
+int
+Open_type_font::count () const
+{
+  return ((Open_type_font*) this)->index_to_charcode_map_.size ();
+}
+
 Real
 Open_type_font::design_size () const
 {
index add49a7ca3a0d960f6cda60efd42d60373a2d5f1..81154f3cb2efaa836779cb61ca085e0e53e1a8ab 100644 (file)
@@ -162,7 +162,6 @@ Stencil
 System_start_delimiter::staff_brace (Grob *me, Real y)
 {
   Font_metric *fm = 0;
-
   /* We go through the style sheet to lookup the font file
      name.  This is better than using find_font directly,
      esp. because that triggers mktextfm for non-existent
@@ -182,6 +181,7 @@ System_start_delimiter::staff_brace (Grob *me, Real y)
     {
       int cmp = (lo + hi) / 2;
       b = fm->get_indexed_char (cmp);
+      //b = fm->get_indexed_char (fm->name_to_index ("brace" + to_string (cmp)));
       if (b[Y_AXIS].is_empty () || b[Y_AXIS].length () > y)
        hi = cmp;
       else
@@ -189,8 +189,7 @@ System_start_delimiter::staff_brace (Grob *me, Real y)
     }
   while (hi - lo > 1);
 
-  /* FIXME: ascii? */
-  Stencil stil (fm->get_indexed_char_stencil (lo));
+  Stencil stil (fm->find_by_name ("brace" + to_string (lo)));
   b = stil.extent_box ();
   b[X_AXIS] = Interval (0, 0);
 
index 566d7c0430a696b24556091aa8990cc41053e4ea..2e293060ba3cbe8c68452f1b04f0a26bf03b4716 100644 (file)
@@ -1,6 +1,6 @@
 #!@FONTFORGE@
 
-# all your braces are belong to us
+# all your brace are belong to us
 
 New();