From 20091095d3ac112fa0d0c55c8e2b8092584be4b2 Mon Sep 17 00:00:00 2001
From: Han-Wen Nienhuys <hanwen@xs4all.nl>
Date: Fri, 17 Aug 2001 01:42:35 +0200
Subject: [PATCH] release: 1.5.7

=========

* Use Cygwin included Python; drop Windows Python and workarounds.

* Include make/lilypond.mandrake.spec (unchecked!) and README.mandrake.

* Comment out two non existing examples in regression test, add one
missing from 1.5.5 distribution.

* Revert silly grace-with-braces stuff in tutorial.

* Add short crescendo bug to input/bugs.

* Update and bit more verbose download instructions in INSTALL,
  fix some links on ftp.lilypond.org.

1.5.6.h
---
 CHANGES                                  |  30 ++++
 Documentation/header.html.in             |   8 +-
 Documentation/regression-test.tely       |   7 +-
 Documentation/user/invoking.itexi        |   2 +-
 INSTALL.txt                              |  55 ++++++--
 VERSION                                  |   4 +-
 input/regression/grace-sync.ly           |   2 +-
 input/regression/spacing-folded-clef.ly  |  12 ++
 input/regression/spacing-grace.ly        |   9 ++
 input/regression/spacing-very-tight.ly   |   6 +-
 lily/grace-iterator.cc                   |   4 +-
 lily/grace-music.cc                      |  11 +-
 lily/include/column-x-positions.hh       |   2 +
 lily/include/new-spacing-spanner.hh      |   2 +-
 lily/include/separating-group-spanner.hh |   1 +
 lily/include/simple-spacer.hh            |   3 +-
 lily/line-of-score.cc                    |  62 ++++++++-
 lily/music-sequence.cc                   |  17 +--
 lily/new-spacing-spanner.cc              |  76 +++++-----
 lily/separating-group-spanner.cc         |  79 +++++++++++
 lily/separating-line-group-engraver.cc   |  27 +---
 lily/sequential-music-iterator.cc        |  16 ++-
 lily/simple-spacer.cc                    |  21 ++-
 lily/spaceable-grob.cc                   |   3 +-
 make/out/lilypond.lsm                    |   8 +-
 make/out/lilypond.mandrake.spec          | 169 +++++++++++++++++++++++
 make/out/lilypond.redhat.spec            |   6 +-
 make/out/lilypond.suse.spec              |   4 +-
 scm/grob-description.scm                 |   2 +-
 scripts/update-lily.py                   |   3 +-
 30 files changed, 519 insertions(+), 132 deletions(-)
 create mode 100644 input/regression/spacing-folded-clef.ly
 create mode 100644 input/regression/spacing-grace.ly
 create mode 100644 make/out/lilypond.mandrake.spec

diff --git a/CHANGES b/CHANGES
index c31ac0c088..843016ab2a 100644
--- a/CHANGES
+++ b/CHANGES
@@ -15,9 +15,39 @@ missing from 1.5.5 distribution.
 * Update and bit more verbose download instructions in INSTALL, 
   fix some links on ftp.lilypond.org.
 
+
+1.5.6.hwn1
+==========
+
+* Grace note bugfixes.
+
+* Move staff-adjacency detection (for the spacing engine) to
+Separating_group_spanner.
+
+* Loose column support: clef changes, key changes may be folded underneath
+notes in a different staff. See input/regression/spacing-folded-clef.ly.
+Changes were made to
+
+  - Separating_group_spanner: decide which columns are loose
+
+  - Simple_spacer, New_spacing_spanner: only look at non-loose columns.
+
+  - Line_of_score: set horizontal positions for loose columns.
+ 
 1.5.6
 =====
 
+* Loose column support: clef changes, key changes may be folded
+underneath notes in a different staff; changes made to
+
+  - Separating_group_spanner: decide which columns are loose
+
+  - Simple_spacer, New_spacing_spanner: only look at non-loose columns.
+
+  - Line_of_score: set horizontal positions for loose columns.
+ 
+
+
 1.4.6.mb1
 =========
 
diff --git a/Documentation/header.html.in b/Documentation/header.html.in
index e7ff35eb8f..45f93fb319 100644
--- a/Documentation/header.html.in
+++ b/Documentation/header.html.in
@@ -70,10 +70,10 @@ which substitutes some @AT_VARIABLES@ as well.
       </td></tr>
       <tr><td><font size="-1">
 	<a href="@TOP@Documentation/out-www/index.html#mailing-lists">About the lists</a><br>
-	<a href="http://mail.gnu.org/mailman/listinfo/gnu-music-discuss/">Discussion</a><br>
-        <a href="http://mail.gnu.org/mailman/listinfo/help-gnu-music/">Help</a><br>
-        <a href="http://mail.gnu.org/mailman/listinfo/bug-gnu-music/">Bugs</a><br>
-        <a href="http://mail.gnu.org/mailman/listinfo/info-gnu-music/">Announcements</a><br>
+	<a href="http://mail.gnu.org/mailman/listinfo/lilypond-user/">Using LilyPond</a><br>
+        <a href="http://mail.gnu.org/mailman/listinfo/lilypond-devel/">Developing LilyPond</a><br>
+        <a href="http://mail.gnu.org/mailman/listinfo/bug-lilypond/">Reporting bugs</a><br>
+        <a href="http://mail.gnu.org/mailman/listinfo/info-lilypond/">Announcements</a><br>
 	<br>
       </font></td></tr>
     <tr><td bgcolor="#e8e8ff"><b>Sites</b></td></tr>
diff --git a/Documentation/regression-test.tely b/Documentation/regression-test.tely
index 95d2347def..03f562a563 100644
--- a/Documentation/regression-test.tely
+++ b/Documentation/regression-test.tely
@@ -92,7 +92,8 @@ Grace note do weird things with timing. Fragile.
 
 @lilypondfile[printfilename]{grace-nest4.ly}
 
-@lilypondfile[printfilename]{grace-nest.ly}
+@lilypondfile[printfilename]{grace-nest5.ly}
+@lilypondfile[printfilename]{grace-nest1.ly}
 
 @lilypondfile[printfilename]{grace-start.ly}
 
@@ -212,9 +213,9 @@ Grace note do weird things with timing. Fragile.
 
 @lilypondfile[printfilename]{spacing-loose.ly}
 
-@c not found @lilypondfile[printfilename]{spacing-accidentals.ly}
+@lilypondfile[printfilename]{spacing-accidental.ly}
 
