]> git.donarmstrong.com Git - lilypond.git/commitdiff
release: 1.3.106 release/1.3.106
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 10 Nov 2000 10:16:07 +0000 (11:16 +0100)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 10 Nov 2000 10:16:07 +0000 (11:16 +0100)
============

* Makeinfo html documentation generation fixes.

1.3.105.

29 files changed:
CHANGES
Documentation/header.html.in
Documentation/user/GNUmakefile
NEWS
VERSION
input/test/manual-clef.ly [new file with mode: 0644]
lily/clef-engraver.cc
lily/include/context-specced-music.hh
lily/key-engraver.cc
lily/key-performer.cc
lily/lily-guile.cc
lily/music-iterator.cc
lily/note-heads-engraver.cc
lily/parser.yy
lily/piano-pedal-engraver.cc
lily/property-engraver.cc
lily/request-chord-iterator.cc
lily/timing-engraver.cc
lily/translator-group.cc
ly/engraver.ly
ly/property.ly
make/mutopia-rules.make
make/out/lilypond.lsm
make/out/lilypond.spec
mutopia/F.Schubert/standchen.ly
scm/element-descriptions.scm
scm/lily.scm
scm/translator-description.scm
scripts/mudela-book.py

diff --git a/CHANGES b/CHANGES
index 492d53fa969aa8822b6d3d6e9e3f63ac11f0a980..ecca8a8e2de7bcc8653525188cf668c06931f32b 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -3,8 +3,23 @@
 
 * Makeinfo html documentation generation fixes.
 
-1.3.104.jcn1
-============
+1.3.105.uu1
+===========
+
+* Remove Bar_req, \bar is now a frontend to setting Score.whichBar
+
+* Move Context_specced_music::translator_{type,id}_str_ into music
+properties.
+
+* Don't make line breaks during note playing.
+
+* Clef engraver rewrite. Clef-engraver is now controlled through
+properties clefPosition, clefGlyph, clefOctavation. The \clef command
+is just a front-end to these, see scm/lily.scm, function
+clef-name-to-properties.  See also input/test/manual-clef.ly
+
+1.3.105
+=======
 
 * Bit of temporary makefile hacking to stay in sync with makeinfo patch.
 
@@ -218,7 +233,7 @@ input/test/instrument-name-grandstaff.ly
 
 * Moved Text_script_req's text_ member into mus-property.
 
-* Renamed ChordName to ChordNames, for consistancy.
+* Renamed ChordName to ChordNames, for consistency.
 
 * Resurrected most of chord names, superscripting and kerning
   is currently broken, though.
@@ -368,7 +383,6 @@ Break_align_item::space-alist, Chord_name::chord-name-function
 
 * Added \property combineParts: part combiner switched off by default.
 
-
 * Remove all print methods.
 
 * Use Scope::try_retrieve if possible.
index 6ad66e9fce2336b53a3becb9f294658c7688bca3..6bd96bbf5a9988650f4599ba4aba2fa92a307daa 100644 (file)
@@ -81,10 +81,9 @@ which substitutes some @AT_VARIABLES@ as well.
       <tr><td><font size=-1>
        <a href="@TOP@short-examples.html">Short examples</a><br>
        <a href="@TOP@long-examples.html">Longer examples</a><br>
-       <a href="http://sca.uwaterloo.ca/Mutopia/">Mutopia Project</a><br>
-       <a href="http://www.geocities.com/Vienna/Studio/1714/scarlattimus.html">Jonh Sankey</a><br>
-       <a href="http://www4.smart.net/~jcovey/scores/">Jeff Covey</a><br>
-       <a href="http://www.alqualonde.de/lilypond.html">Dirk Lattermann</a><br>
+       <a href="http://www.mutopiaproject.org/">Mutopia Project</a><br>
+
+       <a href="http://appel.lilypond.org/wiki/index.php?DownloadLilyPondScores">Other URLs</a><br>
        <br>
       </td></tr>
       <tr><td bgcolor="#e8e8ff">
index feafeb8fcd6706c86b7908267d0572fc6e0af4ad..b586a9a4f59211a7c533f522c2a265759b6048f4 100644 (file)
@@ -38,6 +38,7 @@ DEEP_HTML_FILES = $(outdir)/lilypond/lilypond.html $(outdir)/lilypond-internals/
 local-WWW: $(HTML_FILES) $(datafiles) $(PS_GZ_FILES) $(DEEP_HTML_FILES)
        $(SHELL) $(buildscript-dir)/install-info-html.sh --dir=$(outdir) lilypond lilypond-internals
        $(MAKE) footify
+       -mkdir $(outdir)/lilypond 
        ln -f $(outdir)/*.png $(outdir)/lilypond
        $(MAKE) deep-footify
 
diff --git a/NEWS b/NEWS
index 2f2f4347ae63b7dfe9d17865e134590631ef3016..fd86eddfd993953035312f45eb082588657fc443 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -17,6 +17,8 @@ internals: LilyPond is smaller, cleaner, more flexible, etc.
 
 * New font selection scheme similar to Latex-NFSS.
 
+* Medieval notation features: clefs, custodes
+
 * Piano pedal support, Arpeggios, Custodes
 
 * MIDI: dynamics, tempo changes
@@ -38,6 +40,8 @@ internals: LilyPond is smaller, cleaner, more flexible, etc.
 
 * Finished ouverture Coriolan as full orchestral score example.
 
+* Self-documenting: generated internal documentation.
+
 * AsciiScript: ASCII-art output 
 
 * Translations into Japanese, French and Russian
diff --git a/VERSION b/VERSION
index 8276e5dc4795627fc8559f8709031ab5a6ba3292..a70f97234ccd39ef0a99bde7ad07910508f57ffb 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -1,8 +1,8 @@
 PACKAGE_NAME=LilyPond
 MAJOR_VERSION=1
 MINOR_VERSION=3
-PATCH_LEVEL=105
-MY_PATCH_LEVEL=tca1
+PATCH_LEVEL=106
+MY_PATCH_LEVEL=
 
 # use the above to send patches: MY_PATCH_LEVEL is always empty for a
 # released version.
diff --git a/input/test/manual-clef.ly b/input/test/manual-clef.ly
new file mode 100644 (file)
index 0000000..f6b08e0
--- /dev/null
@@ -0,0 +1,26 @@
+\version "1.3.105";
+
+%{
+
+Test clef engraver by setting \property directly. \clef is merely a front-end  to this.
+
+%}
+
+\score { \notes {
+  \property Staff.clefGlyph = #"clefs-F"
+  \property Staff.clefPosition = #2
+  c'4
+  \property Staff.clefGlyph = #"clefs-G"
+  c'4
+  \property Staff.clefGlyph = #"clefs-C"
+
+  c'4
+       \property Staff.clefOctavation = #7 
+  c'4
+       \property Staff.clefOctavation = #0 
+       \property Staff.clefPosition = #0
+  c'4
+       \clef "bla";
+  c'4
+
+}}
index 83eb544afe64ebca957910a826afa3d4cdc79ce4..818e3544a0f93c0c417ceda23a183713a797534c 100644 (file)
@@ -32,86 +32,81 @@ public:
   Clef_engraver ();
 
   Direction octave_dir_;
-  bool  first_b_;
 
 protected:
   virtual void do_process_music ();
   virtual void do_pre_move_processing ();
   virtual void do_creation_processing ();
   virtual void do_post_move_processing ();
-  virtual bool do_try_music (Music*);
   virtual void acknowledge_element (Score_element_info);
 
 private:
   Item * clef_p_;
   Item * octavate_p_;
   Clef_change_req * clef_req_l_;
-  
+
+  SCM prev_glyph_;
+  SCM prev_cpos_;
+  SCM prev_octavation_;
   void create_clef ();
-  bool set_type (String);
+  void set_central_c (SCM, SCM, SCM);
+  void set_glyph ();
 };
 
 Clef_engraver::Clef_engraver ()
 {
-  first_b_ = true;
   clef_p_ = 0;
   clef_req_l_ = 0;
   octave_dir_ = CENTER;
   octavate_p_ = 0;
+
+  /*
+    will trigger a clef at the start since #f != '()
+   */
+  prev_cpos_ = prev_glyph_ = SCM_BOOL_F;
 }
 
