]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/music.cc (name): bugfix
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Sun, 13 Oct 2002 22:16:28 +0000 (22:16 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Sun, 13 Oct 2002 22:16:28 +0000 (22:16 +0000)
* lily/piano-pedal-engraver.cc (try_music): fix pedals.

* lily/input-file-results.cc (code): set-point-and-click! ->
set-point-and-click

23 files changed:
ChangeLog
Documentation/user/internals.itely
Documentation/user/invoking.itexi
Documentation/user/refman.itely
Documentation/user/tutorial.itely
input/mutopia/J.S.Bach/Petites-Preludes/preludes-1.ly
input/mutopia/J.S.Bach/Petites-Preludes/preludes-2.ly
input/mutopia/J.S.Bach/Petites-Preludes/preludes-3.ly
input/mutopia/J.S.Bach/Petites-Preludes/preludes-5.ly
input/mutopia/J.S.Bach/Petites-Preludes/preludes-6.ly
input/mutopia/J.S.Bach/wtk1-fugue1.ly
input/regression/pc-mmrest.ly
input/tutorial/miniatures.ly
input/tutorial/os-flute-2.ly
input/tutorial/os-score.ly
lily/input-file-results.cc
lily/music.cc
lily/piano-pedal-engraver.cc
ly/init.ly
ly/midi-init.ly
ly/spanners-init.ly
scm/music-functions.scm
scripts/convert-ly.py

index 0917334fc7f14d7574000fec78c721c300d792a4..de50228cfb91c4ca01a51f41fdd2570a5fa1b926 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2002-10-14  Han-Wen Nienhuys  <hanwen@cs.uu.nl>
+
+       * lily/music.cc (name): bugfix
+
+       * lily/piano-pedal-engraver.cc (try_music): fix pedals.
+
+       * lily/input-file-results.cc (code): set-point-and-click! ->
+       set-point-and-click
+       
 2002-10-13  Han-Wen Nienhuys  <hanwen@cs.uu.nl>
 
        * Use uniform ly: prefix for exported scheme primitive functions.
index 81d7e672ff25cac324d0e65dab3d8db1361404de..3ab73dc1072c0bc286d36746b3967c37ca079d06 100644 (file)
@@ -660,11 +660,11 @@ about how music is stored.
 
 @lilypond[verbatim,singleline]
 #(define (testfunc x)
-  (if (equal? (ly-get-mus-property x 'text) "foo")
-      (ly-set-mus-property! x 'text "bar"))
+  (if (equal? (ly:get-mus-property x 'text) "foo")
+      (ly:set-mus-property! x 'text "bar"))
   ;; recurse
-  (ly-set-mus-property! x 'elements
-    (map testfunc (ly-get-mus-property x 'elements)))
+  (ly:set-mus-property! x 'elements
+    (map testfunc (ly:get-mus-property x 'elements)))
   (display x)
   x)
 
@@ -685,12 +685,12 @@ A final example is a function that reverses a piece of music in time:
 
 @lilypond[verbatim,singleline]
 #(define (reverse-music music)
-  (let* ((elements (ly-get-mus-property music 'elements))
+  (let* ((elements (ly:get-mus-property music 'elements))
          (reversed (reverse elements))
-         (span-dir (ly-get-mus-property music 'span-direction)))
-    (ly-set-mus-property! music 'elements reversed)
+         (span-dir (ly:get-mus-property music 'span-direction)))
+    (ly:set-mus-property! music 'elements reversed)
     (if (dir? span-dir)
-        (ly-set-mus-property! music 'span-direction (- span-dir)))
+        (ly:set-mus-property! music 'span-direction (- span-dir)))
     (map reverse-music reversed)
     music))
 
index b6d34c0a33af2f5a5b0aff81f660ff68e4e4feff..ea699c3f1016e5be3cdf34f4d87d724b44166397 100644 (file)
@@ -43,8 +43,8 @@ The following options are supported:
 @item -e,--evaluate=@var{expr}
 Evaluate the Scheme @var{expr} before parsing any @file{.ly} files.
 Multiple @code{-e} options may be given, they will be evaluated
-sequentially.  The function @code{ly-set-option} allows for access to
-some internal variables.  Use @code{-e '(ly-option-usage')} for more
+sequentially.  The function @code{ly:set-option} allows for access to
+some internal variables.  Use @code{-e '(ly:option-usage')} for more
 information.
 
 @item -f,--format=@var{format}
index 20adac1d36e2f4df219a378d6a65ba7cfcfaa117..d3f2dda3f09fee112f4ce324262b209b7afcbf5e 100644 (file)
@@ -725,7 +725,7 @@ fonts. Refer to the Xdvi documentation for more information.
 To use point-and-click, add one of these lines to the top of your .ly
 file.
 @example
-#(set-point-and-click! 'line)
+#(ly:set-point-and-click 'line)
 @end example
 @cindex line-location
 
@@ -765,7 +765,7 @@ apply @file{server.el.patch} (version 21.2 and earlier).  At the top
 of the @code{ly} file, replace the @code{set!} line with the following
 line,
 @example
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 @end example
 @cindex line-colomn-location
 and set @code{XEDITOR} to @code{emacsclient --no-wait +%l:%c %f}.
index 31d03630086956010d45c006ab28ec8c40981c85..9a05dff775e2dbd62176e9c466efdc799e996ef1 100644 (file)
@@ -2387,7 +2387,7 @@ conductor's score.
 \include "os-music.ly"
 \include "paper13.ly"
 
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 #(define text-flat '((font-relative-size . -2)
          (music "accidentals--1")))
 
@@ -2472,11 +2472,11 @@ First we need to include the music definitions we made in
 
 @separate
 @example
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 @end example
 
 This piece of Scheme code executes the function
-@code{set-point-and-click!} with the argument
+@code{ly:set-point-and-click} with the argument
 @code{line-column}.  Editing input files can be complicated if you're
 working with large files: if you're digitizing existing music, you have
 to synchronize the .ly file, the sheet music on your lap and the sheet
index edc1f9b2e4650af71d6afd6447908e8f058328fe..ed039d22379d634b57045a605abe97a244b69983 100644 (file)
@@ -1,4 +1,4 @@
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 
 opus = "BWV 924"
 piece = "1"
@@ -18,7 +18,7 @@ Lemoine puts fermatas on ending bar lines everywhere.
 
 
 
-\version "1.5.72"
+\version "1.7.3"
 
 
 lowstaff =  \translator "Staff" = "lower"
index db203fce4ea6429c22ebd2a77198caaaca1a3d22..9304e4d6d485809456a32beca4071644262f8778 100644 (file)
@@ -1,10 +1,10 @@
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 
 opus= "BWV 939"
 piece = "2"
 
 
-\version "1.5.72"
+\version "1.7.3"
 upper =  \context Staff \notes\relative c{
        \context Voice=i
        \property Voice.TextScript \set #'font-style = #'italic
index 45681e07d3000572f2c9d1f2102d835e88c59198..b426a363095511c75d491525814b25af37ce8131 100644 (file)
@@ -1,4 +1,4 @@
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 
 opus= "BWV 999"
 piece = "3"
@@ -14,7 +14,7 @@ note, some have dotted half notes.
 This file was partly generated using m4.
 %}
 
-\version "1.5.72"
+\version "1.7.3"
 
 
 upper =   \notes \transpose c'' {
index a1b45db8f2666c72183077ec9f3c1176a980df65..cfeda21167734e1d63729dac3c74feda68816e52 100644 (file)
@@ -1,9 +1,9 @@
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 
 piece = "5"
 opus = "BWV 926"
 
-\version "1.5.72"
+\version "1.7.3"
 
 upper =  \context Staff \notes\relative c
        \context Voice=i {
index d678d0b14ff8f721406b8097689d11d016ba12f0..0334e5a8f7d2d1233fc34f915afb5cf56bf17ecc 100644 (file)
@@ -1,9 +1,9 @@
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 
 opus = "BWV 940"
 piece = "6"
 
-\version "1.5.72"
+\version "1.7.3"
 
 
 
index 0a6303a8526ad21453e0202ed0877b9423f0f2e7..5aeedcdf0db07fa394512d518b13334b76b3b218 100644 (file)
@@ -19,9 +19,9 @@ enteredby =    "Shay Rojansky"
 %{
 TODO: use autobeaming. 
 %}
-\version "1.5.72"
+\version "1.7.3"
 
-% #(set-point-and-click! 'line-column)
+% #(ly:set-point-and-click 'line-column)
 
 tenor = 
        \context Voice  = tenor  \notes \relative c' {
index 48a3a13a4028cf3a9a7c43d90b34a9bcbc2e124f..71d2b58d544b65a3b947f3097d5cbd0641054355 100644 (file)
@@ -1,10 +1,10 @@
-\version "1.5.72"
+\version "1.7.3"
 \header {
 texidoc="Multi measure rests of second voice should not disappear."
 }
 
 
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 one = \notes\relative c'' {
 
        f4 \!e-.\f r2|
index c7d27f5f1d1b39619aac3c8cb9da13fa230e75d8..4c3daf2b840dc3a756d6af51985872c74067e765 100644 (file)
@@ -1,10 +1,10 @@
-\version "1.5.72"
+\version "1.7.3"
 \header {
   title = "Two miniatures"
   tagline = "Small is beatiful"
 }
 
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 
 \paper { linewidth = -1.0 }
 
index 8586e975895a9d7cd162802abc6b3836a0dbee6d..2d606cfae5ef0806df7e532ead01d225f5915fec 100644 (file)
@@ -1,4 +1,4 @@
-\version "1.5.72"
+\version "1.7.3"
 
 \include "os-music.ly"
 \include "paper16.ly"
@@ -26,4 +26,4 @@
 
 % switch off settings of -score file, so the rest of the
 % tutorial isn't \special
-#(set-point-and-click! 'none)
+#(ly:set-point-and-click 'none)
index 2d923dad799ae861798b96396e4d35a046ec9b1d..0f37c9a5a942684e4b3b9d3f0c6e9e3a53ab435c 100644 (file)
@@ -1,10 +1,10 @@
 
-\version "1.5.72"
+\version "1.7.3"
 
 \include "os-music.ly"
 \include "paper13.ly"
 
-#(set-point-and-click! 'line-column)
+#(ly:set-point-and-click 'line-column)
 #(define text-flat '((font-relative-size . -2) (music "accidentals--1")))
 
 \score {
index 9ed2878c084afb61ab1b02b5aaf4114b16058caa..c0cc86763ac0e7838a064100b51ab080baf9d27f 100644 (file)
 #include "ly-modules.hh"
 
 
-LY_DEFINE(ly_set_point_and_click_x, "ly:set-point-and-click!", 1, 0, 0,
+/*
+  no ! suffix since it doesn't modify 1st argument.
+ */
+LY_DEFINE(ly_set_point_and_click_x, "ly:set-point-and-click", 1, 0, 0,
          (SCM what),
-         "Set the options for Point-and-click source specials output. The
-argument is a symbol.  Possible options are @code{none} (no source specials),
-@code{line} and @code{line-column}")
+         "Set the options for Point-and-click source specials output. The\n"
+"argument is a symbol.  Possible options are @code{none} (no source specials),\n"
+"@code{line} and @code{line-column}")
 {
   /*
     UGH.
index f7b734c238c24594cffa76542b101ec6fc5b9282..ba6e8ce3c5f94393fe6f953a3125a710fdd6180c 100644 (file)
@@ -40,12 +40,12 @@ Music::internal_is_music_type (SCM k)const
 }
 
 String
-Music::name ()const
+Music::name () const
 {
   SCM nm = get_mus_property ("name");
-  if (gh_string_p (nm))
+  if (gh_symbol_p (nm))
     {
-      return ly_scm2string (nm);
+      return ly_symbol2string (nm);
     }
   else
     {
index 4140c596e0be95ac17c8fef3328f7ac73f97b072..c2e7c5eaf8c8e2acddddf597e7d10bb244c2a19f 100644 (file)
@@ -168,7 +168,7 @@ Piano_pedal_engraver::try_music (Music *m)
        {
          String nm = p->name_ + String ("Event");
          if (gh_equal_p (m->get_mus_property ("name") ,
-                         scm_makfrom0str (nm.to_str0())))
+                         gh_symbol2scm (nm.to_str0())))
            {
              Direction d = to_dir (m->get_mus_property ("span-direction"));
              p->req_l_drul_[d] = m;
@@ -469,7 +469,6 @@ Piano_pedal_engraver::typeset_all ()
       
       if (p->finished_bracket_)
        {
-         Grob * l = p->finished_bracket_->get_bound (LEFT);
          Grob * r = p->finished_bracket_->get_bound (RIGHT);      
          if (!r)
            {
index 1d6a26434ba18827755210c59a88014c8222edd8..fbb3ad6938bd8898ad26da15d82957e0a27a29ab 100644 (file)
@@ -3,7 +3,7 @@
 #(define-public point-and-click #f)
 #(define-public midi-debug #f)
 
-\version "1.5.68"
+\version "1.7.3"
 
 \include "declarations-init.ly"
 
index a13f29d9eb2f2a0f90f8a80ed7598149fc865ca9..17c7709d071990bd8da35d9f2adcdeac168b25cb 100644 (file)
@@ -2,6 +2,5 @@
 \midi {
         \tempo 4=60
        \include "performer-init.ly"
-%      unfold_all = "1"
 }
 
index 3f24cf04ea09417313d1f39b412d1595d0200305..166108f4ad16761db9964075775062dcc465b1d4 100644 (file)
@@ -1,11 +1,6 @@
 \version "1.7.3"
 
 
-#(define (make-span-event type spandir)
-  (let* ((m (make-music-by-name  type)))
-  (ly:set-mus-property! m 'span-direction spandir)
-  m
-  ))
 
 groupOpen = #(make-span-event 'NoteGroupingEvent START)
 groupClose = #(make-span-event 'NoteGroupingEvent STOP)
@@ -55,6 +50,7 @@ endcresc = \spanevent \stop "crescendo"
 
 % better name sustainstart/stop? 
 sustainUp = #(make-span-event 'SustainPedalEvent STOP)
+sustainDown = #(make-span-event 'SustainPedalEvent START)
 
 unaCorda = #(make-span-event 'UnaCordaEvent START)
 treCorde = #(make-span-event 'UnaCordaEvent STOP)
index f078e40da4c80233f7e66edfe0ce3411635f59bc..57eee132f5487d2778a4653e9bc53eb3444d96f9 100644 (file)
@@ -67,7 +67,7 @@ written by Rune Zedeler. "
          (if (equal?
               (ly:get-mus-property music 'iterator-ctor)
               Chord_tremolo_iterator::constructor)
-             (shift-ly:duration-log music  (ly:intlog2 (ly:get-mus-property music 'repeat-count)) 0)
+             (shift-duration-log music  (ly:intlog2 (ly:get-mus-property music 'repeat-count)) 0)
              )
           (ly:set-mus-property!
            music 'length Repeated_music::unfolded_music_length)
@@ -250,6 +250,13 @@ this is not an override
       m
   ))
 
+(define-public (make-span-event type spandir)
+  (let* (
+        (m (make-music-by-name  type))
+        )
+    (ly:set-mus-property! m 'span-direction spandir)
+    m
+    ))
 
 (define-public (set-mus-properties! m alist)
   "Set all of ALIST as properties of M." 
index 7223cc30a2195555ac49acf24a0bd192376854c6..01c7e9771eab8a84b6679167e466845def83bc12 100644 (file)
@@ -1060,11 +1060,14 @@ if 1:
                        r'pitch<\?',
                        r'dir\?',
                        'music-duration-compress',
+                       'set-point-and-click!'
                        ]
 
                origre = r'\b(%s)' % string.join (changed, '|')
                
                str = re.sub (origre, r'ly:\1',str)
+               str = re.sub ('set-point-and-click!', 'set-point-and-click', str)
+               
                return str
        
        conversions.append (((1,7,3), conv, 'ly- -> ly:'))