lilypond-user
[Top][All Lists]
Advanced

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

Re: Are these brackets alongside a staff group possible?


From: Aaron Hill
Subject: Re: Are these brackets alongside a staff group possible?
Date: Thu, 04 Jul 2019 10:57:49 -0700
User-agent: Roundcube Webmail/1.3.8

On 2019-07-04 10:01 am, Pierre Perol-Schneider wrote:
Hi Ben,
How about:

Here are some modifications I made to Pierre's code:

- Removed \overriding InstrumentName.padding and opted instead for self-alignment-X of RIGHT. - Kept the stencil for SystemStartSquare but applied an extra-offset to slide it underneath the instrument name for the StaffGroup. - To prevent the other brackets from being shifted, I also had to adjust SystemStartSquare's direction to RIGHT.
- Changed InstrumentName's layer to be top-most.
- Used the OrchestraGroup's instrumentName with \markup \whiteout...


%%%%
\version "2.19.82"

%%%%% Example:
someMusic = {
  \tempo "Andante."
  \time 3/4
  \key c \minor
  c'2. r8
}

\paper { indent = 40 }

\layout {
  \context {
    \Staff
    \override InstrumentName.font-size = #-1
    \override InstrumentName.self-alignment-X = #RIGHT
  }
  \context {
    \StaffGroup
    \name ViolinGroup
    \alias StaffGroup
    systemStartDelimiter = #'SystemStartBrace
  }
  \context {
    \StaffGroup
    \name WindGroup
    \alias StaffGroup
    systemStartDelimiter = #'SystemStartBracket
    \override SystemStartBracket.collapse-height = #1
  }
  \context {
    \StaffGroup
    \name StringGroup
    \alias StaffGroup
    \accepts ViolinGroup
    systemStartDelimiter = #'SystemStartBracket
  }
  \context {
    \StaffGroup
    \name OrchestraGroup
    \accepts WindGroup
    \accepts StringGroup
    systemStartDelimiter = #'SystemStartSquare
    \override SystemStartSquare.thickness = #2
    \override SystemStartSquare.direction = #RIGHT
    \override SystemStartSquare.extra-offset = #'(-15.5 . 0)
    \override InstrumentName.layer = #1000
  }
  \context {
    \GrandStaff
    \remove "System_start_delimiter_engraver"
    \accepts OrchestraGroup
    \accepts StaffGroup
  }
}

\score {
  \new GrandStaff <<
    \new OrchestraGroup \with {
        instrumentName = \markup \whiteout
          \override #'(circle-padding . 1)
          \circle "I"
      } <<
      \new WindGroup <<
        \new Staff \with {
          instrumentName = "Oboe"
        } \someMusic
      >>
      \new StringGroup <<
        \new ViolinGroup <<
          \new Staff \with {
            instrumentName = "Violino I"
          } \someMusic
          \new Staff \with {
            instrumentName = "Violino II"
          } \someMusic
        >>
        \new Staff \with {
            instrumentName = "Viola"
          } { \clef C \someMusic }
      >>
    >>
    \new StaffGroup <<
      \new Staff \with {
      instrumentName = "Soprano"
      } \someMusic
      \new Staff \with {
      instrumentName = "Alto"
      } { \clef C \someMusic }
    >>
  >>
}
%%%%


-- Aaron Hill

Attachment: custom-start-bar.cropped.png
Description: PNG image


reply via email to

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