-bool
-Clef_engraver::set_type (String s)
+void
+Clef_engraver::set_central_c (SCM glyph,SCM clefpos, SCM octavation)
 {
-  if (s.right_str (2) == "_8") // Down one octave
-    {
-      octave_dir_ = DOWN;
-      s = s.left_str (s.length_i () - 2);
-    }
-  else if (s.right_str (2) == "^8") // Up one octave
-    {
-      octave_dir_ = UP;
-      s = s.left_str (s.length_i () - 2);
-    }
-  else
-    octave_dir_ = CENTER;
+  prev_cpos_ = clefpos;
+  prev_glyph_ = glyph;
+  prev_octavation_ = octavation;
 
-  SCM c = get_property ("supportedClefTypes");
   SCM p = get_property ("clefPitches");
-  
-  if (gh_list_p (c))
+  int c0_position =  0;
+  if (gh_list_p (p))
     {
-      SCM found = scm_assoc (ly_str02scm (s.ch_C ()), c);
+      SCM found = scm_assoc (glyph, p);
       if (found == SCM_BOOL_F)
-       return false;
-      
-      SCM glyph = gh_cadr (found);
-      SCM pos = gh_caddr (found);
-
-      daddy_trans_l_->set_property ("clefGlyph", glyph);
-      daddy_trans_l_->set_property ("clefPosition", pos);
-
-      found = scm_assoc (glyph, p);
-      if (found == SCM_BOOL_F)
-       return false;
+       {
+         c0_position =0;
+       }
+      else
+       {
+         c0_position =  gh_scm2int (gh_cdr (found));
 
-      int c0_position = gh_scm2int (pos) + gh_scm2int (gh_cdr (found));
-      daddy_trans_l_->set_property ("centralCPosition", gh_int2scm (c0_position));
+         if (gh_number_p (octavation))
+             c0_position -= gh_scm2int (octavation);
+      
+         if (gh_number_p (clefpos))
+           c0_position += gh_scm2int (clefpos);
+       }
+      
     }
-
-  int c0_position = gh_scm2int (get_property ("centralCPosition"));
-  c0_position -= (int)octave_dir_ * 7;
   daddy_trans_l_->set_property ("centralCPosition", gh_int2scm (c0_position));
+}
 
+void
+Clef_engraver::set_glyph ()
+{
+  SCM glyph_sym = ly_symbol2scm ("glyph");
+  SCM glyph = get_property ("clefGlyph");
 
   SCM basic = ly_symbol2scm ("Clef");
-  SCM gl = ly_symbol2scm ("glyph");
-
-  daddy_trans_l_->execute_single_pushpop_property (basic, gl, SCM_UNDEFINED);
-  daddy_trans_l_->execute_single_pushpop_property (basic, gl,
-                                                  get_property ("clefGlyph"));
-
-  return true;
+  
+  daddy_trans_l_->execute_single_pushpop_property (basic, glyph_sym, SCM_UNDEFINED);
+  daddy_trans_l_->execute_single_pushpop_property (basic, glyph_sym, glyph);
 }
 
 /** 
@@ -154,31 +149,9 @@ Clef_engraver::acknowledge_element (Score_element_info info)
 void
 Clef_engraver::do_creation_processing ()
 {
-  daddy_trans_l_->set_property ("clefPosition", gh_int2scm (0));
-  daddy_trans_l_->set_property ("clefGlyph", SCM_EOL);
-  daddy_trans_l_->set_property ("centralCPosition", gh_int2scm (0));
-
-  SCM def = get_property ("defaultClef");
-  if (gh_string_p (def))
-    {
-      set_type (ly_scm2string (def));
-    }
 }
 
-bool
-Clef_engraver::do_try_music (Music * r_l)
-{
-  if (Clef_change_req *cl = dynamic_cast <Clef_change_req *> (r_l))
-    {
-      clef_req_l_ = cl;
-      String t = ly_scm2string (cl->get_mus_property ("clef-type"));
-      if (!set_type (t))
-       cl->origin ()->warning (_ ("unknown clef type"));
 
-      return true;
-    }
-  return false;
-}
 
 void
 Clef_engraver::create_clef ()
@@ -186,16 +159,17 @@ Clef_engraver::create_clef ()
   if (!clef_p_)
     {
       Item *c= new Item (get_property ("Clef"));
-      announce_element (c, clef_req_l_);
+      announce_element (c, 0);
 
       Staff_symbol_referencer::set_interface (c);
       
       clef_p_ = c;
     }
   Staff_symbol_referencer::set_position (clef_p_,
-                                        gh_scm2int (get_property ("clefPosition")
-                                                    ));
-  if (octave_dir_)
+                                        gh_scm2int (get_property ("clefPosition")));
+
+  SCM oct =  get_property("clefOctavation");
+  if (gh_number_p (oct) && gh_scm2int (oct))
     {
       Item * g = new Item (get_property ("OctavateEight"));
 
@@ -204,18 +178,28 @@ Clef_engraver::create_clef ()
       g->set_parent (clef_p_, Y_AXIS);
       g->set_parent (clef_p_, X_AXIS);
 
-      g->set_elt_property ("direction", gh_int2scm (octave_dir_));
+      g->set_elt_property ("direction", gh_int2scm (sign (gh_scm2int (oct))));
       octavate_p_ = g;
-      announce_element (octavate_p_, clef_req_l_);
+      announce_element (octavate_p_, 0);
     }
 }
 
 void
 Clef_engraver::do_process_music ()
 {
-  if (clef_req_l_ || first_b_)
+  SCM glyph = get_property ("clefGlyph");
+  SCM clefpos = get_property ("clefPosition");
+  SCM octavation = get_property ("clefOctavation");
+  
+  if (scm_equal_p (glyph, prev_glyph_) == SCM_BOOL_F
+      || scm_equal_p (clefpos, prev_cpos_) == SCM_BOOL_F
+      || scm_equal_p (octavation, prev_octavation_) == SCM_BOOL_F)    
     {
+      set_glyph();
+      set_central_c (glyph, clefpos, octavation);
+       
       create_clef ();
+
       clef_p_->set_elt_property ("non-default", SCM_BOOL_T);
     }
 }
@@ -246,14 +230,11 @@ Clef_engraver::do_pre_move_processing ()
 
       octavate_p_ = 0;
     }
-
-  first_b_ = 0;
 }
 
 void
 Clef_engraver::do_post_move_processing ()
 {
-  clef_req_l_ = 0;
 }
 
 ADD_THIS_TRANSLATOR (Clef_engraver);
index abcf2c40f3710a810c88c1edc86761df273c4322..e6eb7c8b0f1128d6021d94f2d4632fe7cafe67ec 100644 (file)
 
 class Context_specced_music : public Music_wrapper
 {
-public:
+
+/*
   /// The kind of translation needed for this music.  
   String translator_type_str_;
 
   /// what identification for the translation unit
   String translator_id_str_;
+*/
+public:  
   Context_specced_music (Music*);
   VIRTUAL_COPY_CONS(Music);
 
