0

I need several analysis bracket combinations which are rather unusual (at least I didn't find a lot help in the net). First of all I wanted overlapping analysis brackets, which I managed to achieve already. Now, what I also need is "adjacent brackets", meaning that one bracket ends on a note while on the same note another one starts. So in theory I would need this: "g4\stopGroup\startGroup". However, this results in simply one big bracket. Here is my example code, which currently has the problem that the g4 is in both voices and therefore visible twice, while it should only be there once, but both brackets should include it.

\version "2.19.61"

adjtwo = \relative c'' {
    s2 g4\startGroup a b c\stopGroup d e
}

adjone = \relative c' {
    \once \override HorizontalBracket #'direction = #UP
    e\startGroup f g\stopGroup
}

\score {
  \new Staff {
    <<
      \voiceOne \adjone
      \voiceThree \adjtwo
    >>
  }
}

\layout {
  \context {
    \Voice
    \consists "Horizontal_bracket_engraver"
  }
}

Thanks for any help Best regards

acensored
  • 87
  • 5

2 Answers2

0

Is this what you're looking for?

\version "2.19.61"

\score {
  \relative {
    \override HorizontalBracket #'direction = #UP
    e'\startGroup f g\stopGroup <>\startGroup a
    b c\stopGroup d e
  }
}

\layout {
  \context {
    \Voice
    \consists "Horizontal_bracket_engraver"
  }
}
ksnortum
  • 2,809
  • 4
  • 27
  • 36
  • Thanks for your comment but no this is not what I want because the second bracket starts at the a while I want it to start at g (where the first one stops) – acensored Aug 09 '17 at 16:33
0

A work around to make this, is the following:

  1. put \starGroup and \stopGroup where you need. The unique condition is that you can not put a \stopGroup following a \startGroup. You have to put at least 1 note among their. You can put the \stopGroup after the following note, don't worry
  2. fix the position and length of the bracket that are wrong drawn with \once \override HorizontalBracket.shorten-pair = #'(-3.0 . 1.5).

For your example, you can do the following:

adjone = \relative c' {
  \once \override HorizontalBracket #'direction = #UP
  e \startGroup f g \stopGroup 
  \once \override HorizontalBracket.shorten-pair = #'(-3.0 . 1.5)
  a \startGroup b c \stopGroup d e
}


\score {
  \new Staff {
    <<
      \voiceOne \adjone
    >>
  }
}

\layout {
  \context {
    \Voice
    \consists "Horizontal_bracket_engraver"
  }
}

And you get this score:

(I can not put images embed yet) Here is the link of the image: https://i.stack.imgur.com/ZxXAc.jpg