-@c not found @lilypondfile[printfilename]{spacing-accidentals-staff.ly}
+@lilypondfile[printfilename]{spacing-accidental-staffs.ly}
 
 @lilypondfile[printfilename]{lyrics-bar.ly}
 
diff --git a/Documentation/user/invoking.itexi b/Documentation/user/invoking.itexi
index 583d9219c2..0839266056 100644
--- a/Documentation/user/invoking.itexi
+++ b/Documentation/user/invoking.itexi
@@ -25,7 +25,7 @@ sequentially.
 
 @item -f,--format=@var{format}
 Output format for sheet music. Choices are @code{tex} (for @TeX{}
-output), @code{ps} (for PostScript), @code{scm} (for a Scheme
+output), @code{pdftex} for PDF@TeX input, @code{ps} (for PostScript), @code{scm} (for a Scheme
 dump), and @code{as} (for ASCII-art).
 
 @c TODO: TFMFONTS
diff --git a/INSTALL.txt b/INSTALL.txt
index 22e59ba08c..65765b509d 100644
--- a/INSTALL.txt
+++ b/INSTALL.txt
@@ -8,8 +8,8 @@ Table of Contents
 
 INSTALL - compiling and installing GNU LilyPond
   Downloading
-    source code
-    Binaries
+    Source code
+    Precompiled binaries
     Upgrading
   Requirements
     Compilation
