]> git.donarmstrong.com Git - lilypond.git/commitdiff
* input/regression/line-arrows.ly: new file.
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Mon, 18 Apr 2005 12:10:37 +0000 (12:10 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Mon, 18 Apr 2005 12:10:37 +0000 (12:10 +0000)
* lily/paper-score.cc (process): run get_paper_systems() only once.

ChangeLog
input/regression/line-arrows.ly [new file with mode: 0644]
lily/book.cc
lily/include/paper-score.hh
lily/paper-book.cc
lily/paper-score.cc

index 546085c1c06129d185cb361712f0f5fe6d11935d..ad4fe48c90955eca00e930bd53e704dd3127b760 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 2005-04-18  Han-Wen Nienhuys  <hanwen@xs4all.nl>
 
+       * input/regression/line-arrows.ly: new file.
+
        * lily/paper-score.cc (process): run get_paper_systems() only once.
 
        * lily/line-interface.cc (make_arrow): new function. Patch by
diff --git a/input/regression/line-arrows.ly b/input/regression/line-arrows.ly
new file mode 100644 (file)
index 0000000..47e9ebb
--- /dev/null
@@ -0,0 +1,23 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\version "2.5.18"
+
+%% demonstration of line arrows
+%% By Jonatan Liljedahl <http://kymatica.com>
+
+\relative c'' {
+    %% Arrow between two texts    
+    \override TextSpanner #'edge-text = #'("foo" . "bar")
+    \override TextSpanner #'dash-fraction = #'()
+    \override TextSpanner #'style = #'line
+    \override TextSpanner #'arrow = ##t
+    
+    %% Default arrow size
+%    \override TextSpanner #'arrow-length = #1.3
+%    \override TextSpanner #'arrow-width = #0.5
+
+    %% We can put arrows to a glissando line
+    \override Glissando #'arrow = ##t
+    
+    a8\startTextSpan gis8\< a2 b4\glissando
+    c,4 g'\! c\stopTextSpan c
+}
index e0388c00c38bb42be06372bf8eedad14dc78f5ce..b1d3ff11659f05efa42843f26f63a1d6bfd89e8b 100644 (file)
@@ -121,7 +121,7 @@ Book::process (String outname, Output_def *default_def)
                }
              else if (Paper_score *pscore = dynamic_cast<Paper_score *> (output)) 
                {
-                 SCM systems = pscore->get_systems ();
+                 SCM systems = pscore->get_paper_systems ();
                  if (ly_c_module_p (score->header_))
                    paper_book->add_score (score->header_);
                  paper_book->add_score (systems);
index 7a6b1f147294ca57efeee02863dc07e84a4acfe7..bf9443cd507b642973c7fbe3678014ea44899400 100644 (file)
@@ -29,7 +29,7 @@ public:
   void typeset_system (System *);
   Array<Column_x_positions> calc_breaking ();
 
-  SCM get_systems () const;
+  SCM get_paper_systems () const;
 protected:
   virtual void process ();
   virtual void derived_mark () const;
index cd9f4cbc45b1d60d7c78f75abce335a607be96c9..19669737e762a768b24ba27f3560ce249ca8b445 100644 (file)
@@ -7,7 +7,7 @@
 */
 
 #include "paper-book.hh"
-
+#include "paper-score.hh"
 #include "main.hh"
 #include "output-def.hh"
 #include "paper-score.hh"
@@ -250,8 +250,10 @@ Paper_book::systems ()
          if (header_0_ == SCM_EOL)
            header_0_ = header;
        }
-      else if (scm_is_vector (scm_car (s)))
+      else if (Paper_score *pscore
+              = dynamic_cast<Paper_score *> (unsmob_music_output (scm_car (s))))
        {
+         
          Stencil title = score_title (header);
          if (title.is_empty ())
            title = score_title (header_);
@@ -264,7 +266,8 @@ Paper_book::systems ()
            }
          header = SCM_EOL;
 
-         SCM system_list = scm_vector_to_list (scm_car (s));
+         
+         SCM system_list = scm_vector_to_list (pscore->get_paper_systems ());
          system_list = scm_reverse (system_list);
          systems_ = scm_append (scm_list_2 (system_list, systems_));
        }
index eb431864b2dd460e4cf12502cd63d00b3e9fbc09..2c1f0797d0f86c59ce746fc046f3bc61a27a97fd 100644 (file)
@@ -109,7 +109,7 @@ Paper_score::layout () const
   
 
 SCM
-Paper_score::get_systems () const
+Paper_score::get_paper_systems () const
 {
   return paper_systems_;
 }