index eff8a73a20a169b9eba72f8cc127a371639370fd..46f4d3f656f5ec93ea7d69d4c644533425ed9524 100644 (file)
@@ -150,7 +150,7 @@ void
 Key_engraver::read_req (Key_change_req const * r)
 {
   SCM p = r->get_mus_property ("pitch-alist");
-  if (p == SCM_UNDEFINED)
+  if (!gh_pair_p (p))
     return;
 
   SCM n = scm_list_copy (p);
index 79fdac637e6468d4ed7882c82a072b88f93921df..f13cc85d7d6f828b5bf053497623dcdd335878a4 100644 (file)
@@ -26,7 +26,8 @@ Key_performer::~Key_performer ()
 void
 Key_performer::do_process_music ()
 {
-  if (key_req_l_ && key_req_l_->get_mus_property ("pitch-alist") != SCM_UNDEFINED)
+  if (key_req_l_ &&
+      gh_list_p (key_req_l_->get_mus_property ("pitch-alist")))
     {
       audio_p_ = new Audio_key (); // *key_req_l_->key_);
       Audio_element_info info (audio_p_, key_req_l_);
index 7f56dbcf3e73575c67ca34829d0a0a7dea100cdd..91096bce8efe606d8f758e9ba17a6e281548a658 100644 (file)
@@ -390,11 +390,6 @@ wave_sweep_goodbye (void *dummy1, void *dummy2, void *dummy3)
 }
 #endif
 
-SCM
-undefd ()
-{
-  return SCM_UNDEFINED;
-}
 
 #include "version.hh"
 SCM
@@ -413,7 +408,7 @@ init_functions ()
   scm_make_gsubr ("ly-version", 0, 0, 0, (Scheme_function_unknown)ly_warning);  
   scm_make_gsubr ("ly-gulp-file", 1,0, 0, (Scheme_function_unknown)ly_gulp_file);
   scm_make_gsubr ("dir?", 1,0, 0, (Scheme_function_unknown)ly_isdir_p);
-  scm_make_gsubr ("undefd", 0,0, 0, (Scheme_function_unknown)undefd);  
+
   scm_make_gsubr ("ly-number->string", 1, 0,0, (Scheme_function_unknown) ly_number2string);
 
 
index 4a2c2ec95ec5468b9da751d264899ac854f3fe7c..08f454fae1e303b8d255c0579729d7f2876735ad 100644 (file)
@@ -185,8 +185,18 @@ Music_iterator::init_translator (Music *m, Translator_group *report_l)
   music_l_ = m;
   if (Context_specced_music * csm =dynamic_cast<Context_specced_music *> (m))
     {
-      Translator_group* a =report_l->
-       find_create_translator_l (csm->translator_type_str_, csm->translator_id_str_);
+      SCM ct = csm->get_mus_property ("context-type");
+      String c_type;
+      if (gh_string_p (ct))
+         c_type =  ly_scm2string (ct);
+      
+      String c_id;
+      SCM ci = csm->get_mus_property ("context-id");
+      if (gh_string_p (ci))
+       c_id = ly_scm2string (ci);
+      
+      Translator_group* a
+       =report_l->find_create_translator_l (c_type, c_id);
 
       set_translator (a);
       
index 9bcd1dad7b087c7d56902b168ea7da788830108d..ec47cb0442d293f67f874d045d35a240ab535cf1 100644 (file)
@@ -5,15 +5,14 @@
 */
 
 #include "rhythmic-head.hh"
-#include "engraver.hh"
 #include "paper-def.hh"
 #include "musical-request.hh"
 #include "dots.hh"
 #include "dot-column.hh"
 #include "staff-symbol-referencer.hh"
-#include "engraver.hh"
-#include "pqueue.hh"
 #include "item.hh"
+#include "score-engraver.hh"
+#include "warn.hh"
 
 /**
   make balls and rests
@@ -29,6 +28,7 @@ public:
   Note_heads_engraver();
   
 protected:
+  virtual void do_post_move_processing ();
   virtual bool do_try_music (Music *req_l) ;
   virtual void do_process_music();
   virtual void do_pre_move_processing();
@@ -129,6 +129,26 @@ Note_heads_engraver::do_pre_move_processing()
   note_req_l_arr_.clear ();
 }
 
+void
+Note_heads_engraver::do_post_move_processing ()
+{
+  /* TODO:make this settable?
+   */
+  if (note_end_mom_ > now_mom())
+    {
+      Score_engraver * e = 0;
+      Translator * t  =  daddy_grav_l ();
+      for (; !e && t;  t = t->daddy_trans_l_)
+       {
+         e = dynamic_cast<Score_engraver*> (t);
+       }
+
+      if (!e)
+       programming_error ("No score engraver!");
+      else
+       e->forbid_breaks ();    // guh. Use properties!
+    }
+}
 
 
 
index 76d6d7e1696848d414a0d474d7138c3c455b2acb..6853bc91fd8e0eb963130a490d45f858d8428d66 100644 (file)
@@ -251,7 +251,7 @@ yylex (YYSTYPE *s,  void * v_l)
 %type <outputdef>  music_output_def_body
 %type <request> shorthand_command_req
 %type <request>        post_request 
-%type <request> command_req verbose_command_req
+%type <music> command_req verbose_command_req
 %type <request>        extender_req
 %type <request> hyphen_req
 %type <scm>    string bare_number number_expression
@@ -729,9 +729,8 @@ Composite_music:
        CONTEXT STRING Music    {
                Context_specced_music *csm =  new Context_specced_music ($3);
 
-               csm->translator_type_str_ = ly_scm2string ($2);
-               csm->translator_id_str_ = "";
-
+               csm->set_mus_property ("context-type",$2);
+               csm->set_mus_property ("context-id", ly_str02scm (""));
 
                $$ = csm;
        }
@@ -748,8 +747,8 @@ Composite_music:
        | CONTEXT STRING '=' STRING Music {
                Context_specced_music *csm =  new Context_specced_music ($5);
 
-               csm->translator_type_str_ = ly_scm2string ($2);
-               csm->translator_id_str_ = ly_scm2string ($4);
+               csm->set_mus_property ("context-type", $2);
+               csm->set_mus_property ("context-id", $4);
 
                $$ = csm;
        }
@@ -854,7 +853,7 @@ property_def:
                $$ = csm;
                $$->set_spot (THIS->here_input ());
 
-               csm-> translator_type_str_ = ly_scm2string ($2);
+               csm-> set_mus_property ("context-type", $2);
        }
        | PROPERTY STRING '.' STRING PUSH embedded_scm '=' embedded_scm {
                Music *t = new Music;
@@ -866,7 +865,7 @@ property_def:
                $$ = csm;
                $$->set_spot (THIS->here_input ());
 
-               csm-> translator_type_str_ = ly_scm2string ($2);
+               csm-> set_mus_property ("context-type", $2);
        }
        | PROPERTY STRING '.' STRING POP embedded_scm {
                Music *t = new Music;
@@ -878,7 +877,7 @@ property_def:
                $$ = csm;
                $$->set_spot (THIS->here_input ());
 
-               csm-> translator_type_str_ = ly_scm2string ($2);
+               csm-> set_mus_property ("context-type", $2);
        }
        ;
 
@@ -912,6 +911,19 @@ command_element:
                $$-> set_spot (THIS->here_input ());
                $1-> set_spot (THIS->here_input ());
        }
