]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-1.4.1
authorfred <fred>
Wed, 27 Mar 2002 01:04:09 +0000 (01:04 +0000)
committerfred <fred>
Wed, 27 Mar 2002 01:04:09 +0000 (01:04 +0000)
buildscripts/mf-to-table.py
input/regression/script-stacked.ly [new file with mode: 0644]
lily/afm.cc
lily/include/request.hh
lily/musical-request.cc
lily/request.cc
lily/script-engraver.cc

index 8feec727d6e5a0ac84aec30db29aa3711ce38b6b..bb9c05919b505e274db243baa2494cba24e025a5 100644 (file)
@@ -90,7 +90,7 @@ def write_afm_char_metric(file, charmetric):
 
        f = 1000;
        tup = (charmetric['code'],
-               charmetric['width'] + charmetric['breapth'],
+              (charmetric['width'] + charmetric['breapth'])*f,
                charmetric['name'],
                -charmetric['breapth'] *f,
                -charmetric['depth']*f,
diff --git a/input/regression/script-stacked.ly b/input/regression/script-stacked.ly
new file mode 100644 (file)
index 0000000..0f48710
--- /dev/null
@@ -0,0 +1,5 @@
+
+\header { 
+texidoc = "Scripts may b4e stacked."
+}
+\score { \notes { c''->-. } }
index 6786afd72592ff34ac67c8070e9fce44040822a7..8fac391067b134cfdcdc21d4802ef13172128ae8 100644 (file)
@@ -22,7 +22,13 @@ Adobe_font_metric::Adobe_font_metric (AFM_Font_info * fi)
     {
       AFM_CharMetricInfo * c = fi->cmi + i;
 
-      ascii_to_metric_idx_[c->code] = i;
+      /*
+       Some TeX afm files contain code = -1. We don't know why, let's
+       ignore it.
+       
+       */
+      if (c->code >= 0)
+       ascii_to_metric_idx_[c->code] = i;
       name_to_metric_dict_[c->name] = i;
     }
 }
index c0090667d6beb97656cc05bac05f648c3b4e7a0c..677be604f9a1b9a636440c147831413ee82ee5b5 100644 (file)
@@ -41,7 +41,6 @@ class Script_req : public virtual Request
 public:
   void set_direction (Direction d);
   Direction get_direction () const;
-
   VIRTUAL_COPY_CONS (Music);
   Script_req ();
 };
index 463d0775e81c558d266b09e98e77b3d58c6465a1..e4866b6064908b5aa236a9b710713c86fd5617ef 100644 (file)
@@ -16,7 +16,6 @@ Tremolo_req::Tremolo_req ()
 {
 }
 
-
 void
 Melodic_req::transpose (Pitch delta)
 {
@@ -78,9 +77,6 @@ Note_req::Note_req ()
 }
 
 
-
-
-
 bool
 Span_req::do_equal_b (Request const*r) const
 {
@@ -106,7 +102,8 @@ Articulation_req::do_equal_b (Request const* r) const
 {
   Articulation_req const* a = dynamic_cast<Articulation_req const*> (r);
   
-  return a; //  &&  articulation_str_ == a->articulation_str_;
+  return a && gh_equal_p (get_mus_property ("articulation-type"),
+                         r->get_mus_property ("articulation-type"));
 }
 
 
@@ -114,11 +111,3 @@ Articulation_req::do_equal_b (Request const* r) const
 
 
 
-
-
-
-
-
-
-
-
index 7ad67285b1836a1b3ca8845dda7e4bc46538b2a6..844f942a35648b9bf4e4d81b0eec5c4cf0118d81 100644 (file)
@@ -9,8 +9,6 @@
 #include "request.hh"
 #include "debug.hh"
 
-
-
 bool
 Request::equal_b (Request const* r) const
 {
@@ -23,15 +21,12 @@ Request::do_equal_b (Request const*) const
   return true;
 }
   
-
 Request::Request ()
   : Music (SCM_EOL)
 {
   set_mus_property ("type", ly_symbol2scm ("request"));
 }
 
-
-
 Script_req::Script_req ()
 {
   set_direction (CENTER);
@@ -51,7 +46,6 @@ Script_req::get_direction () const
   return (isdir_b (d)) ?  to_dir (d) : CENTER;
 }
 
-
 Direction
 Span_req::get_span_dir () const
 {
@@ -68,3 +62,5 @@ Span_req::set_span_dir (Direction d)
 
 
 
+
+
index 4b2c44773d52436886114b1680264dc686db7b8f..256acd3dc47ef9c3ab6831b8d00a04d454ae48ac 100644 (file)
@@ -4,7 +4,6 @@
   (c)  1997--2001 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
-
 #include "script.hh"
 #include "side-position-interface.hh"
 #include "musical-request.hh"
@@ -12,7 +11,8 @@
 #include "rhythmic-head.hh"
 #include "engraver.hh"
 
-class Script_engraver : public Engraver {
+class Script_engraver : public Engraver
+{
   Link_array<Grob> script_p_arr_;
   Link_array<Articulation_req> script_req_l_arr_;
 
@@ -28,7 +28,6 @@ protected:
   virtual void acknowledge_grob (Grob_info);
 };
 
-
 void
 Script_engraver::initialize ()
 {
@@ -71,8 +70,7 @@ Script_engraver::process_music ()
       // todo -> use result of articulation-to-scriptdef directly as basic prop list.
       Grob *p =new Item (get_property ("Script"));
       art = gh_cdr (art);
-      p->set_grob_property ("molecule",
-                          gh_car (art));
+      p->set_grob_property ("molecule", gh_car (art));
 
       art = gh_cdr (art);
       bool follow_staff = gh_scm2bool (gh_car (art));
@@ -87,12 +85,10 @@ Script_engraver::process_music ()
       art = gh_cdr (art);
       SCM priority = gh_car (art);
 
-
       if (isdir_b (force_dir) && to_dir (force_dir))
        p->set_grob_property ("direction", force_dir);
       else if (to_dir (relative_stem_dir))
        p->set_grob_property ("side-relative-direction", relative_stem_dir);
-      
 
 
       /*