From 570b036c77a7143584d08eb81390d78702886b8e Mon Sep 17 00:00:00 2001 From: Han-Wen Nienhuys Date: Tue, 5 Apr 2005 22:52:50 +0000 Subject: [PATCH] * input/test/spacing-optical.ly (Module): new file. * lily/staff-spacing.cc: add same-direction-correction --- ChangeLog | 6 ++++ Documentation/user/introduction.itely | 2 +- input/regression/backend-excercise.ly | 2 ++ input/test/spacing-optical.ly | 44 +++++++++++++++++++++++++++ lily/staff-spacing.cc | 2 +- 5 files changed, 54 insertions(+), 2 deletions(-) create mode 100644 input/test/spacing-optical.ly diff --git a/ChangeLog b/ChangeLog index e5a003c571..a7cf271a23 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2005-04-06 Han-Wen Nienhuys + + * input/test/spacing-optical.ly (Module): new file. + + * lily/staff-spacing.cc: add same-direction-correction + 2005-04-06 Jan Nieuwenhuizen * Documentation/user/introduction.itely (Engraving): Comment-out diff --git a/Documentation/user/introduction.itely b/Documentation/user/introduction.itely index ca61f9b69a..b72e36916f 100644 --- a/Documentation/user/introduction.itely +++ b/Documentation/user/introduction.itely @@ -109,7 +109,7 @@ exact mathematical spacing, and once with corrections. Can you spot which fragment is which? @cindex optical spacing -@c @lily pondfile[quote,noindent]{spacing-optical.ly} +@lilypondfile[quote,noindent]{spacing-optical.ly} @cindex regular rhythms @cindex regular spacing diff --git a/input/regression/backend-excercise.ly b/input/regression/backend-excercise.ly index ad8a65720a..d2694952c5 100644 --- a/input/regression/backend-excercise.ly +++ b/input/regression/backend-excercise.ly @@ -10,6 +10,8 @@ { #(set-octavation 1) \times 2/3 { c'8[\< f]( f''\!) } + #(set-octavation 0) + } \skip 1 >> \new Staff \relative c'' { diff --git a/input/test/spacing-optical.ly b/input/test/spacing-optical.ly new file mode 100644 index 0000000000..e87bdfb111 --- /dev/null +++ b/input/test/spacing-optical.ly @@ -0,0 +1,44 @@ + +\header { +texidoc = "Stem directions and head positions are taken into account for spacing " + +} + +\paper { + raggedright = ##t + indent = #0.0 +} + +music = { + c'4 e''4 e'4 b'4 | + \stemDown + b'8[ e'' a' e''] + \stemNeutral + e'8[ e'8 e'8 e'8] +} + + + +\score +{ + \music + \layout { + \context { + \Staff + \override NoteSpacing #'stem-spacing-correction = #0.6 + } + } +} + +\score +{ + \music + \layout { + \context { + \Staff + \override NoteSpacing #'stem-spacing-correction = #0.0 + \override NoteSpacing #'same-direction-correction = #0.0 + \override StaffSpacing #'stem-spacing-correction = #0.0 + } + } +} diff --git a/lily/staff-spacing.cc b/lily/staff-spacing.cc index 90e6882ea2..4aed2ddb2b 100644 --- a/lily/staff-spacing.cc +++ b/lily/staff-spacing.cc @@ -238,4 +238,4 @@ ADD_INTERFACE (Staff_spacing, "staff-spacing-interface", "This object calculates spacing details from a " " breakable symbol (left) to another object. For example, it takes care " " of optical spacing from a bar lines to a note.", - "stem-spacing-correction left-items right-items"); + "same-direction-correction stem-spacing-correction left-items right-items"); -- 2.39.2