+       | BAR STRING ';'                        {
+               Music *t = new Music;
+
+               t->set_mus_property ("type", ly_symbol2scm ("property-set"));
+               t->set_mus_property ("symbol", ly_symbol2scm ("whichBar"));
+               t->set_mus_property ("value", $2);
+
+               Context_specced_music *csm = new Context_specced_music (t);
+               $$ = csm;
+               $$->set_spot (THIS->here_input ());
+
+               csm->set_mus_property ("context-type", ly_str02scm ("Score"));
+       }
        | PARTIAL duration_length ';'   {
                Music * p = new Music;
                p->set_mus_property ("symbol", ly_symbol2scm ( "measurePosition"));
@@ -922,12 +934,31 @@ command_element:
                delete $2; // ugh
                Context_specced_music * sp = new Context_specced_music (p);
                $$ =sp ;
-               sp-> translator_type_str_ = "Score";
+               sp-> set_mus_property ("context-type", ly_str02scm ( "Score"));
+       }
+       | CLEF STRING ';' {
+               SCM func = scm_eval2 (ly_symbol2scm ("clef-name-to-properties"), SCM_EOL);
+               SCM result = gh_call1 (func, $2);
+
+               SCM l = SCM_EOL; 
+               for (SCM s = result ; gh_pair_p (s); s = gh_cdr (s)) {
+                       Music * p = new Music;
+                       for (SCM k = gh_car (s) ; gh_pair_p (k); k = gh_cdr (k)) {
+                               p->set_mus_property (gh_caar (k), gh_cdar (k));
+                       }
+                       l = gh_cons (p->self_scm (), l);
+                       scm_unprotect_object (p->self_scm ());
+               }
+               Sequential_music * seq = new Sequential_music (l);
+
+               Context_specced_music * sp = new Context_specced_music (seq);
+               $$ =sp ;
+               sp-> set_mus_property("context-type", ly_str02scm("Staff"));
        }
        ;
 
 command_req:
-       shorthand_command_req
+       shorthand_command_req   { $$ = $1; }
        | verbose_command_req semicolon { $$ = $1; }
        ;
 
@@ -963,11 +994,7 @@ shorthand_command_req:
 
 
 verbose_command_req:
