lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Acciaccatura distoring spacing


From: Stefano Troncaro
Subject: Re: Acciaccatura distoring spacing
Date: Sun, 26 May 2019 14:20:14 -0300

Hi David,

Look at this:

%%%%%%%%%%%%%%%%%%%%%
\version "2.19.82"
\language "english"
#(set-global-staff-size 16)

strictGraceTrue = {
  \newSpacingSection
  \override Score.SpacingSpanner.strict-grace-spacing = ##t }

strictGraceFalse = {
  \newSpacingSection
  \override Score.SpacingSpanner.strict-grace-spacing = ##f }

\score {
  \new StaffGroup <<
    \new Staff { s4*5*2 }
    \new Staff \relative { \time 5/4
      r2
      \strictGraceTrue
      \tuplet 3/2 4 {r8 \acciaccatura a'' g-. \acciaccatura a g-.
     \once \hide TupletBracket
     \acciaccatura a g[-. r \acciaccatura a g]-.
     \acciaccatura a g-. \acciaccatura a g-. r} |
      \noBreak \strictGraceFalse
      \tuplet 3/2 4 {\once \hide TupletBracket \acciaccatura a g8-.
     \acciaccatura a g-. \acciaccatura a g-.
     r \acciaccatura a g-. \acciaccatura a g-.}
      \acciaccatura a g-.
      r r2 |
    }
    \new Staff \relative {
       r2 g''16-. g-. e'( c) g-. g-. e'( c) g-. g-. e'( c) |
       \grace s8 g=''16-. \strictGraceTrue g-. e'( c) r4 g16-. g-. e'( c)
       r8 e,16-. fs-. g-. a-. b-. c-. |
    }
  >>

%%%%%%%%%%%%%%%%%%%%%%%%%

I'm sorry I don't have time to write a full explanation, or more tests now, but I think the problem lies with the fact that the bar starts with an acciacatura in one Voice, but there is a bar check and no acciacatura in the other Voice. Writing an acciacatura with a spacer rest in the voice that has no printed grace note solves the issue. To avoid having the grace (that occupies no time with the strict-grace-spacing set to #t) collide with the barline, I changed spacing sections.

Hope this helps,
Stéfano

El dom., 26 may. 2019 a las 13:29, David Sumbler (<address@hidden>) escribió:
Armed with this method of correcting the spacing when acciaccature occur in conflicting rhythms, I tried applying it to some other passages which had similar but less noticeable spacing problems.

But there is a difficulty, which I mentioned before: if a barline occurs within a system, the barline is often printed in completely the wrong place, passing through noteheads etc. The error is always in shifting the barline to the right by a couple of inches or so.

Yet everything else about the output appears fine: the line end comes in the correct place (complete with barline), and the spacing is as required.

I blamed polymark when I reported this problem before. But now I find that, although I thought that disabling polymark had solved the problem, in other places the wrongly-placed barline occurs even when polymark is not included in the files.

The following pared down version of a couple of bars illustrates the problem.  It compiles correctly as it stands. But if the commented line is removed, then on my system, at least, the barline which should be placed after 5 crotchets, actually appears almost at the end of the line, after 9.25 crotchets.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\version "2.19.82"
\language "english"
#(set-global-staff-size 16)

\score {
  \new StaffGroup <<
%    { \new Staff s4*5*2 }
    { \new Staff \time 5/4 \relative {
      r2
      \newSpacingSection
      \override Score.SpacingSpanner.strict-grace-spacing = ##t
      \tuplet 3/2 4 {r8 \acciaccatura a'' g-. \acciaccatura a g-.
     \once \hide TupletBracket
     \acciaccatura a g[-. r \acciaccatura a g]-.
     \acciaccatura a g-. \acciaccatura a g-. r} |
      \noBreak
      \tuplet 3/2 4 {\once \hide TupletBracket \acciaccatura a g8-.
     \acciaccatura a g-. \acciaccatura a g-.
     r \acciaccatura a g-. \acciaccatura a g-.}
      \acciaccatura a g-.
      r r2 |
    } }
    { \new Staff \relative {
       r2 g''16-. g-. e'( c) g-. g-. e'( c) g-. g-. e'( c) |
       \tweak extra-spacing-width #'(-3 . 0) g=''16-. g-. e'( c) r4 g16-. g-. e'( c)
       r8 e,16-. fs-. g-. a-. b-. c-. |
    } }
  >>
}  
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

If the spacer rests are replaced by normal rests, the problem goes away. But whole bar rests cause the problem to reappear, Even if the stave is not actually displayed (because \with \RemoveAllEmptyStaves has been added), the problem persists.

This surely is a bug. Whether it is or not, it is causing me a lot of difficulty, because I have a part for narrator which uses a dummy stave to add the narrator's words as Marks. If I replace the dummy rests with normal rests in this stave (which has \RemoveAllEmptyStaves) the stave reappears on any line where the narrator has to speak, although I don't understand why it does this: after all, the stave is still "empty", and the RehearsalMark is in the Score context.

Can anyone explain this odd behaviour?

David

On Tue, 2019-05-21 at 01:30 -0300, Stefano Troncaro wrote:
Oh I see, troubleshooting in big projects like what you describe can be so painful.

Hopefully you figure out specifically what in your poly-mark-engraver.ily is conflicting with overriding the SpacingSpanner. Perhaps if you manage to isolate the problem and make a short example showing the bizarre results you described someone in this list will be able to figure out what is happening and how to fix the poly-mark-engraver.

Anyways, I'm happy you solved it!

El lun., 20 may. 2019 a las 18:01, David Sumbler (<address@hidden>) escribió:
Hi Stefano,

I have now re-read the Horizontal Spacing section, and I am a bit wiser
than I was.

When I tried it, the fix you suggested worked perfectly for the snippet
in my email.  But I had great difficulty when I applied it to my actual
score: I kept getting numerous warnings:

        programming error: Cannot determine neighbors for floating column.
        continuing, cross fingers

Also, depending where I began/ended the strict-grace-spacing, I
sometimes had really bizarre results with a barline in completely the
wrong place and actually passing through noteheads!

After about 2 hours trying to isolate the cause, I found that it was
due to the fact that my default include file itself includes poly-mark-
engraver-ily.  I disabled this, and then recompiled the whole score
(all 150 pages of it).  To my great relief I found that there were no
problems: clearly I have not actually used the poly-mark facility in
this score.

Thank you very much for your help on this.

David


On Mon, 2019-05-20 at 12:45 -0300, Stefano Troncaro wrote:
> Hi David,
> Ttake a look a this snippet:
> \version "2.19.82"
> \paper { line-width = 65\mm }
> <<
>   {
>     \new Staff \time 2/4
>     \newSpacingSection
>     \override Score.SpacingSpanner.strict-grace-spacing = ##t
>     \tuplet 7/4 { g'16 a' b' c'' d'' e'' f'' } g''8 r
>   }
>   {
>     \new Staff
>     \tuplet 3/2 4 { g''8 \acciaccatura a'' g'' g'' } g'' r
>   }
> >>
> Does this fix it for you? If it does, I encourage you to read the
> chapter on horizontal spacing of the Notation Reference, and then
> also look at the SpacingSpanner properties and interfaces in the
> Internals Reference.
> Hope that helps!
> Stéfano




reply via email to

[Prev in Thread] Current Thread [Next in Thread]