john ware
john ware

Reputation: 163

Lilypond repeat symbol vanishes next line uses: \bar ".|"

I am creating a chord chart where the first 8 bars are repeated using \repeat volta 2 {}; no problem. I use \bar ".|" to force bar lines on the left side. Not conventional, but, that's what I want.

The next line starts with the above mentioned \bar ".|". That adds the next line correctly, however, the repeat symbol at the end of the repeat section is not rendered.

Here's my snippet:

\version "2.18.2"

\score {

  \chordmode {

    \repeat volta 2 {
       \bar ".|" c1 | c | 
       \break
       \bar ".|" d1 | d | 
      \break
     }

    % uncomment one of the following two lines only
    %This first one adds a new line correctly, but the bar line is wrong.
    \bar "|" c1 |

    %This one add a new line, but the above repeat section has no ending repeat symbol 
    %\bar ".|" c1 | 
}

} 

Upvotes: 3

Views: 247

Answers (1)

fedelibre
fedelibre

Reputation: 418

You hit a known problem: see Issue #3688 Manual barlines overwrite repeat barlines.

Anyway, your snippet will compile fine as long as you avoid manual bars (you need it only in the first measure) and use \repeat commands instead for each repetition. Also, you probably want to use \bar ".|:, as explained in the documentation.

\version "2.18.2"

\score {
  \chordmode {
    \repeat volta 2 {
      \bar ".|:"
      c1 | c |
      \break
    }
    \repeat volta 2 {
      d1 | d |
      \break
    }
    c1 d |
  }
}

Upvotes: 2

Related Questions