-       
-       BAR STRING                      {
-               $$ = new Bar_req (ly_scm2string ($2));
-       }
-       | COMMANDSPANREQUEST bare_int STRING {
+       COMMANDSPANREQUEST bare_int STRING {
                Span_req * sp_p = new Span_req;
                sp_p-> set_span_dir ( Direction($2));
                sp_p->set_mus_property ("span-type",$3);
@@ -1011,11 +1038,6 @@ verbose_command_req:
        | tempo_request {
                $$ = $1;
        }
-       | CLEF STRING {
-               $$ = new Clef_change_req;
-               $$->set_mus_property ("clef-type", $2);
-
-       }
        | KEY {
                Key_change_req *key_p= new Key_change_req;
                $$ = key_p;
index a510a141ff5835205df2d15eff4e7b0d2645d34c..3f09f169e1579d2bddc1ca60bc7f59fa1453ed00 100644 (file)
@@ -134,7 +134,7 @@ Piano_pedal_engraver::do_process_music ()
 {
   for (Pedal_info*p = info_list_; p->name_; p ++)
     {
-      SCM s = SCM_UNDEFINED;
+      SCM s = SCM_EOL;
       if (p->req_l_drul_[STOP] && p->req_l_drul_[START])
        {
          if (!p->start_req_l_)
index baddf06bb6999e70cb79cbb886da892cefa0c98f..9861866e82442545206b97bdfc2f00153a1dd147 100644 (file)
@@ -109,7 +109,7 @@ Property_engraver::apply_properties (SCM p, Score_element *e, Translator_group*o
   
       SCM val = get_property (prop_sym);
 
-      if (val == SCM_UNDEFINED)
+      if (val == SCM_EOL)
        ;                       // Not defined in context.
       else if (gh_apply (type_p, scm_listify (val, SCM_UNDEFINED))
               == SCM_BOOL_T)   // defined and  right type: do it
@@ -135,16 +135,16 @@ Property_engraver::apply_properties (SCM p, Score_element *e, Translator_group*o
       else
 
        /*
-           we don't print a warning if VAL == #f, because we would
+           we don't print a warning if VAL == (), because we would
            get lots of warnings when we restore stuff to default, eg.
 
-           slurDash = #1 [...] slurDash = ##f
+           slurDash = #1 [...] slurDash = ()
 
            should not cause "type error: slurDash expects number not
-           boolean"
+           boolean
 
        */
-       if (val != SCM_BOOL_F)
+       if (val != SCM_EOL)
          {                     // not the right type: error message.
            SCM errport = scm_current_error_port ();
            warning (_("Wrong type for property"));
index aaeeeecac7bcb5427fad13d5c56aa341d839d8e3..79df69f6daefd86727f066e54561ea55ff86499b 100644 (file)
@@ -71,15 +71,9 @@ Request_chord_iterator::process (Moment m)
        {
          Music *mus = unsmob_music (gh_car (s));
 
-         if (Request * req_l = dynamic_cast<Request*> (mus))
-           {
-             bool gotcha = try_music (req_l);
-             if (!gotcha)
-               req_l->origin ()->warning (_f ("Junking request: `%s'", classname( req_l)));
-           }
-         else
-           mus->origin ()->warning (_f ("Huh?  Not a Request: `%s'",
-                                        classname (mus)));
+         bool gotcha = try_music (mus);
+         if (!gotcha)
+           mus->origin ()->warning (_f ("Junking request: `%s'", classname(mus)));
        }
     }
   skip (m);
index c727c5889625c2aab8410811bd2b51e29ee5e4d2..05b4fbfc207768b58ae774c5e2c3e1d643736af0 100644 (file)
@@ -66,8 +66,9 @@ Timing_engraver::do_pre_move_processing ()
 bool
 Timing_engraver::do_try_music (Music*m)
 {
-  if (Bar_req  * b= dynamic_cast <Bar_req *> (m))
+  if (0) // 
     {
+      Bar_req  * b= dynamic_cast <Bar_req *> (m);
       if (bar_req_l_ && !bar_req_l_->equal_b (b)) 
        return false;
       
@@ -81,7 +82,4 @@ Timing_engraver::do_try_music (Music*m)
 void
 Timing_engraver::do_process_music ()
 {
-  if (bar_req_l_)
-    daddy_trans_l_->set_property ("whichBar", bar_req_l_->get_mus_property ("type"));
 }
-
index cf813de9636d8b6610c2573e5bd8410244a5ee7e..1b85d8113a1b147d3a14fb24ef7c279dba2c4de9 100644 (file)
@@ -282,12 +282,12 @@ Translator_group::where_defined (SCM sym) const
 }
 
 /*
-  TODO: return SCM_EOL iso. SCM_UNDEFINED when not found.
+  return SCM_EOL when not found.
 */
 SCM
 Translator_group::get_property (SCM sym) const
 {
-  SCM val =SCM_UNDEFINED;
+  SCM val =SCM_EOL;
   if (properties_dict ()->try_retrieve (sym, &val))
     return val;
 
@@ -322,10 +322,6 @@ Translator_group::execute_single_pushpop_property (SCM prop, SCM eltprop, SCM va
        {
          SCM prev = get_property (prop);
 
-         /*
-           we don't tack onto SCM_UNDEFINED, because it creates
-           errors down the line, if we do scm_assoc().
-          */
          if (gh_pair_p (prev) || prev == SCM_EOL)
            {
              bool ok = true;
@@ -333,6 +329,13 @@ Translator_group::execute_single_pushpop_property (SCM prop, SCM eltprop, SCM va
              SCM errport = scm_current_error_port ();
              
              SCM meta = scm_assoc (ly_symbol2scm ("meta"), prev);
+
+             /*
+               We're probably in a performer.
+              */
+             if (!gh_pair_p (meta))
+               return;
+             
              SCM props = scm_assoc (ly_symbol2scm ("properties"), gh_cdr (meta));
              SCM type_p = scm_assoc (eltprop, gh_cdr (props));
              if (!gh_pair_p (type_p))
@@ -348,7 +351,8 @@ Translator_group::execute_single_pushpop_property (SCM prop, SCM eltprop, SCM va
              else
                {
                  type_p = gh_cdr (type_p);
-                 if (gh_call1 (type_p, val) == SCM_BOOL_F)
+                 if (val != SCM_EOL
+                     && gh_call1 (type_p, val) == SCM_BOOL_F)
                    {
                      ok = false;
                      scm_puts (_("Failed typecheck for #'").ch_C (),errport);
index 383bb18c8c7541cbc97034cb4b522c626acb7394..be2d0f15e70893228453dd3c21a56de5e0c52444 100644 (file)
@@ -366,59 +366,11 @@ ScoreContext = \translator {
        splitInterval = #'(0 . 1)
        changeMoment = #`(,(make-moment 0 0) . ,(make-moment 1 512))
 
-       defaultClef = #"treble"
-
        StaffMinimumVerticalExtent = #(cons -4.0 4.0)
 
        barAuto = ##t
        voltaVisibility = ##t
        %  name, glyph id, clef position 
-       supportedClefTypes = #'(
-         ("treble" . ("clefs-G" -2))
-         ("violin" . ("clefs-G" -2))
-         ("G" . ("clefs-G" -2))
-         ("G2" . ("clefs-G" -2))
-         ("french" . ("clefs-G" -4 ))
-         ("soprano" . ("clefs-C" -4 ))
-         ("mezzosoprano" . ("clefs-C" -2 ))
-         ("alto" . ("clefs-C" 0 ))
-         ("tenor" . ("clefs-C" 2 ))
-         ("baritone" . ("clefs-C" 4 ))
-         ("varbaritone"  . ("clefs-F" 0))
-         ("bass" . ("clefs-F" 2 ))
-         ("F" . ( "clefs-F" 2))
-         ("subbass" . ("clefs-F" 4))
-         ("vaticana_do1" . ("clefs-vaticana_do" -1))
-         ("vaticana_do2" . ("clefs-vaticana_do" 1))
-         ("vaticana_do3" . ("clefs-vaticana_do" 3))
-         ("vaticana_fa1" . ("clefs-vaticana_fa" -1))
-         ("vaticana_fa2" . ("clefs-vaticana_fa" 1))
-         ("medicaea_do1" . ("clefs-medicaea_do" -1))
-         ("medicaea_do2" . ("clefs-medicaea_do" 1))
-         ("medicaea_do3" . ("clefs-medicaea_do" 3))
-         ("medicaea_fa1" . ("clefs-medicaea_fa" -1))
-         ("medicaea_fa2" . ("clefs-medicaea_fa" 1))
-         ("hufnagel_do1" . ("clefs-hufnagel_do" -1))
-         ("hufnagel_do2" . ("clefs-hufnagel_do" 1))
-         ("hufnagel_do3" . ("clefs-hufnagel_do" 3))
-         ("hufnagel_fa1" . ("clefs-hufnagel_fa" -1))
-         ("hufnagel_fa2" . ("clefs-hufnagel_fa" 1))
-         ("hufnagel" . ("clefs-hufnagel_do_fa" 4))
-         ("mensural1_c1" . ("clefs-mensural1_c" -4))
-         ("mensural1_c2" . ("clefs-mensural1_c" -2))
-         ("mensural1_c3" . ("clefs-mensural1_c" 0))
-         ("mensural1_c4" . ("clefs-mensural1_c" 2))
-         ("mensural2_c1" . ("clefs-mensural2_c" -4))
-         ("mensural2_c2" . ("clefs-mensural2_c" -2))
-         ("mensural2_c3" . ("clefs-mensural2_c" 0))
-         ("mensural2_c4" . ("clefs-mensural2_c" 2))
-         ("mensural2_c5" . ("clefs-mensural2_c" 4))
-         ("mensural3_c1" . ("clefs-mensural3_c" -2))
-         ("mensural3_c2" . ("clefs-mensural3_c" 0))
-         ("mensural3_c3" . ("clefs-mensural3_c" 2))
-         ("mensural3_c4" . ("clefs-mensural3_c" 4))
-         ("mensural_f" . ("clefs-mensural_f" 2))
-       )
        % where is c0 in this clef?
        clefPitches = #'(("clefs-G" . -4)
          ("clefs-C" . 0)
@@ -435,9 +387,11 @@ ScoreContext = \translator {
          ("clefs-mensural3_c" . 0)
          ("clefs-mensural_f" . 0))
 
+       clefGlyph = #"clefs-G"
+       clefPosition = #-2
+
         automaticPhrasing = ##t;
        alignmentReference = \down;
-       defaultClef = #"treble"
        defaultBarType = #"|"
 
        explicitClefVisibility = #all-visible
index 15656a9161d51c29cbd803de404ba0a578f92d23..754e2854cc26f367902879859a206110532cbe20 100644 (file)
@@ -48,8 +48,8 @@ voiceFour = {
        \shiftOn
 }
 
-slurDotted = \property Voice.Slur \push #'dash = #1
-slurNoDots = \property Voice.Slur \pop #'dash
+slurDotted = \property Voice.Slur \push #'dashed = #1
+slurNoDots = \property Voice.Slur \pop #'dashed
 
        
 tiny  = 
index 509de0118a58051facedd102d8f03a6a1bc733c2..923aa009d8ebec28a021bf22ae0ede32ba39bb1f 100644 (file)
@@ -13,9 +13,6 @@ $(outdir)/%.png: $(outdir)/%.ps
 $(outdir)/%.ly.txt: %.ly
        ln -f $< $@
 
-$(outdir)/%.fly.txt: %.fly
-       ln -f $< $@
-
 $(outdir)/%.ly.txt: %.abc
 #which file to show here -- abc seems more cute?
        ln -f $< $@
index eae217f289c028362e378789168ab2909cea1db6..9aa271c1a47211d0b5f42bdd7a327aaec72c6904 100644 (file)
@@ -1,15 +1,15 @@
 Begin3
 Title: LilyPond
-Version: 1.3.105
-Entered-date: 09NOV00
+Version: 1.3.106
+Entered-date: 10NOV00
 Description: 
 Keywords: music notation typesetting midi fonts engraving
 Author: hanwen@cs.uu.nl (Han-Wen Nienhuys)
        janneke@gnu.org (Jan Nieuwenhuizen)
 Maintained-by: hanwen@stack.nl (Han-Wen Nienhuys)
 Primary-site: sunsite.unc.edu /pub/Linux/apps/sound/convert
-       1000k lilypond-1.3.105.tar.gz 
+       1000k lilypond-1.3.106.tar.gz 
 Original-site: ftp.cs.uu.nl /pub/GNU/LilyPond/development/
-       1000k lilypond-1.3.105.tar.gz 
+       1000k lilypond-1.3.106.tar.gz 
 Copying-policy: GPL
 End
index e8516e9d82ab0aa5a90bdbe66038ed236b17745e..731458cd47e1bc159f73620e506089996df3f6dc 100644 (file)
@@ -1,11 +1,11 @@
 %define info yes
 
 Name: lilypond
-Version: 1.3.105
+Version: 1.3.106
 Release: 1
 License: GPL
 Group: Applications/Publishing
-Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.3.105.tar.gz
+Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.3.106.tar.gz
 Summary: A program for printing sheet music.
 URL: http://www.cs.uu.nl/~hanwen/lilypond
 # Icon: lilypond-icon.gif
index 0dfe91f8da334efa8be3d12cda5494fdfa9ebf4a..0d1006949b68cf39d822cdca71a5392d0159e8ab 100644 (file)
@@ -43,8 +43,12 @@ Note: Original key f.
 
 \version "1.3.93";
 
+dynamicUp =    \property Voice.DynamicLineSpanner \push #'direction = #1
+dynamicRevert =        \property Voice.DynamicLineSpanner \pop #'direction
+
+
 vocalVerse = \notes\relative c''{
-       \property Voice.dynamicDirection=\up
+       \dynamicUp
        \times 2/3 { [ g8( )as] g } c4. g8 |
        \times 2/3 { [ f8( )g] f } c'4 f,8 r |
        g4.-> f8 \times 2/3 { [ f( )es] d } |
@@ -73,7 +77,7 @@ vocalVerse = \notes\relative c''{
 }
 
 vocalThrough = \notes\relative c{
-       \property Voice.dynamicDirection=\up
+       \dynamicUp
        g''8. g16 b8. b16 d8. d16 |
        c4 b r |
        g4. b8 d8. c16 |
@@ -176,7 +180,7 @@ trebleVerseOne = \notes\relative c{
 }
 
 trebleEentje = \notes \relative c'{
-       \context Voice=one \property Voice.verticalDirection = \center
+       \stemBoth
        <e2 e'> <e4 g>|
        <f2\mf as!(> <as8.->( c> <)f16 )as> |
        <e4. g> <e8-. g-.(> <e-. g-.> <e-. )g-.> |
@@ -190,7 +194,7 @@ trebleEentje = \notes \relative c'{
 }
 
 trebleThrough = \notes \relative c'{
-       \context Voice=one \property Voice.verticalDirection = \center
+       \stemBoth
        <e2. e'> |
        %61
        R2. |
@@ -201,18 +205,18 @@ trebleThrough = \notes \relative c'{
        %65
        < { d,2.\f a'2} { e2. ~ e2 } { b'2. c,2 }> r4 |
        \context Staff < 
-               {
-                       \context Voice=one \property Voice.verticalDirection = 1 
+               \context Voice=one {
+                       \voiceOne
                        a8. b16 c4-> () a8 r |
                        a8. b16 c4-> () a8 r |
                }
-               { 
-                       \context Voice=two \property Voice.verticalDirection = -1 
+               \context Voice=two {
+                       \voiceTwo
                        <d,4 f> <d2 f> |
                        <c!4 es> <c2 es> |
                }
        >
-       \context Voice=one \property Voice.verticalDirection = 0
+
        % 4 bars copied from end verse1
        r8 <f, a c> <a c f> <f a c> <a c f> <f a c> |
        %70
@@ -222,8 +226,10 @@ trebleThrough = \notes \relative c'{
        < { a4.-> )f8 } { a'4. f8 } > |
        <e2 e'> r4 |
        <es!2 es'! > r4 |
-       \property Voice . textStyle =  "italic"
+       \property Voice . TextItem \push #'font-style = #'italic
        <d2_"decresc." d'> r4 |
+       \property Voice . TextItem \pop #'font-style
+
        %75
        <b2 b'> r4 |
        <c2 c'> <e4\pp g> |
@@ -233,14 +239,17 @@ trebleThrough = \notes \relative c'{
        <e4. g> <e8-. g-.(> <e-. g-.> <e-. )g-.> |
        <f4. g> <b,8-. g'-.(> <d-. g-.> <f-. )g-.> |
        %80
-       \property Voice . textStyle =  "italic"
+
+       \property Voice . TextItem \push #'font-style = #'italic
        <e2._"dim." g> |
+       \property Voice . TextItem \pop #'font-style
+
        <g,2. e' g> |
        <g2.-\fermata e' g> |
 }
 
 bassIntro = \notes\relative c{
-       \property Voice.dynamicDirection=1
+       \dynamicUp
 %1
        <c,2 c'> r4 |
        <as2 as'> r4 |
@@ -250,7 +259,7 @@ bassIntro = \notes\relative c{
 
 bassVerseOne = \notes\relative c{
 %      \clef bass;
-       \property Voice.dynamicDirection=1
+       \dynamicUp
 %5
        <c,2 c'> r4 |
        <as2 as'> r4 |
@@ -281,7 +290,7 @@ bassVerseOne = \notes\relative c{
 }
 
 bassEentje = \notes\relative c{
-       \property Voice.dynamicDirection=1
+       \dynamicUp
        <c,8 c'> [<c' f as!> <f as c> <c f as> <f as c> <c f as>] |
        c,8 [<c' e g> <e g c> <c e g> <e g c> <c e g>] |
        <g,8 g'> [<d'' g> <g b> <d g> <g b> <d g>] |
@@ -293,7 +302,7 @@ bassEentje = \notes\relative c{
 }
 
 bassThrough = \notes\relative c{
-       \property Voice.dynamicDirection=1
+       \dynamicUp
        %61
        <g,8^"cresc." g'> [<g' b d> <b d f> <g b d> <as!-> b-> d->> <b d f>] |
        <g,8 g'> [<g' d'> <d' f> <g, d'> <as-> b-> d->> <b d f>] |
@@ -351,7 +360,7 @@ vocals = \notes{
        \property Voice.noAutoBeaming = ##t
        \property Staff.automaticMelismata= ##t
 
-       \property Voice.dynamicDirection = \up
+       \dynamicUp
        \skip 4 * 12; 
        \vocalVerse 
        \skip 4 * 24; 
index cb5f5438d175d8e2d7e11878524098387a58a61d..9adc6639cb23379949c2d8c515f031d883644e68 100644 (file)
                (Y-offset-callbacks . (,Side_position::aligned_side))
                (molecule-callback . ,Text_item::brew_molecule)
                 (font-shape . italic)
+               (font-family . roman)
                (meta . ,(element-description "OctavateEight" text-interface font-interface ))
        ))
        
index be6872c6779dd92b43660812b78496e492f19117..6876a9cb6563701963920ccfe40e268c9616de0a 100644 (file)
   (eval-string (ly-gulp-file "chord-names.scm"))
   (eval-string (ly-gulp-file "element-descriptions.scm"))
  )
+
+
+;;
+;; (name . (glyph clef-position octavation))
+;; -- the name clefOctavation is misleading the value 7 is 1 octave not 7 Octaves.
+;;
+(define supported-clefs '(
+         ("treble" . ("clefs-G" -2 0))
+         ("violin" . ("clefs-G" -2 0))
+         ("G" . ("clefs-G" -2 0))
+         ("G2" . ("clefs-G" -2 0))
+         ("french" . ("clefs-G" -4  0))
+         ("soprano" . ("clefs-C" -4  0))
+         ("mezzosoprano" . ("clefs-C" -2  0))
+         ("alto" . ("clefs-C" 0  0))
+         ("tenor" . ("clefs-C" 2  0))
+         ("baritone" . ("clefs-C" 4  0))
+         ("varbaritone"  . ("clefs-F" 0 0))
+         ("bass" . ("clefs-F" 2  0))
+         ("F" . ( "clefs-F" 2 0))
+         ("subbass" . ("clefs-F" 4 0))
+
+         ;; should move mensural stuff to separate file? 
+         ("vaticana_do1" . ("clefs-vaticana_do" -1 0))
+         ("vaticana_do2" . ("clefs-vaticana_do" 1 0))
+         ("vaticana_do3" . ("clefs-vaticana_do" 3 0))
+         ("vaticana_fa1" . ("clefs-vaticana_fa" -1 0))
+         ("vaticana_fa2" . ("clefs-vaticana_fa" 1 0))
+         ("medicaea_do1" . ("clefs-medicaea_do" -1 0))
+         ("medicaea_do2" . ("clefs-medicaea_do" 1 0))
+         ("medicaea_do3" . ("clefs-medicaea_do" 3 0))
+         ("medicaea_fa1" . ("clefs-medicaea_fa" -1 0))
+         ("medicaea_fa2" . ("clefs-medicaea_fa" 1 0))
+         ("hufnagel_do1" . ("clefs-hufnagel_do" -1 0))
+         ("hufnagel_do2" . ("clefs-hufnagel_do" 1 0))
+         ("hufnagel_do3" . ("clefs-hufnagel_do" 3 0))
+         ("hufnagel_fa1" . ("clefs-hufnagel_fa" -1 0))
+         ("hufnagel_fa2" . ("clefs-hufnagel_fa" 1 0))
+         ("hufnagel" . ("clefs-hufnagel_do_fa" 4 0))
+         ("mensural1_c1" . ("clefs-mensural1_c" -4 0))
+         ("mensural1_c2" . ("clefs-mensural1_c" -2 0))
+         ("mensural1_c3" . ("clefs-mensural1_c" 0 0))
+         ("mensural1_c4" . ("clefs-mensural1_c" 2 0))
+         ("mensural2_c1" . ("clefs-mensural2_c" -4 0))
+         ("mensural2_c2" . ("clefs-mensural2_c" -2 0))
+         ("mensural2_c3" . ("clefs-mensural2_c" 0 0))
+         ("mensural2_c4" . ("clefs-mensural2_c" 2 0))
+         ("mensural2_c5" . ("clefs-mensural2_c" 4 0))
+         ("mensural3_c1" . ("clefs-mensural3_c" -2 0))
+         ("mensural3_c2" . ("clefs-mensural3_c" 0 0))
+         ("mensural3_c3" . ("clefs-mensural3_c" 2 0))
+         ("mensural3_c4" . ("clefs-mensural3_c" 4 0))
+         ("mensural_f" . ("clefs-mensural_f" 2 0))
+       )
+)
+
+(define (clef-name-to-properties cl)
+  (let ((e (assoc cl supported-clefs))
+       )
+    (if (pair? e)
+       `(((symbol . clefGlyph)
+          (type . property-set)
+          (value . ,(cadr e))
+          )
+         ((symbol . clefPosition)
+          (type . property-set)
+          (value . ,(caddr e))
+          )
+         ((symbol . clefOctavation)
+          (type . property-set)
+          (value . ,(caddr (cdr e)))
+         )
+         )
+       (begin
+         (ly-warn (string-append "Unknown clef type `" cl "'\nSee scm/lily.scm for supported clefs"))
+         '())
+    )))
index 61badb5ef96434fc42661599cc7344a119d40c3d..ee58d6ba18e132743138c700a50bfce2334c8f5b 100644 (file)
@@ -148,14 +148,13 @@ given in an @code{\alternative}.
      "Determine and set reference point for pitches"
      '(Clef OctavateEight)
      (list
-      (translator-property-description 'supportedClefTypes
-                                      list? "Clef settings supported. The value is an association list contain entries (NAME . (GLYPH . POSITION)), where  NAME is the clef name (alto, baritone, etc.), GLYPH the glyph name, POSITION an integer where the center symbol should go.")
-      (translator-property-description 'clefPosition number? " where the center of the symbol should go")
-      (translator-property-description 'clefGlyph string? "name of the symbol within the music font")
-      (translator-property-description 'centralCPosition number? "place of the central C. ")
-      (translator-property-description 'defaultClef string? "generate this clef at the very start of this staff. If not set, don't generate a clef")
-      (translator-property-description 'explicitClefVisibility procedure? "visibility-lambda function for clefs entered as \clef.")
-      (translator-property-description 'clefPitches list? "alist mapping GLYPHNAME to the position of the central C for that symbol")
+      (translator-property-description 'clefPosition number? "Where should the center of the symbol go?")
+      (translator-property-description 'clefGlyph string? "Name of the symbol within the music font")
+      (translator-property-description 'centralCPosition number? "Place of the central C. Usually determined by looking at clefPosition and clefGlyph.")
+      (translator-property-description 'clefOctavation integer? "Add
+this much extra octavation. Values of 7 and -7 are common.")
+      (translator-property-description 'explicitClefVisibility procedure? "visibility-lambda function for clef changes.")
+      (translator-property-description 'clefPitches list? "an alist mapping GLYPHNAME to the position of the central C for that symbol")
 
       )))
    
index 6539a48e3bd74dec062927150ba2d62a24c3e393..d37806d3a91145d281b7a7b12a53a7b6a9161030 100644 (file)
@@ -5,6 +5,8 @@
 # * add support for .lilyrc
 
 
+# todo: dimension handling (all the x2y) is clumsy. 
+
 # This is was the idea for handling of comments:
 #      Multiline comments, @ignore .. @end ignore is scanned for
 #      in read_doc_file, and the chunks are marked as 'ignore', so
@@ -36,10 +38,14 @@ import operator
 
 program_version = '@TOPLEVEL_VERSION@'
 if program_version == '@' + 'TOPLEVEL_VERSION' + '@':
-       program_version = '1.3.105.tca1'
+       program_version = '1.3.106'     
 
 include_path = [os.getcwd()]
 
+
+# g_ is for global (?)
+
+g_here_dir = os.getcwd ()
 g_dep_prefix = ''
 g_outdir = ''
 g_force_mudela_fontsize = 0
@@ -813,10 +819,10 @@ def find_eps_dims (match):
        "Fill in dimensions of EPS files."
        
        fn =match.group (1)
-       if g_outdir:
-           fn = os.path.join(g_outdir, fn)
        dims = bounding_box_dimensions (fn)
-
+       if g_outdir:
+               fn = os.path.join(g_outdir, fn)
+       
        return '%ipt' % dims[0]
 
 
@@ -850,8 +856,14 @@ def compile_all_files (chunks):
        if g_outdir:
                os.chdir(g_outdir)
        if tex:
-               lilyopts = map (lambda x:  '-I ' + x, include_path)
-               lilyopts = string.join (lilyopts, ' ' )
+               # fixme: be sys-independent.
+               def incl_opt (x):
+                       if g_outdir and x[0] <> '/' :
+                               x = os.path.join (g_here_dir, x)
+                       return ' -I %s' % x
+
+               incs =  map (incl_opt, include_path)
+               lilyopts = string.join (incs, ' ' )
                texfiles = string.join (tex, ' ')
                system ('lilypond %s %s' % (lilyopts, texfiles))
        for e in eps: