0

I'm writing a score with Lilypond to simplify a complex score.

It is composed of a singe melodic line but has some mixed choir parts.

I wrote the lilypond code, but it shows a blank line #5-8 checked red.

How can I remove the blank line?

Also, I would like to remove two 6/8 marks in the #5.

Thanks in advance.

enter image description here

I don't know why the inserted image is not displayed. :-(

\version "2.24.3"

\layout {
  indent = 0
%  ragged-right = ##t
}

<<
{
\relative c' {
  \key g \major
  \time 6/8
  \numericTimeSignature
  \override Score.BarNumber.break-visibility = #end-of-line-invisible
  
  b'8 b b d4. | 
  b8 a g e4. | 
  d8 d16 d d d c'8 b a | 
  g4.~ g4 r8 |\break

<<
  \new Staff {
  \key g \major
  r4. a8 b c |
  r4. b16 b c8 d |
  cis4. e4 cis8 |
  d4.~ d4 r8 |\break
  }
  \addlyrics {
    ei- us- mod tem- por in- ci- di- dunt ut labore 
  }
  \new Staff {
  \clef bass
  \key g \major
  fis,,4 g8 a4. |
  g8 g a b4. |
  a8 a a cis4. |
  d4.~ d4 r8 |\break
  }
  \addlyrics {
    ei- us- mod tem- por in- ci- di- dunt ut lab- ore 
  }
>>

  d'4 d8 g4. |
  g8 fis e d4. |
  d8 d d16 d g8 b g |
  a4.~ a4 r8 | \break
  
  \bar "|."
}
}

\addlyrics {
 Lo- rem ip- sum dolor sit amet, con- sec- tetur ad- i- pis- cing elit, sed do 
 
 et dolore magna al- iqua. Ut enim ad min- im ven-iam, quis no- strud exer- ci- ta- tion 
 }
>>
2
  • You closed the code snippet with ' rather than backticks `. This meant that the reference to the image was part of you code snippet, and thus rendered as such.
    – Lazy
    Commented May 18 at 9:50
  • @Lazy Oops! Thank you!
    – P.-S. Park
    Commented May 18 at 13:14

1 Answer 1

3

The reason why you get this empty staff is because you are creating two new staves in an existing staff. So the empty staff you see is actually the original staff. You could solve this by not creating two new staves, but only one new staff:

\new Staff { ... << { ... } \new Staff { ... } >> }

But I think generally what you want to do here is a so called frenched score, i.e. a score where empty staves are removed. To achieve this do << \new Staff ... \new Staff ... >> instead and use

\layout {
  \context {
    \Staff
    \RemoveAllEmptyStaves
  }
}

to get rid of empty staves. So your example would look like this:

\version "2.24.3"

\layout {
  indent = 0
%  ragged-right = ##t
}

\layout {
  \context {
    \Staff
    \RemoveAllEmptyStaves
  }
}

<<
  \new Staff \relative c' {
    \key g \major
    \time 6/8
    \numericTimeSignature
    \override Score.BarNumber.break-visibility = #end-of-line-invisible
    
    b'8 b b d4. | 
    b8 a g e4. | 
    d8 d16 d d d c'8 b a | 
    g4.~ g4 r8 |\break
  
    r4. a8 b c |
    r4. b16 b c8 d |
    cis4. e4 cis8 |
    d4.~ d4 r8 |\break
  
    d4 d8 g4. |
    g8 fis e d4. |
    d8 d d16 d g8 b g |
    a4.~ a4 r8 | \break
    
    \fine
  }
  \addlyrics {
   Lo -- rem ip -- sum dolor sit amet, con -- sec -- tetur ad -- i -- pis -- cing elit, sed do 
   ei -- us -- mod tem -- por in -- ci -- di -- dunt ut labore 
   
   et dolore magna al -- iqua. Ut enim ad min -- im veniam, quis no -- strud exer -- ci -- ta -- tion 
  }
  \new Staff \relative c {
    \clef bass
    \key g \major
    R2.*4
    
    fis4 g8 a4. |
    g8 g a b4. |
    a8 a a cis4. |
    d4.~ d4 r8 |\break

    R2.*4
    \fine
  }
  \addlyrics {
    ei -- us -- mod tem -- por in -- ci -- di -- dunt ut lab -- ore 
  }
>>

(I’ve taken the liberty to replace your hyphenation by correct Lilypond syntax --).

1
  • Thank you for your answer and editing! I didn't know the command \RemoveAllEmptyStaves. It works well.
    – P.-S. Park
    Commented May 18 at 13:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.