@@ -49,7 +49,7 @@ version (1.2) reside on the GNU servers
 latest odd numbered version (1.3), whose webpages are on the lilypond
 site (http://www.lilypond.org/).
 
-source code
+Source code
 -----------
 
    If you want to compile LilyPond from source, download here:
@@ -62,21 +62,39 @@ source code
    * at `lilypond.org' `ftp://ftp.lilypond.org/pub/LilyPond/' by FTP and
      `http://www.lilypond.org/ftp/' by HTTP.
 
-Binaries
---------
+   Of course, if your platform supports LilyPond, such as Debian
+GNU/Linux, FreeBSD, OpenBSD or NetBSD, you're encouraged to use the
+native build from source drill.
+
+   For Red Hat Linux and SuSE Linux, `.spec' files are included in the
+tarball; see instructions below.
+
+Precompiled binaries
+--------------------
+
+   If you want to track bleeding edge development, try:
 
-   Binaries are available, but are not updated for every version
+   * Debian GNU/Linux
+     (ftp://ftp.debian.org/debian/pool/main/l/lilypond/) usually has
+     the latest binaries for the most useful stable and development
+     versions, while
+
+   * Mandrake Cooker
+     (http://rpmfind.net/linux/mandrake/cooker/contrib/RPMS/) also
+     provides fairly recent versions.
+
+   Binaries are made available for other popular platforms, but as we
+need to compile them ourselves, they are not updated for every version
 released.
+
    * Red Hat i386
      (ftp://ftp.cs.uu.nl/pub/GNU/LilyPond/binaries/RedHat/RPMS/)
 
-   * LinuxPPC (ftp://ftp.lilypond.org/pub/LilyPond/binaries/linuxppc/)
-
-   * Debian GNU/Linux
-     (ftp://ftp.debian.org/debian/pool/main/l/lilypond/)
+   * SuSE (ftp://ftp.lilypond.org/pub/LilyPond/binaries/SuSE)
 
-   * Windows Testing (http://www.lilypond.org/gnu-windows/)
+   * LinuxPPC (ftp://ftp.lilypond.org/pub/LilyPond/binaries/linuxppc/)
 
+   * Windows (http://www.lilypond.org/gnu-windows/)
 
 Upgrading
 ---------
@@ -356,7 +374,11 @@ Mandrake
 --------
 
    Some binaries are available at rpmfind.net. Refer to
-`ftp://ftp.rpmfind.net/linux/Mandrake-devel/cooker/contrib/RPMS/'.
+`http://rpmfind.net/linux/mandrake/cooker/contrib/RPMS/'.
+
+   You can also compile a RPM for Mandrake yourself.  A spec file is in
+`make/out/lilypond.mandrake.spec', see the instructions for building
+the Red Hat RPM.
 
 Debian GNU/Linux
 ----------------
@@ -366,6 +388,15 @@ running `apt-get' as root:
 
      	apt-get install lilypond lilypond-doc
 
+   You can also compile the .deb for Debian yourself, do:
+
+     	apt-get -b source lilypond
+
+   If you're real impatient, you may even do:
+
+     	cd lilypond-x.y.z   # a previous version
+             uscan               # download and build latest directly from upstream
+
    Debian's TeX installation is a bit short on memory, you may want to
 increase it like this:
      --- /etc/texmf/texmf.cnf.dpkg	Sun Jan 28 14:12:14 2001
diff --git a/VERSION b/VERSION
index af67bd19bc..7a3efe2e82 100644
--- a/VERSION
+++ b/VERSION
@@ -1,8 +1,8 @@
 PACKAGE_NAME=LilyPond
 MAJOR_VERSION=1
 MINOR_VERSION=5
-PATCH_LEVEL=6
-MY_PATCH_LEVEL=jcn2
+PATCH_LEVEL=7
+MY_PATCH_LEVEL=
 
 # use the above to send patches: MY_PATCH_LEVEL is always empty for a
 # released version.
diff --git a/input/regression/grace-sync.ly b/input/regression/grace-sync.ly
index 69efcd5df6..8e44e82570 100644
--- a/input/regression/grace-sync.ly
+++ b/input/regression/grace-sync.ly
@@ -6,7 +6,7 @@
 	 \grace  c8
   c4 c4 }
 		\context Staff = SB { c2 \clef bass
- \grace { [dis8 ( d8] }
+ \grace { [dis8 ( d8] \key es\major  }
 
   ) c4 c4 }
 		\context Staff = SC { c2 c4 c4 \bar "|." }
diff --git a/input/regression/spacing-folded-clef.ly b/input/regression/spacing-folded-clef.ly
new file mode 100644
index 0000000000..287d634d0c
--- /dev/null
+++ b/input/regression/spacing-folded-clef.ly
@@ -0,0 +1,12 @@
+\header {
+texidoc = "A clef can be folded below notes in a different staff, if
+this doesn't disrupt the flow of the notes."
+}
+
+\score { \notes \relative c'' <
+\context Staff = SA  { c4 [c16 c c  c] c4 c4 }
+	\context Staff = SB { \clef bass c,2 \clef treble  c'2 }
+	>
+
+	\paper { linewidth = -1. }
+	}
diff --git a/input/regression/spacing-grace.ly b/input/regression/spacing-grace.ly
new file mode 100644
index 0000000000..3b4b32bfa7
--- /dev/null
+++ b/input/regression/spacing-grace.ly
@@ -0,0 +1,9 @@
+\header {
+  texidoc = "Grace note spacing. Should be tuned? "
+}
+	
+\score {
+ \notes \context Voice \relative c'' { \grace { [c16 d] } c4 }
+  \paper { linewidth =-1. }
+
+}
diff --git a/input/regression/spacing-very-tight.ly b/input/regression/spacing-very-tight.ly
index b6fdb49970..79808154d6 100644
--- a/input/regression/spacing-very-tight.ly
+++ b/input/regression/spacing-very-tight.ly
@@ -1,11 +1,15 @@
 \version "1.3.148"
 \header {
+texidoc = "
  When tightly spaced, hinterfleisch -> 0.
  Stems may touch the bar lines, opposite stems may touch eachother.
  We need a mininum of about a note-width/interline space in these
  situations, so that in tightly spaced music all vertical lines
  are about equally spaced.
-}
+
+ "
+ 
+ }
 \score {
 	\notes \relative c''{ 
 		r1 e4 f, e' f,
diff --git a/lily/grace-iterator.cc b/lily/grace-iterator.cc
index fde8167730..8357e2c3ad 100644
--- a/lily/grace-iterator.cc
+++ b/lily/grace-iterator.cc
@@ -25,7 +25,7 @@ void
 Grace_iterator::process (Moment m)
 {
   Moment main ;
-  main.main_part_ = music_length_.grace_part_ + m.grace_part_;
+  main.main_part_ = - start_mom_.grace_part_ + m.grace_part_;
   Music_wrapper_iterator::process (main);
 }
 
@@ -43,7 +43,7 @@ Grace_iterator::pending_moment () const
   Moment cp =Music_wrapper_iterator::pending_moment();
 
   Moment pending;
-  pending.grace_part_ =  cp.main_part_- music_length_.grace_part_ ;
+  pending.grace_part_ =  start_mom_.grace_part_ + cp.main_part_;
 
   return pending;
 }
diff --git a/lily/grace-music.cc b/lily/grace-music.cc
index 27c88c6f7b..8fd0ff0d0b 100644
--- a/lily/grace-music.cc
+++ b/lily/grace-music.cc
@@ -19,17 +19,18 @@ Grace_music::compress (Moment m)
 Moment
 Grace_music::length_mom () const
 {
-  Moment l = Music_wrapper::length_mom ();
-  Moment gl;
-  gl.grace_part_ = l.main_part_ + l.grace_part_ ;
-  return gl;
+  Moment m ;
+  return m;
 }
 
 
 Moment
 Grace_music::start_mom () const
 {
-  return - length_mom ();
+  Moment l = Music_wrapper::length_mom ();
+  Moment gl;
+  gl.grace_part_ = -(l.main_part_ + l.grace_part_ );
+  return gl;
 }
 
 Grace_music::Grace_music ()
diff --git a/lily/include/column-x-positions.hh b/lily/include/column-x-positions.hh
index e8688d3bcd..830fa867ab 100644
--- a/lily/include/column-x-positions.hh
+++ b/lily/include/column-x-positions.hh
@@ -14,6 +14,8 @@
 struct Column_x_positions
 {
   Link_array<Grob> cols_;
+  Link_array<Grob> loose_cols_;
+  
   Array<Real> config_;
   Real force_f_;
   bool satisfies_constraints_b_;
diff --git a/lily/include/new-spacing-spanner.hh b/lily/include/new-spacing-spanner.hh
index 0af0bc5737..ac1ac80696 100644
--- a/lily/include/new-spacing-spanner.hh
+++ b/lily/include/new-spacing-spanner.hh
@@ -17,7 +17,7 @@ class New_spacing_spanner
 {
 public:
   static void set_interface (Grob*);
-  static void do_measure (Grob*,Link_array<Grob> const &) ;
+  static void do_measure (Grob*,Link_array<Grob> *) ;
   static void stretch_to_regularity (Grob*, Array<Spring> *, Link_array<Grob> const &);
   static void breakable_column_spacing (Item* l, Item *r);
   DECLARE_SCHEME_CALLBACK (set_springs, (SCM ));
diff --git a/lily/include/separating-group-spanner.hh b/lily/include/separating-group-spanner.hh
index 1b8baf9ea9..c394821df4 100644
--- a/lily/include/separating-group-spanner.hh
+++ b/lily/include/separating-group-spanner.hh
@@ -19,6 +19,7 @@ public:
   static void find_rods (Item*, SCM);
   static void set_interface (Grob*);
   static bool has_interface (Grob*);
+  static void find_musical_sequences (Grob*);
   DECLARE_SCHEME_CALLBACK (set_spacing_rods, (SCM ));
 };
 
diff --git a/lily/include/simple-spacer.hh b/lily/include/simple-spacer.hh
index 2f13a107d2..8115e25587 100644
--- a/lily/include/simple-spacer.hh
+++ b/lily/include/simple-spacer.hh
@@ -63,7 +63,8 @@ struct Spring_description
 struct Simple_spacer
 {
   Array<Spring_description> springs_;
-
+  Link_array<Grob> spaced_cols_;
+  Link_array<Grob> loose_cols_;
   Real force_f_;
   Real indent_f_;
   Real line_len_f_;
diff --git a/lily/line-of-score.cc b/lily/line-of-score.cc
index 9c70f62adb..a6cff9391f 100644
--- a/lily/line-of-score.cc
+++ b/lily/line-of-score.cc
@@ -123,6 +123,66 @@ Line_of_score::output_lines ()
     }
 }
 
+/*
+  Find the loose columns in POSNS, and drape them around the columns
+  specified in BETWEEN-COLS.  */
+void
+set_loose_columns (Line_of_score* which, Column_x_positions const *posns)
+{
+  for (int i = 0; i<posns->loose_cols_.size (); i++)
+    {
+      int divide_over = 1;
+      Item *loose = dynamic_cast<Item*> (posns->loose_cols_[i]);
+      Paper_column* col = dynamic_cast<Paper_column*> (loose);
+      
+      if (col->line_l_)
+	continue;
+
+      
+      Item * left = 0;
+      Item * right = 0;
+      while (1)
+	{
+	  
+	  SCM between = loose->get_grob_property ("between-cols");
+	  if (!gh_pair_p (between))
+	    break;
+
+	  if (!left)
+	    {
+	      left = dynamic_cast<Item*> (unsmob_grob (gh_car (between)));
+	      left = left->column_l ();
+	    }
+	  divide_over ++;	
+	  loose = dynamic_cast<Item*> (unsmob_grob (gh_cdr (between)));
+	  loose = loose->column_l ();
+	}
+
+      right = loose;
+
+      Real rx = right->relative_coordinate (right->parent_l (X_AXIS), X_AXIS);
+      Real lx = left->relative_coordinate (left->parent_l (X_AXIS), X_AXIS);
+
+      int j = 1;
+      loose = col;
+      while (1)
+	{
+	  SCM between = loose->get_grob_property ("between-cols");
+	  if (!gh_pair_p (between))
+	    break;
+
+	  Paper_column *thiscol = dynamic_cast<Paper_column*> (loose);
+
+	  thiscol->line_l_ = which;
+	  thiscol->translate_axis (lx + j*(rx - lx)/divide_over, X_AXIS);
+
+	  j ++;	
+	  loose = dynamic_cast<Item*> (unsmob_grob (gh_cdr (between)));
+	}
+      
+    }
+}
+
 // const?
 void
 Line_of_score::break_into_pieces (Array<Column_x_positions> const &breaking)
@@ -142,7 +202,7 @@ Line_of_score::break_into_pieces (Array<Column_x_positions> const &breaking)
 	  c[j]->translate_axis (breaking[i].config_[j],X_AXIS);
 	  dynamic_cast<Paper_column*> (c[j])->line_l_ = line_l;
 	}
-      
+      set_loose_columns (line_l, &breaking[i]);
       broken_into_l_arr_.push (line_l);
     }
 }
diff --git a/lily/music-sequence.cc b/lily/music-sequence.cc
index a8e9e76fa5..1df990d42b 100644
--- a/lily/music-sequence.cc
+++ b/lily/music-sequence.cc
@@ -86,8 +86,6 @@ Music_sequence::cumulative_length () const
   last_len.grace_part_ = Rational (0);
   cumulative += last_len;
 
-  cumulative += - first_start ();
-  
   return  cumulative;
 }
 
@@ -105,12 +103,10 @@ Music_sequence::maximum_length () const
   for (SCM s = music_list (); gh_pair_p (s);  s = gh_cdr (s))
     {
       Music * m = unsmob_music (gh_car (s));
-      Moment l = m->length_mom () + m->start_mom ();
+      Moment l = m->length_mom ();
       dur = dur >? l;
     }
 
-  dur -= minimum_start ();
-  
   return dur;
 }
 int
@@ -175,14 +171,9 @@ Music_sequence::first_start () const
     {
       Music * mus = unsmob_music (gh_car (s));
       Moment l = mus->length_mom ();
-
-      if (l.main_part_)
-	return mus->start_mom ();
-      else if (l.grace_part_)
-	{
-	  m.grace_part_ = - l.grace_part_; 
-	  return m;
-	}
+      Moment s = mus->start_mom ();
+      if (l.to_bool () || s.to_bool ())
+	return s;
     }
   return m;
 }
diff --git a/lily/new-spacing-spanner.cc b/lily/new-spacing-spanner.cc
index b67c373fcb..4ed9c7afde 100644
--- a/lily/new-spacing-spanner.cc
+++ b/lily/new-spacing-spanner.cc
@@ -39,7 +39,7 @@ New_spacing_spanner::set_interface (Grob*me)
   
  */
 void
-New_spacing_spanner::do_measure (Grob*me, Link_array<Grob> const & cols) 
+New_spacing_spanner::do_measure (Grob*me, Link_array<Grob> *cols) 
 {
   Moment shortest;
   Moment mean_shortest;
@@ -50,12 +50,18 @@ New_spacing_spanner::do_measure (Grob*me, Link_array<Grob> const & cols)
   Moment base_shortest_duration = *unsmob_moment (me->get_grob_property ("maximum-duration-for-spacing"));
   shortest.set_infinite (1);
 
+  for (int i = cols->size(); i--;)
+    {
+      if (gh_pair_p (cols->elem(i)->get_grob_property ("between-cols")))
+	cols->del (i);
+    }
+  
   int n = 0;
-  for (int i =0 ; i < cols.size (); i++)  
+  for (int i =0 ; i < cols->size (); i++)  
     {
-      if (Paper_column::musical_b (cols[i]))
+      if (Paper_column::musical_b (cols->elem (i)))
 	{
-	  Moment *when = unsmob_moment (cols[i]->get_grob_property  ("when"));
+	  Moment *when = unsmob_moment (cols->elem (i)->get_grob_property  ("when"));
 
 	  /*
 	    ignore grace notes for shortest notes.
@@ -63,7 +69,7 @@ New_spacing_spanner::do_measure (Grob*me, Link_array<Grob> const & cols)
 	  if (when && when->grace_part_)
 	    continue;
 	  
-	  SCM  st = cols[i]->get_grob_property ("shortest-starter-duration");
+	  SCM  st = cols->elem (i)->get_grob_property ("shortest-starter-duration");
 	  Moment this_shortest = *unsmob_moment (st);
 	  shortest = shortest <? this_shortest;
 	  if (!mean_shortest.main_part_.infty_b ())
@@ -77,37 +83,14 @@ New_spacing_spanner::do_measure (Grob*me, Link_array<Grob> const & cols)
   Array<Spring> springs;
 
   Item * first_col = 0;
-  for (int i= 0; i < cols.size () - 1; i++)
+  for (int i= 0; i < cols->size () - 1; i++)
     {
-      Item * l = dynamic_cast<Item*> (cols[i]);
+      Item * l = dynamic_cast<Item*> (cols->elem (i));
 
       if (!first_col && Paper_column::musical_b (l))
 	first_col = l;
 
-      SCM between = cols[i]->get_grob_property ("between-cols"); 
-      if (gh_pair_p (between)
-	  && i > 0
-	  && i < cols.size ()-1
-	  && (gh_cdr (between) != cols[i+1]->self_scm ()
-	   || gh_car (between) != cols[i-1]->self_scm ()) 
-	  )
-	continue ;
-      
-      int j = i+1;
-      for (; j < cols.size () - 1; j++)
-	{
-	  if  (Paper_column::musical_b (cols[j]))
-	    break;
-
-	  SCM between = cols[j]->get_grob_property ("between-cols");
-	  if (!gh_pair_p (between))
-	    continue;
-
-	  if (gh_car (between) == cols[i]->self_scm () )
-	    break ;
-	}
-
-      Item * r =  dynamic_cast<Item*> (cols[j]);
+      Item * r =  dynamic_cast<Item*> (cols->elem (i+1));
       Paper_column * lc = dynamic_cast<Paper_column*> (l);
       Paper_column *rc = dynamic_cast<Paper_column*> (r);
 
@@ -370,7 +353,7 @@ New_spacing_spanner::get_duration_space (Grob*me, Moment d, Moment shortest)
 
 Real
 New_spacing_spanner::note_spacing (Grob*me, Grob *lc, Grob *rc,
-			       Moment shortest) 
+				   Moment shortest) 
 {
   Moment shortest_playing_len = 0;
   SCM s = lc->get_grob_property ("shortest-playing-duration");
@@ -391,15 +374,32 @@ New_spacing_spanner::note_spacing (Grob*me, Grob *lc, Grob *rc,
       shortest = 1;
     }
   Moment delta_t = Paper_column::when_mom (rc) - Paper_column::when_mom (lc);
-  Real dist = get_duration_space (me, shortest_playing_len, shortest);
+  Real dist = 0.0;
 
+  if (delta_t.main_part_)
+    {
+      dist = get_duration_space (me, shortest_playing_len, shortest);
+      dist *= (double) (delta_t.main_part_ / shortest_playing_len.main_part_);
+    }
+  else if (delta_t.grace_part_)
+    {
+      dist = get_duration_space (me, shortest, shortest);
 
+      Real grace_fact = 1.0;
+      SCM gf = me->get_grob_property ("grace-space-factor");
+      if (gh_number_p (gf))
+	grace_fact = gh_scm2double (gf);
+
+      dist *= grace_fact; 
+    }
+
+#if 0
   /*
-    ugh: 0.1 is an arbitrary distance.
+    TODO: figure out how to space grace notes.
    */
-  dist *= (double) (delta_t.main_part_ / shortest_playing_len.main_part_)
-    + 0.1 * (double) (delta_t.grace_part_ / shortest_playing_len.main_part_);
 
+  dist *= 
+    +  grace_fact * (double) (delta_t.grace_part_ / shortest_playing_len.main_part_);
 
 
   Moment *lm = unsmob_moment (lc->get_grob_property ("when"));
@@ -412,7 +412,7 @@ New_spacing_spanner::note_spacing (Grob*me, Grob *lc, Grob *rc,
       else if (!rm->grace_part_ && lm->grace_part_)
 	dist *= 0.7;
     }
-
+#endif
   
   return dist;
 }
@@ -483,7 +483,7 @@ New_spacing_spanner::set_springs (SCM smob)
       if (Item::breakable_b (sc))
         {
 	  Link_array<Grob> measure (all.slice (j, i+1));	  
-          do_measure (me, measure);
+          do_measure (me, &measure);
 	  j = i;
         }
     }
diff --git a/lily/separating-group-spanner.cc b/lily/separating-group-spanner.cc
index d102e35bdb..9a1c85d51b 100644
--- a/lily/separating-group-spanner.cc
+++ b/lily/separating-group-spanner.cc
@@ -96,6 +96,7 @@ Separating_group_spanner::set_spacing_rods (SCM smob)
 	find_rods (rb, gh_cdr (s));
     }
 
+  find_musical_sequences (me);
 #if 0
   /*
     TODO; restore this.
@@ -126,6 +127,84 @@ Separating_group_spanner::add_spacing_unit (Grob* me ,Item*i)
 }
 
 
+void
+Separating_group_spanner::find_musical_sequences (Grob *me)
+{
+  Item *last = 0;
+  Item *llast = 0;
+  for (SCM s = me->get_grob_property ("elements");
+       gh_pair_p (s); s = gh_cdr (s))
+    {
+      Item *it = dynamic_cast<Item*> (unsmob_grob (gh_car (s)));
+      if (last)
+	{	
+	  Item *lcol = last->column_l ();
+	  Item *col = it->column_l ();
+
+	  int lrank = Paper_column::rank_i (lcol);
+	  int rank = Paper_column ::rank_i (col);
+
+	  bool mus = Paper_column::musical_b (col);
+	  bool lmus = Paper_column::musical_b (lcol);
+
+	  if ((lrank - rank == 2) && lmus && mus)
+	    {
+	      SCM seq = col->get_grob_property ("spacing-sequence");
+	      col->set_grob_property ("spacing-sequence",
+				      gh_cons (gh_cons (it->self_scm (), last->self_scm ()), seq));
+	    }
+
+	  if (llast && !Paper_column::breakable_b (last))
+	    {
+	      Item *llcol = llast->column_l ();
+	      int llrank = Paper_column::rank_i (llcol);
+	      bool llmus= Paper_column::musical_b (llcol);
+	      if (llrank - lrank == 1
+		  && lrank - rank == 1
+		  && llmus && !lmus && mus)
+		{
+		  SCM seq = col->get_grob_property ("spacing-sequence");
+		  col->set_grob_property ("spacing-sequence",
+					  gh_cons (gh_cons (it->self_scm (), last->self_scm ()), seq));
+		}
+	      else if (!lmus)
+		{
+		  SCM between = lcol->get_grob_property ("between-cols");
+
+		  if (!gh_pair_p (between))
+		    {
+		      between = gh_cons (it->self_scm (), llast->self_scm ());
+		      lcol ->set_grob_property ("between-cols", between);
+		    }
+
+		  Item * left
+		    = dynamic_cast<Item*> (unsmob_grob (gh_car (between)));
+		  if(Paper_column::rank_i (left->column_l ()) < rank)
+		    gh_set_car_x (between, col->self_scm());
+		  
+		  Item * right
+		    = dynamic_cast<Item*> (unsmob_grob (gh_cdr (between)));
+		  if (Paper_column::rank_i (right->column_l ()) > llrank )
+		    gh_set_cdr_x (between, llcol->self_scm ());
+		}
+	    }
+	}
+
+      llast = last;
+      last = it;
+    }
+}
+
+#if 0
+void
+Separating_group_spanner::set_loose_rods ()
+{
+  // loose columns should  also generate minimum distances.
+  // TODO
+}
+#endif
+
+
 void
 Separating_group_spanner::set_interface (Grob*)
 {
diff --git a/lily/separating-line-group-engraver.cc b/lily/separating-line-group-engraver.cc
index 0de0777d9d..6c3811b8e2 100644
--- a/lily/separating-line-group-engraver.cc
+++ b/lily/separating-line-group-engraver.cc
@@ -20,12 +20,6 @@ protected:
   Item * break_malt_p_;
   Item * musical_malt_p_;
 
-  /*
-    malt_p_ : we used to have a Single_malt_grouping_item
-    
-   */
-  Item * last_step_musical_malt_p_;
-  
   Spanner * sep_span_p_;
   
   virtual void acknowledge_grob (Grob_info);
@@ -39,7 +33,6 @@ public:
 
 Separating_line_group_engraver::Separating_line_group_engraver ()
 {
-  last_step_musical_malt_p_ = 0;
   sep_span_p_ = 0;
   break_malt_p_ = 0;
   musical_malt_p_ =0;
@@ -102,26 +95,12 @@ Separating_line_group_engraver::stop_translation_timestep ()
     }
 
   if (musical_malt_p_)
-      {
+    {
       Separating_group_spanner::add_spacing_unit (sep_span_p_, musical_malt_p_);
-
-      if (last_step_musical_malt_p_)
-	{
-	  Paper_column *col = 
-	    last_step_musical_malt_p_->column_l();
-	  SCM newtup = gh_cons (last_step_musical_malt_p_->self_scm (),
-				musical_malt_p_->self_scm ());
-	  col->set_grob_property ("spacing-sequence",
-				  gh_cons (newtup,
-					   col->get_grob_property ("spacing-sequence")));
-	}
-      
       typeset_grob (musical_malt_p_);
-      }
-  last_step_musical_malt_p_ = musical_malt_p_;
-  musical_malt_p_ =0;
-
+    }
 
+  musical_malt_p_ =0;
 }
 
 
diff --git a/lily/sequential-music-iterator.cc b/lily/sequential-music-iterator.cc
index 5d8ce337de..f37320caf0 100644
--- a/lily/sequential-music-iterator.cc
+++ b/lily/sequential-music-iterator.cc
@@ -97,8 +97,8 @@ get_grace_fixups (SCM cursor)
   for (; gh_pair_p (cursor); cursor = gh_cdr (cursor))
     {
       Music * mus = unsmob_music (gh_car (cursor));
-      Moment l =mus->length_mom ();
       Moment s = mus->start_mom ();
+      Moment l =mus->length_mom () - s;
 
       if (s.grace_part_)
 	{
@@ -154,7 +154,7 @@ Sequential_music_iterator::construct_children ()
 void
 Sequential_music_iterator::next_element ()
 {
-  Moment len =iter_p_->music_length_mom ();
+  Moment len =iter_p_->music_length_mom () - iter_p_->music_start_mom ();
   assert (!grace_fixups_  || grace_fixups_->start_ >= here_mom_);
   
   if (len.main_part_ && grace_fixups_ &&
@@ -245,8 +245,10 @@ Sequential_music_iterator::get_music (Moment until)const
       
       Moment m = 0;
       for (SCM i = nm; gh_pair_p (i); i = gh_cdr (i))
-	m = m >? unsmob_music (gh_car (i))->length_mom ();
-
+	{
+	  Music *mus=unsmob_music (gh_car (i));
+	  m = m >? (mus->length_mom () - mus->start_mom ());
+	}
       if (m > Moment (0))
 	break ;
       else
@@ -256,6 +258,8 @@ Sequential_music_iterator::get_music (Moment until)const
   
   return s;
 }
+
+
 /*
   Skip events till UNTIL. We don't do any other side effects such as
   descending to child iterator contexts, because they might depend on
@@ -291,9 +295,7 @@ Sequential_music_iterator::process (Moment until)
 	  /*
 	    do the stuff/note/rest preceding a grace.
 	   */
-	  iter_p_->process (iter_p_->music_length_mom ()+ 
-			    iter_p_->music_start_mom ());
-
+	  iter_p_->process (iter_p_->music_length_mom ());
 	}
       else
 	iter_p_->process (until - here_mom_ + iter_p_->music_start_mom ());
diff --git a/lily/simple-spacer.cc b/lily/simple-spacer.cc
index 0340596ad3..6671a6edb6 100644
--- a/lily/simple-spacer.cc
+++ b/lily/simple-spacer.cc
@@ -167,11 +167,19 @@ Simple_spacer::my_solve_natural_len ()
 void
 Simple_spacer::add_columns (Link_array<Grob> cols)
 {
+  for (int i =  cols.size (); i--;)
+    if (gh_pair_p (cols[i]->get_grob_property ("between-cols")))
+      {
+	loose_cols_.push (cols[i]);
+	cols.del (i);
+      }
+  
+  spaced_cols_ = cols;
   for (int i=0; i < cols.size () - 1; i++)
     {
-      SCM spring_params = SCM_UNDEFINED;
+      SCM spring_params = SCM_EOL;
       for (SCM s = cols[i]->get_grob_property ("ideal-distances");
-	   spring_params == SCM_UNDEFINED && gh_pair_p (s);
+	   !gh_pair_p (spring_params) && gh_pair_p (s);
 	   s = gh_cdr (s))
 	{
 	  Grob *other = unsmob_grob (gh_caar (s));
@@ -182,7 +190,7 @@ Simple_spacer::add_columns (Link_array<Grob> cols)
 	}
 
       Spring_description desc;
-      if (spring_params != SCM_UNDEFINED)
+      if (gh_pair_p (spring_params))
 	{
 	  desc.ideal_f_ = gh_scm2double (gh_car (spring_params));
 	  desc.hooke_f_ = gh_scm2double (gh_cdr (spring_params));
@@ -199,6 +207,9 @@ Simple_spacer::add_columns (Link_array<Grob> cols)
       if (!desc.sane_b ())
 	{
 	  programming_error ("Insane spring found. Setting to unit spring.");
+
+	  cout << "columns " << Paper_column::rank_i (cols[i])
+	       << " " << Paper_column::rank_i (cols[i+1]) << endl;
 	  desc.hooke_f_ = 1.0;
 	  desc.ideal_f_ = 1.0;
 	}
@@ -240,7 +251,9 @@ Simple_spacer::solve (Column_x_positions *positions) const
     {
       positions->config_.push (positions->config_.top () + springs_[i].length (force_f_));
     }
-
+  positions->cols_ = spaced_cols_;
+  positions->loose_cols_ = loose_cols_;
+  
   positions->satisfies_constraints_b_ = (line_len_f_ < 0) || active_b ();
 }
 
diff --git a/lily/spaceable-grob.cc b/lily/spaceable-grob.cc
index 8aa3209f28..26bf4e8066 100644
--- a/lily/spaceable-grob.cc
+++ b/lily/spaceable-grob.cc
@@ -43,6 +43,8 @@ void
 Spaceable_grob::add_spring (Grob*me, Grob * p, Real d, Real strength)
 {
   SCM mins = me->get_grob_property ("ideal-distances");
+  
+  
   SCM newdist= gh_double2scm (d);
   for (SCM s = mins; gh_pair_p (s); s = gh_cdr (s))
     {
@@ -60,7 +62,6 @@ Spaceable_grob::add_spring (Grob*me, Grob * p, Real d, Real strength)
 }
 
 
-
 void
 Spaceable_grob::remove_interface (Grob*me)
 {
diff --git a/make/out/lilypond.lsm b/make/out/lilypond.lsm
index 2fbafa4e25..e04509eff2 100644
--- a/make/out/lilypond.lsm
+++ b/make/out/lilypond.lsm
@@ -1,15 +1,15 @@
 Begin3
 Title: LilyPond
-Version: 1.5.6
-Entered-date: 14AUG01
+Version: 1.5.7
+Entered-date: 17AUG01
 Description: @BLURB@
 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.5.6.tar.gz 
+	1000k lilypond-1.5.7.tar.gz 
 Original-site: ftp.cs.uu.nl /pub/GNU/LilyPond/development/
-	1000k lilypond-1.5.6.tar.gz 
+	1000k lilypond-1.5.7.tar.gz 
 Copying-policy: GPL
 End
diff --git a/make/out/lilypond.mandrake.spec b/make/out/lilypond.mandrake.spec
new file mode 100644
index 0000000000..471b69a0da
--- /dev/null
+++ b/make/out/lilypond.mandrake.spec
@@ -0,0 +1,169 @@
+%define name lilypond
+%define version 1.5.7
+%define release 1mdk
+
+Name: %{name}
+Summary: A program for printing sheet music.
+Version: %{version}
+Release: %{release}
+Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-%{version}.tar.gz
+## Patch0: lilypond-GNUmakefile.in.patch.bz2
+License: GPL
+Group: Publishing
+URL: http://www.lilypond.org/
+BuildRoot: %{_tmppath}/%{name}-buildroot
+BuildRequires: guile guile-devel
+Requires: tetex
+
+%description
+LilyPond is a music typesetter.  It produces beautiful sheet music using a
+high level description file as input.  Lilypond is part of the GNU project.
+ 
+LilyPond is split into two packages.  The package "lilypond" provides the
+core package, containing the utilities for converting the music source
+(.ly) files into printable output.  The package "lilypond-extras" provides
+the full documentation, example .ly files for various features and the
+Mutopia project files (musical equivalent of the Gutenberg project - see
+http://www.mutopiaproject.org for details).
+ 
+If you are new to lilypond, you will almost certainly want to install the
+"lilypond-extras" package in addition to the "lilypond" package.
+ 
+You may also wish to investigate the "denemo" package, which provides a
+graphical front end to lilypond.
+
+See the file README.first for more information.
+
+
+%package extras
+Summary: LilyPond documentation, examples and Mutopia files.
+Group: Publishing
+Requires: lilypond
+
+%description extras
+The documentation of LilyPond, both in HTML and PostScript, along with
+example input files and the files from the Mutopia project.
+
+%prep
+%setup -a 1
+## % patch0 -b .orig
+
+%build
+# DO NOT use % { configure } , it hardcodes all paths, runs libtool,
+# so we can't do make prefix=/tmp/ install.
+# -- not sure what this comment means; it's a relic from the PPC spec file -- mbrown@fensystems.co.uk
+./configure --disable-checking --disable-debugging --enable-printing --prefix=%{_prefix} --disable-optimise --enable-shared
+make
+make local-web
+
+%install
+
+# Create installation root folders
+rm -rf $RPM_BUILD_ROOT
+RPM_DOC_ROOT=$RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
+rm -rf $RPM_DOC_ROOT
+mkdir -p $RPM_DOC_ROOT
+
+make prefix="$RPM_BUILD_ROOT%{_prefix}" install
+%{find_lang} %{name}
+
+# Move info and man files into correct locations
+mv $RPM_BUILD_ROOT/usr/info $RPM_BUILD_ROOT%{_infodir}
+mv $RPM_BUILD_ROOT/usr/man $RPM_BUILD_ROOT%{_mandir}
+
+# Move TeX font files into system TeX tree locations
+mkdir -p $RPM_BUILD_ROOT%{_datadir}/texmf/fonts/{afm,source,tfm}
+mv $RPM_BUILD_ROOT%{_datadir}/lilypond/afm $RPM_BUILD_ROOT%{_datadir}/texmf/fonts/afm/lilypond
+mv $RPM_BUILD_ROOT%{_datadir}/lilypond/mf $RPM_BUILD_ROOT%{_datadir}/texmf/fonts/source/lilypond
+mv $RPM_BUILD_ROOT%{_datadir}/lilypond/tfm $RPM_BUILD_ROOT%{_datadir}/texmf/fonts/tfm/lilypond
+mkdir -p $RPM_BUILD_ROOT%{_datadir}/texmf/tex
+mv $RPM_BUILD_ROOT%{_datadir}/lilypond/tex $RPM_BUILD_ROOT%{_datadir}/texmf/tex/lilypond
+
+# Copy emacs mode files into %{_datadir}/lilypond/emacs
+mkdir -p $RPM_BUILD_ROOT%{_datadir}/lilypond/emacs
+cp *.el $RPM_BUILD_ROOT%{_datadir}/lilypond/emacs/
+
+# Create documentation tree in %{_docdir}
+mkdir -p $RPM_DOC_ROOT/HTML
+tar -C $RPM_DOC_ROOT/HTML -xzf out/web.tar.gz
+ln -s HTML/input $RPM_DOC_ROOT/Examples
+ln -s HTML/input/test $RPM_DOC_ROOT/Tricks
+ln -s HTML/mutopia $RPM_DOC_ROOT/Mutopia
+mkdir -p $RPM_DOC_ROOT/Printable
+ln -s ../HTML/Documentation/user/out-www/lilypond.ps.gz $RPM_DOC_ROOT/Printable/Manual.ps.gz
+ln -s ../HTML/Documentation/user/out-www/glossary.ps.gz $RPM_DOC_ROOT/Printable/Glossary.ps.gz
+cp AUTHORS.txt CHANGES COPYING DEDICATION FAQ.txt NEWS README.txt VERSION README.mandrake $RPM_DOC_ROOT/README.first
+
+%post
+touch /tmp/.lilypond-install
+rm `find /var/lib/texmf -name 'feta*pk -print' -or -name 'feta*tfm -print'` /tmp/.lilypond-install
+/usr/bin/mktexlsr
+%_install_info lilypond.info
+%_install_info lilypond-internals.info
+
+%preun
+%_remove_install_info lilypond.info
+%_remove_install_info lilypond-internals.info
+
+%postun
+/usr/bin/mktexlsr
+
+
+%files -f %{name}.lang
+%defattr(-,root,root,0755)
+%{_bindir}/*
+%{_datadir}/lilypond/
+%{_datadir}/texmf/fonts/afm/lilypond
+%{_datadir}/texmf/fonts/source/lilypond
+%{_datadir}/texmf/fonts/tfm/lilypond
+%{_datadir}/texmf/tex/lilypond
+
+%doc %{_infodir}/*
+%doc %{_mandir}/man1/*
+%doc %{_docdir}/%{name}-%{version}/AUTHORS.txt
+%doc %{_docdir}/%{name}-%{version}/CHANGES
+%doc %{_docdir}/%{name}-%{version}/COPYING
+%doc %{_docdir}/%{name}-%{version}/DEDICATION
+%doc %{_docdir}/%{name}-%{version}/FAQ.txt
+%doc %{_docdir}/%{name}-%{version}/NEWS
+%doc %{_docdir}/%{name}-%{version}/README.txt
+%doc %{_docdir}/%{name}-%{version}/VERSION
+%doc %{_docdir}/%{name}-%{version}/README.first
+
+%files extras
+%defattr(-,root,root,0755)
+%doc %{_docdir}/%{name}-%{version}/HTML
+%doc %{_docdir}/%{name}-%{version}/Mutopia
+%doc %{_docdir}/%{name}-%{version}/Printable
+%doc %{_docdir}/%{name}-%{version}/Tricks
+%doc %{_docdir}/%{name}-%{version}/Examples
+
+
+%changelog
+* Fri Jun 01 2001 Lenny Cartier <lenny@mandrakesoft.com> 1.4.2-1mdk
+- updated by Michael Brown <mbrown@linux-mandrake.com> :
+	- Upgraded to 1.4.2
+	- Changed URL
+	- Removed /etc/profile.d scripts: all TeX bits are now located properly
+	- Rearranged documentation
+	- Tidied spec file
+	- Updated README.first
+
+* Mon Feb 26 2001 Lenny Cartier <lenny@mandrakesoft.com> 1.3.129-1mdk
+- added in contribs by Michael Brown <mbrown@fensystems.co.uk> :
+	- Removed info files completely (couldn't get info reader to read them)
+	- TODO: Get this to work at some point (in the meantime, use documentation in lilypond-extras)
+
+* Sat Feb 17 2001 Michael Brown <mbrown@fensystems.co.uk>
+- Moved TeX font folders into the system TeX tree (this ensures that the /var/lib/texmf font cache is used instead of current folder)
+- Added mktexlsr to post-install and post-uninstall scripts
+- Patched scripts in /etc/profile.d to reflect changes to font locations
+- Added QuickStart guide and Points to note sections to README.first (well worth reading)
+- Fixed install-info and uninstall-info sections to use Mandrake's RPM macros :-)
+
+* Tue Feb 13 2001 Michael Brown <mbrown@fensystems.co.uk>
+- First Mandrake package
+- spec file heavily adapted from PowerPC contribs.
+- Note HTML documentation may contain duff links and may be incomplete.  Lots of warnings appear when building HTML docs.
+- PostScript documentation is duplicated (how do you get an rpm package to contain a symlink?)
+- Created README.first file
diff --git a/make/out/lilypond.redhat.spec b/make/out/lilypond.redhat.spec
index 946c7b90a5..c45927288b 100644
--- a/make/out/lilypond.redhat.spec
+++ b/make/out/lilypond.redhat.spec
@@ -1,13 +1,13 @@
 %define info yes
 
 Name: lilypond
-Version: 1.5.6
+Version: 1.5.7
 Release: 1
 License: GPL
 Group: Applications/Publishing
-Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.5.6.tar.gz
+Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.5.7.tar.gz
 Summary: Create and print music notation 
-URL: http://www.cs.uu.nl/~hanwen/lilypond
+URL: http://www.lilypond.org/
 BuildRoot: /tmp/lilypond-install
 # add lots of Buildreq: flex, bison, tetex, tetex-devel, tetex-latex, texinfo
 # better prereqs: tetex-latex, python, (mpost?) etc.
diff --git a/make/out/lilypond.suse.spec b/make/out/lilypond.suse.spec
index 4ff11cf3ed..c181554716 100644
--- a/make/out/lilypond.suse.spec
+++ b/make/out/lilypond.suse.spec
@@ -14,11 +14,11 @@
 
 Distribution: SuSE Linux 7.0 (i386)
 Name: lilypond
-Version: 1.5.6
+Version: 1.5.7
 Release: 2
 Copyright:    GPL
 Group: Applications/Publishing
-Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.5.6.tar.gz
+Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.5.7.tar.gz
 # music notation software for.. ?
 Summary: A program for printing sheet music.
 URL: http://www.lilypond.org/
diff --git a/scm/grob-description.scm b/scm/grob-description.scm
index 0a76e6263c..c24f369723 100644
--- a/scm/grob-description.scm
+++ b/scm/grob-description.scm
@@ -502,7 +502,7 @@
 	(SpacingSpanner . (
 		(spacing-procedure . ,Spacing_spanner::set_springs)
 		(stem-spacing-correction . 0.5)
-
+		(grace-space-factor . 0.8)
 
 		;; TODO: change naming -- unintuitive
 		(arithmetic-basicspace . 2.0)
diff --git a/scripts/update-lily.py b/scripts/update-lily.py
index b1fdd3420f..1d16dbdbf3 100644
--- a/scripts/update-lily.py
+++ b/scripts/update-lily.py
@@ -5,7 +5,8 @@
 # source file of the GNU LilyPond music typesetter
 #
 # download and rebuild latest lilypond or from specified url
-# 
+#
+
 
 '''
 TODO:
-- 
2.39.5