lilypond-devel
[Top][All Lists]
Advanced

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

Re: repeating bar numbers and rehearsal marks in frenched score


From: tisimst
Subject: Re: repeating bar numbers and rehearsal marks in frenched score
Date: Thu, 28 Jul 2016 13:08:34 -0700 (MST)

Mark, et al,

On Thu, Jul 28, 2016 at 1:36 PM, Mark Knoop-4 [via Lilypond] <
address@hidden> wrote:

> At 21:03 on 28 Jul 2016, David Kastrup wrote:
>
> >Mark Knoop <[hidden email]
> <http:///user/SendEmail.jtp?type=node&node=193214&i=0>> writes:
> >> I'm also unclear as to why you feel that this is unsuitable to be
> >> done by the Keep_alive_together_engraver without further nesting.
> >> After all, the documentation for this engraver states:
> >>
> >>     These spanners are then tied together so that one will be removed
> >>     only if all are removed.
> >
> >Your use case desired to have staves removed without consideration of
> >whether the mark line is removed, and have the mark line removed only
> >if all staves are removed.
>
> How is this so conceptually dissimilar to the divisi-staves situation
> which introduced the remove-layer property?
>
> Staves are already removeable without consideration of other contexts
> by setting remove-layer = ##f. The only change is that a specified
> context can be retained throughout the normal life of the group.
>
> I'm sorry, I am trying to progress this and respond to your
> suggestions, but it would be nice to receive some proper criticism of
> my (working) code which amounts to more than just "I don't like it".
>

Forgive me if this is the wrong place to ask this question, but can the new
code handle nested situations?

For example, let's say we have four horns. These may appear on their own
staff, they may appear on a combined staff (e.g., "Horns 1 & 2"), and they
may appear on a single staff together. The divisi-staves example works
wonderfully for a single parent-child situation, but using the
'keepAliveInterfaces as the trigger doesn't seem to allow you to have more
nested levels. Here's a complete compiling example. I tried to extend the
divisi-staves code to allow for this multi-level nesting, but all
permutations failed for me. Here's one example:

%%%%%%%%%

\version "2.19.13"

\header {
  texidoc = "The @code{VerticalAxisGroup.remove-layer}
property can be used for typesetting temporary divisi staves where
the switch to split staves is done only at line breaks such that all
complex passages are rendered in separate staves."
}

boring = \set Staff.keepAliveInterfaces = #'()
tricky = \unset Staff.keepAliveInterfaces

violI=\relative c'' {
  \boring \repeat unfold 50 c4
  \tricky <c g'>2
  \boring \repeat unfold 48 c4
  \tricky <c g'>2
  \boring \repeat unfold 98 c4
  \bar "|."
}

violII=\relative g' {
  \boring \repeat unfold 100 g4
  \tricky <g d'>2
  \boring \repeat unfold 98 g4
  \bar "|."
}

violIII=\relative e' {
  \boring \repeat unfold 100 e4
  \tricky <e b'>2
  \boring \repeat unfold 48 e4
  \tricky <e b'>2
  \boring \repeat unfold 48 e4
  \bar "|."
}

violIV=\relative c' {
  \boring \repeat unfold 100 c4
  \tricky <c g'>2
  \boring \repeat unfold 98 c4
  \bar "|."
}

\score {
  \new StaffGroup \with {
    \consists "Keep_alive_together_engraver"
  } <<
    \new StaffGroup \with {
      \consists "Keep_alive_together_engraver"
      \override VerticalAxisGroup.remove-layer = 1
      \remove System_start_delimiter_engraver
    } <<
        \new Staff \with {
          instrumentName = "Violin I"
          shortInstrumentName = "V I"
          \override VerticalAxisGroup.remove-empty = ##t
          \override VerticalAxisGroup.remove-first = ##t
          \override VerticalAxisGroup.remove-layer = 1
        } \violI
        \new Staff \with {
          instrumentName = "Violin II"
          shortInstrumentName = "V II"
          \override VerticalAxisGroup.remove-empty = ##t
          \override VerticalAxisGroup.remove-first = ##t
          \override VerticalAxisGroup.remove-layer = 1
        } \violII
        \new Staff \with {
          instrumentName = "Violins I&II"
          shortInstrumentName = "V I&II"
          \override VerticalAxisGroup.remove-layer = 2
        } << \violI \\ \violII  >>
    >>
    \new StaffGroup \with {
      \consists "Keep_alive_together_engraver"
      \override VerticalAxisGroup.remove-layer = 1
      \remove System_start_delimiter_engraver
    } <<
        \new Staff \with {
          instrumentName = "Violin III"
          shortInstrumentName = "V III"
          \override VerticalAxisGroup.remove-empty = ##t
          \override VerticalAxisGroup.remove-first = ##t
          \override VerticalAxisGroup.remove-layer = 1
        } \violIII
        \new Staff \with {
          instrumentName = "Violin IV"
          shortInstrumentName = "V IV"
          \override VerticalAxisGroup.remove-empty = ##t
          \override VerticalAxisGroup.remove-first = ##t
          \override VerticalAxisGroup.remove-layer = 1
        } \violIV
        \new Staff \with {
          instrumentName = "Violins III&IV"
          shortInstrumentName = "V III&IV"
          \override VerticalAxisGroup.remove-layer = 2
        } << \violIII \\ \violIV  >>
    >>
    \new Staff \with {
      instrumentName = "Violins"
      shortInstrumentName = "V I-IV"
      \override VerticalAxisGroup.remove-layer = 2
    } << \violI \\ \violII \\ \violIII \\ \violIV >>
  >>
  \layout {
    short-indent = 2\cm
    indent = 3\cm
  }
}

%%%%%%%%%

Here are some other scenarios I tried, but failed with:
1. A single StaffGroup contains seven Staff contexts: four individuals, two
paired staves, and one combined staff. Each individual Staff had a
'remove-layer value of 1, each paired Staff had a 'remove-layer value of 2
and the combined Staff had a 'remove-layer value of 3. This seems like the
ideal situation since it has the simplest structure.
2. Adding/removing \RemoveAllEmptyStaves to the paired Staff and StaffGroups
3. Adding/removing \consists "Keep_alive_together_engraver" to the paired
StaffGroups

No matter what I tried, I would either get the individual staves and the
combined staff or I'd get the paired staves and the combined staff or the
individual staves and the paired staves, but never all three. My guess is
that nesting makes things much more complicated because of the increase in
pair multiplicity. Looking at the VerticalAxisGroup properties, I see the
'keep-alive-with and 'make-dead-with properties, which seem like they could
do the trick, but I haven't a clue how to get the Staff grobs so I can set
them. Ideally, the nesting might appear like this (using those properties):

(Top-most combined staff): Staff.make-dead-with = #'(pair-one-staff
pair-two-staff)
(Middle paired staff): Staff.make-dead-with = #'(individual-one-staff
indvidual-two-staff)
(Bottom individual staff): Staff.keep-alive-with = #'(individual-two-staff)

where pair-one-staff, pair-two-staff, indvidual-one-staff, and
individual-two-staff are the grob variables of those Staff contexts. But
how to get them and make those connections? Or, am I misunderstanding how
these work?

Thanks for hearing me out and thanks for all you both do!

Best,
Abraham




--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/repeating-bar-numbers-and-rehearsal-marks-in-frenched-score-tp193171p193215.html
Sent from the Dev mailing list archive at Nabble.com.


reply via email to

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