Re: Bloody mao! Valentin, you tricked us!

2012-04-03 Thread Valentin Villenave
On Tue, Apr 3, 2012 at 1:59 AM, PMA peterarmstr...@aya.yale.edu wrote:
 Indeed, Valentin!  Our chiwawa JSB lives for that
 report and, seeing your joke, nearly had kittens.

Thanks -- but this has to be the weirdest compliment no one has ever
made to me. (Or is it a compliment? 0_o)

Cheers,
Valentin.

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Score layout in a separate file

2012-04-03 Thread Siska Ádám
Dear List,


is there a way to put the layout block for a score in a variable that lives in 
a separate file? Unfortunately the following won't compile:



myMusic = \relative d' {
  d4 d d d
}

myLayout = \layout {
   \context {
\Staff
\remove Clef_engraver
  }
}

\score {
  \myMusic
  \myLayout
}



I tried several other ways to export the content of the layout block, but none 
of them succeeded. I'm writing parts of an orchestral piece and I'd like to 
include the layout definition for these scores in a separate file.


Thanks for any help,
Ádám


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Bloody mao! Valentin, you tricked us!

2012-04-03 Thread PMA

Re: complement? --

This would depend on Why he'd have had kittens,
and that in turn on whether he'd 'gotten' the joke.
We couldn't tell whether he was amused or, you
know, merely devastated.

P

Valentin Villenave wrote:

On Tue, Apr 3, 2012 at 1:59 AM, PMApeterarmstr...@aya.yale.edu  wrote:

Indeed, Valentin!  Our chiwawa JSB lives for that
report and, seeing your joke, nearly had kittens.


Thanks -- but this has to be the weirdest compliment no one has ever
made to me. (Or is it a compliment? 0_o)

Cheers,
Valentin.


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Score layout in a separate file

2012-04-03 Thread Thomas Morley
Am 3. April 2012 15:17 schrieb Siska Ádám sa...@sadam.hu:
 Dear List,


 is there a way to put the layout block for a score in a variable that lives 
 in a separate file? Unfortunately the following won't compile:

 

 myMusic = \relative d' {
  d4 d d d
 }

 myLayout = \layout {
   \context {
    \Staff
    \remove Clef_engraver
  }
 }

 \score {
  \myMusic
  \myLayout
 }

 

 I tried several other ways to export the content of the layout block, but 
 none of them succeeded. I'm writing parts of an orchestral piece and I'd like 
 to include the layout definition for these scores in a separate file.


 Thanks for any help,
 Ádám

Hi,

try:

\layout { \myLayout }

Cheers,
  Harm

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Score layout in a separate file

2012-04-03 Thread Tim McNamara
On Apr 3, 2012, at 8:17 AM, Siska Ádám wrote:
 
 is there a way to put the layout block for a score in a variable that lives 
 in a separate file? Unfortunately the following won't compile:

have you tried using \include?
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Score layout in a separate file

2012-04-03 Thread Siska Ádám

On 2012.04.03., at 15:46, Thomas Morley wrote:

 Am 3. April 2012 15:17 schrieb Siska Ádám sa...@sadam.hu:
 Dear List,
 
 
 is there a way to put the layout block for a score in a variable that lives 
 in a separate file? Unfortunately the following won't compile:
 
 
 
 myMusic = \relative d' {
  d4 d d d
 }
 
 myLayout = \layout {
   \context {
\Staff
\remove Clef_engraver
  }
 }
 
 \score {
  \myMusic
  \myLayout
 }
 
 
 
 I tried several other ways to export the content of the layout block, but 
 none of them succeeded. I'm writing parts of an orchestral piece and I'd 
 like to include the layout definition for these scores in a separate file.
 
 
 Thanks for any help,
 Ádám
 
 Hi,
 
 try:
 
 \layout { \myLayout }
 
 Cheers,
  Harm

Hi,


thanks a lot, this works! Out of curiosity, could you or somebody on the list 
explain to me why this works? It is a bit weird to me, as I also tried to have 
the variable without the \layout in it (so that it was myLayout = \context { 
etc. } and then I used \layout { \myLayout } ), but that didn't work either. 
I'm just surprised that this solution (which reads at the end \layout { \layout 
{ etc. } } ) will compile...


Thank you,
Ádám


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: lilypond no longer creates .log files

2012-04-03 Thread -Eluze


esperanto wrote:
 
 When I compile in using windows I see the .log file generated, but it does
 not remain after the .pdf is created.
 
 If I compile in command prompt I can scroll to read the output, but no
 .log file is generated.
 
 I have uninstalled and installed again.
 
 I'm running \version 2.14.2 in Windows 7.
 
can you please be more concrete about using windows and what command you
use  in the command prompt?

thanks
Eluze
-- 
View this message in context: 
http://old.nabble.com/lilypond-no-longer-creates-.log-files-tp33545031p33545040.html
Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com.


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


lilypond no longer creates .log files

2012-04-03 Thread esperanto

When I compile in using windows I see the .log file generated, but it does
not remain after the .pdf is created.

If I compile in command prompt I can scroll to read the output, but no .log
file is generated.

I have uninstalled and installed again.

I'm running \version 2.14.2 in Windows 7.
-- 
View this message in context: 
http://old.nabble.com/lilypond-no-longer-creates-.log-files-tp33545031p33545031.html
Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com.


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


change the size of the arpeggio arrows

2012-04-03 Thread Paolo Prete
Hello,

how can I change the size of the arpeggio (up and down) arrows? 
The default size is really small

thanks!

Paolo

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Pitch with null duration?

2012-04-03 Thread Dossy Shiobara
I know how to make a pitch transparent (e.g., \override Rest
#'transparent = ##t) but is there a way to specify a pitch with a null
duration (e.g., like g0 or somesuch)?

The behavior I'm looking for is to start out a measure with a slur to
the first note, as this is a continuation of a previous measure from a
note that is slurred to the note that I'm interested in, that I am *not*
including in my LilyPond document.

The behavior of this null duration pitch would be very similar to the
transparent pitch above, except:

1) It has no horizontal spacing.

2) It has no duration, thus doesn't generate annoying barcheck warnings,
or otherwise screw up matching notes to lyrics, etc.

If I haven't adequately explained myself, please ask questions and I
will try to provide a better explanation and examples.  If this is in
the documentation, I couldn't find it; I'm sorry.

Thanks,

Dossy

-- 
Dossy Shiobara |  He realized the fastest way to change
do...@panoptic.com |   is to laugh at your own folly -- then you
http://panoptic.com/   |   can let go and quickly move on. (p. 70) 
  * WordPress * jQuery * MySQL * Security * Business Continuity *


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


gonville music font results in different text fonts on Linux and Mac

2012-04-03 Thread Klaus Föhl
Hello,

I've experimentally changed my lilypond installations from feta to gonville,
and while the music grobs are changed in both cases
I find that on Linux debian squeeze 2.12.3 the text font remains
New Century Schoolbook, while on Mac OS X 2.14.2 the text font is changed
to a sans-serif/grotesk version for the entire document.

Both times I unzipped gonville-r9313.zip on the relevant machine
and renamed (mv) the existing fonts to a different name and instead
put (mv or cp -pr) the lilyfonts directory / folder as fonts in place.

The sections on the fonts look the same in 2.12.3 and 2.14.2 documentation.
Is it down to the different OS (Mac vs Linux) which makes for the difference
in the chosen text font? Is it to do with different fonts installed?
Why does the Mac change to some sans-serif (and which one this is?)
and Linux does not?

Best regards

Klaus

P.S. already used  lilypond -dshow-available-fonts x


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Score layout in a separate file

2012-04-03 Thread Choan Gálvez

On 4/3/12 15:17 , Siska Ádám wrote:

Dear List,


is there a way to put the layout block for a score in a variable that
lives in a separate file? Unfortunately the following won't compile:



myMusic = \relative d' { d4 d d d }

myLayout = \layout { \context { \Staff \remove Clef_engraver } }

\score { \myMusic \myLayout }



I tried several other ways to export the content of the layout block,
but none of them succeeded. I'm writing parts of an orchestral piece
and I'd like to include the layout definition for these scores in a
separate file.


You must put the variable call inside a \layout block:

\score {
  \myMusic
  \layout {
\myLayout
  }
}

will work fine.

Best.
--
Choan Gálvez

Ukecosas. Los ukeleles que nos gustan, también para ti
Visítanos: http://ukecosas.es/
Degústanos en Facebook: http://facebook.com/ukecosas

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Lost .log files

2012-04-03 Thread Peter Wannemacher
When I compile in using windows I see the .log file generated, but it does
not remain after the .pdf is created. 
If I compile in command prompt I can scroll to read the output, but no .log
file is generated. 
I have uninstalled and installed again. 



I'm running \version 2.14.2 in Windows 7.

 

Thank you --  Peter

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Score layout in a separate file

2012-04-03 Thread David Kastrup
Siska Ádám sa...@sadam.hu writes:

 On 2012.04.03., at 15:46, Thomas Morley wrote:

 Am 3. April 2012 15:17 schrieb Siska Ádám sa...@sadam.hu:
 Dear List,
 
 
 is there a way to put the layout block for a score in a variable that lives 
 in a separate file? Unfortunately the following won't compile:
 
 
 
 myMusic = \relative d' {
  d4 d d d
 }
 
 myLayout = \layout {
   \context {
\Staff
\remove Clef_engraver
  }
 }
 
 \score {
  \myMusic
  \myLayout
 }
 
 
 try:
 
 \layout { \myLayout }

 thanks a lot, this works! Out of curiosity, could you or somebody on
 the list explain to me why this works?

The LilyPond grammar in the appendices of the NR will show what to use
here.

 It is a bit weird to me, as I also tried to have the variable without
 the \layout in it (so that it was myLayout = \context { etc. } and
 then I used \layout { \myLayout } ), but that didn't work either. I'm
 just surprised that this solution (which reads at the end \layout {
 \layout { etc. } } ) will compile...

Variables in LilyPond are not textual entities but Scheme expressions.
Some keywords like \layout throw LilyPond into a mode, like one suitable
for creating output definitions, or drum parts or whatever.  And to
interpret such a variable, you sometimes need to be in the right mode
already (because the information _what_ kind of output definition is in
the variable created by \layout is not there).  Basically, when putting
stuff into a variable and reusing the result, you are safer off if you
consult the grammar when things go wrong.

-- 
David Kastrup


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Pitch with null duration?

2012-04-03 Thread Eluze

you can try something like

{
  \hideNotes
  \grace g''(
  \unHideNotes a1)
}

hth
Eluze

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Pitch with null duration?

2012-04-03 Thread Thomas Morley
Am 4. April 2012 00:56 schrieb Eluze elu...@gmail.com:
 you can try something like

 {
  \hideNotes
  \grace g''(
  \unHideNotes a1)
 }

 hth
 Eluze

Or perhaps:

\version 2.14.2

\relative c' {
d'4\repeatTie
}

and tweak the Tie, if necessary.

HTH,
  Harm

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: change the size of the arpeggio arrows

2012-04-03 Thread Janek Warchoł
On Tue, Apr 3, 2012 at 12:24 AM, Paolo Prete p4olo_pr...@yahoo.it wrote:
 Hello,

 how can I change the size of the arpeggio (up and down) arrows?
 The default size is really small

I think it may be impossible (i.e. if you increase it's font-size, the
size of the arpeggio zigzag will also increase).
I agree that the arrow should be bigger.  Long time ago i wrote a
draft patch that addresses this, but i'm too busy now to do something
about it.  Maybe you'd like to handle it (files attached)?

cheers,
Janek


0001-font-widening-the-arpeggio-arrow.patch
Description: Binary data


0002-more-fiddling.patch
Description: Binary data
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


upbow above fermata?

2012-04-03 Thread Mark Mathias
Putting an upbow above a fermata seems right to me, but the program
automatically puts the fermata on top. I've read the manuals until I'm blue
in the face, experimented numerous times, and still can't figure out how to
change it. Help will be greatly appreciated.

\relative c' { f2\fermata\upbow }

Thanks!
Mark
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: upbow above fermata?

2012-04-03 Thread Kieren MacMillan
Hi Mark,

\version 2.15.32

\relative c'
{
  f2 \fermata \upbow
  f2 -\tweak #'outside-staff-priority #100 -\fermata -\tweak 
#'outside-staff-priority #1000 -\upbow
}

 I've read the manuals until I'm blue in the face

http://lilypond.org/doc/v2.12/Documentation/user/lilypond-learning/Placement-of-objects#Placement-of-objects
http://lilypond.org/doc/v2.12/Documentation/user/lilypond-learning/Outside_002dstaff-objects#Outside_002dstaff-objects

What would have made these easier for you to find?

Best regards,
Kieren.
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: upbow above fermata?

2012-04-03 Thread Mark Mathias
Kieren,
Thank you! It wasn't that I couldn't find the material. In fact, I'd read
it several times, but (as is often the case for me with LilyPond) I still
have a lot to learn about how to assemble just the right pieces of
information in just the right order or syntax or grammar or whatever it is
that I still don't get so that it controls the output for me.
Best Wishes,
Mark

On Tue, Apr 3, 2012 at 11:07 PM, Kieren MacMillan 
kieren_macmil...@sympatico.ca wrote:

 Hi Mark,

 \version 2.15.32

 \relative c'
 {
  f2 \fermata \upbow
   f2 -\tweak #'outside-staff-priority #100 -\fermata -\tweak
 #'outside-staff-priority #1000 -\upbow
 }

  I've read the manuals until I'm blue in the face

 
 http://lilypond.org/doc/v2.12/Documentation/user/lilypond-learning/Placement-of-objects#Placement-of-objects
 
 
 http://lilypond.org/doc/v2.12/Documentation/user/lilypond-learning/Outside_002dstaff-objects#Outside_002dstaff-objects
 

 What would have made these easier for you to find?

 Best regards,
 Kieren.
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: partcombine - whole note : slash on grace note

2012-04-03 Thread Mark Mathias
(1) Try altering your TBk variable to not include the tied whole note, then
add the whole note to one Voice and add a space instead of a whole note to
the other Voice.
(2) Someone else will have to help you with your second question.
May I suggest that you carve your sample down to a Very Tiny Example? It
will make it easier for someone to help you.
Best Wishes,
Mark

On Tue, Apr 3, 2012 at 11:50 PM, MING TSANG tsan...@rogers.com wrote:

 Two questions:
 (1) how can I have partcombine works on whole note - refer to bar #6 of
 png file?
 (2) how can I have slash on the grace notes beam - refer to piano RH - bar
 #4?

 Appreciate the help.

 snippet
 \version 2.14.2
 \include english.ly
 #(define (rest-score r)
  (let ((score 0)
  (yoff (ly:grob-property-data r 'Y-offset))
  (sp (ly:grob-property-data r 'staff-position)))
  (if (number? yoff)
  (set! score (+ score 2))
  (if (eq? yoff 'calculation-in-progress)
  (set! score (- score 3
  (and (number? sp)
  (= 0 2 sp)
  (set! score (+ score 2))
  (set! score (- score (abs (- 1 sp)
  score))
 #(define (merge-rests-on-positioning grob)
  (let* ((can-merge #f)
  (elts (ly:grob-object grob 'elements))
  (num-elts (and (ly:grob-array? elts)
  (ly:grob-array-length elts)))
  (two-voice? (= num-elts 2)))
  (if two-voice?
  (let* ((v1-grob (ly:grob-array-ref elts 0))
  (v2-grob (ly:grob-array-ref elts 1))
  (v1-rest (ly:grob-object v1-grob 'rest))
  (v2-rest (ly:grob-object v2-grob 'rest)))
  (and
  (ly:grob? v1-rest)
  (ly:grob? v2-rest)
  (let* ((v1-duration-log (ly:grob-property v1-rest 'duration-log))
  (v2-duration-log (ly:grob-property v2-rest 'duration-log))
  (v1-dot (ly:grob-object v1-rest 'dot))
  (v2-dot (ly:grob-object v2-rest 'dot))
  (v1-dot-count (and (ly:grob? v1-dot)
  (ly:grob-property v1-dot 'dot-count -1)))
  (v2-dot-count (and (ly:grob? v2-dot)
  (ly:grob-property v2-dot 'dot-count -1
  (set! can-merge
  (and
  (number? v1-duration-log)
  (number? v2-duration-log)
  (= v1-duration-log v2-duration-log)
  (eq? v1-dot-count v2-dot-count)))
  (if can-merge
  ;; keep the rest that looks best:
  (let* ((keep-v1? (= (rest-score v1-rest)
  (rest-score v2-rest)))
  (rest-to-keep (if keep-v1? v1-rest v2-rest))
  (dot-to-kill (if keep-v1? v2-dot v1-dot)))
  ;; uncomment if you're curious of which rest was chosen:
  ;;(ly:grob-set-property! v1-rest 'color green)
  ;;(ly:grob-set-property! v2-rest 'color blue)
  (ly:grob-suicide! (if keep-v1? v2-rest v1-rest))
  (if (ly:grob? dot-to-kill)
  (ly:grob-suicide! dot-to-kill))
  (ly:grob-set-property! rest-to-keep 'direction 0)
  (ly:rest::y-offset-callback rest-to-keep)))
  (if can-merge
  #t
  (ly:rest-collision::calc-positioning-done grob
  global = {\key c\major \time 4/4 \tempo 4 = 63}
  TTj = \relative c {
 %{TT61-62%} ef2 r8. bf16 ef8 ef8 | ef4( c4 d8) d16 d16 b8 b8 |
 %{TT63 %} c2~ c2 |
  }
  BBj = \relative c {
 %{BB61-62%} bf2 r8. g16 g8 g8 | af2( g8) g16 g16 g8 g8 |
 %{BB63 %} c2( c2) |
  }
 %--
  TBk = \relative c {
 %{TB64 %} r2 r4 ef8 d16 ef(~ |
 %{TB65-66%} ef4~ ef16 f16) g8 f4. af8 | g1~ | g1
  }
 PianoRH = \relative c' { \global
 %{rh61 %} ef g bf4~ q8 g bf ef g16 af ef' af16 bf ef bf'8. ef16
 ef g bf ef8 d g bf d8
 %{rh62 %} c ef af c4 c,16 g16 af16 c16 f, a c d4 d' f d'8 d g d'8
 %{rh63 %} { g c ef4~ q4 af ef'2 }\\{ ef4~ ef8 ef16 r8 af,8 c~ g'8
 c f8 }
 %{rh64 %} { r8 bf''16 af16 ef16 df16 bf16 af16 ef8[ \grace{ bf16[ ef16]
 } bf8] ef, af ef'4 }\\{ f bf ef2. s4 }
 %{rh65 %} g bf ef2\stemUp af c f2
 %{rh66 %} g bf ef g2 c ef f af2 r1
 }

 %--
 PianoLH = \relative c { \global \clef bass
 %{lh61 %} { r16 bf16 ef16 f16 s2 r16 ef16 bf'8 }\\{ ef,,4 g'8 ef bf'
 ef16 f f'16 g bf ef g4 g,4 }
 %{lh62 %} { s4 af, af'4 g g'4 s4 }\\{ af' ef' c'4\arpeggio s2 g
 d' b'4\arpeggio }
 %{lh63 %} { r16 g16 c16 d16 ef16 g16 c8 f, c'2 }\\{c,2 r4 c'4 }
 %{lh64 %} df, af'2. cf gf'4_-
 %{lh65 %} { bf'2 bf2 }\\{ bf,4 bf4 bf4 bf4 }
 %{lh66 %} { bf'2 bf2 }\\{ bf,4 bf4 bf4 bf4 } r1
 }
 % SA_TB seperate + piano staff
 % {
 \score {
  \new GrandStaff = GrandStaff_score 
  \new ChoirStaff 
  \new Staff \with { \override RestCollision #'positioning-done =
 #merge-rests-on-positioning
  }
  \clef bass
  \global \partcombine
  \new Voice = Tenor {
  \voiceOne { \TTj \TBk }}
  \new Voice = Bass {
  \voiceTwo { \BBj \TBk }}
  
  
  \new PianoStaff 
  \set PianoStaff.connectArpeggios = ##t
  \new Staff = RH { \global \PianoRH }
  \new Staff = LH { \global \clef bass \PianoLH }
  
  
  \layout { indent = #'0
  \context { \RemoveEmptyStaffContext }
  \context {
  \Staff
  \override TimeSignature #'style = #'()
  }
  }
  \midi {
  \context { }
  \context { \Staff \remove Dynamic_performer }
  }
 }

 end

 Blessing in+,
 Ming.

 ___
 lilypond-user mailing list
 lilypond-user@gnu.org
 

Re: partcombine - whole note : slash on grace note

2012-04-03 Thread Mark Mathias
Sorry, meant to include this:
%{TB65-66%} ef4~ ef16 f16) g8 f4. af8 | %new TBk doesn't have the whole
note.
\new Voice = Tenor {
\voiceOne { \TTj \TBk g1~ | g1  } }
\new Voice = Bass {
\voiceTwo { \BBj \TBk s1~ | s1  } }



On Wed, Apr 4, 2012 at 1:29 AM, Mark Mathias d8val...@gmail.com wrote:

 (1) Try altering your TBk variable to not include the tied whole note,
 then add the whole note to one Voice and add a space instead of a whole
 note to the other Voice.
 (2) Someone else will have to help you with your second question.
 May I suggest that you carve your sample down to a Very Tiny Example? It
 will make it easier for someone to help you.
 Best Wishes,
 Mark

 On Tue, Apr 3, 2012 at 11:50 PM, MING TSANG tsan...@rogers.com wrote:

 Two questions:
 (1) how can I have partcombine works on whole note - refer to bar #6 of
 png file?
 (2) how can I have slash on the grace notes beam - refer to piano RH -
 bar #4?

 Appreciate the help.

 snippet
 \version 2.14.2
 \include english.ly
 #(define (rest-score r)
  (let ((score 0)
  (yoff (ly:grob-property-data r 'Y-offset))
  (sp (ly:grob-property-data r 'staff-position)))
  (if (number? yoff)
  (set! score (+ score 2))
  (if (eq? yoff 'calculation-in-progress)
  (set! score (- score 3
  (and (number? sp)
  (= 0 2 sp)
  (set! score (+ score 2))
  (set! score (- score (abs (- 1 sp)
  score))
 #(define (merge-rests-on-positioning grob)
  (let* ((can-merge #f)
  (elts (ly:grob-object grob 'elements))
  (num-elts (and (ly:grob-array? elts)
  (ly:grob-array-length elts)))
  (two-voice? (= num-elts 2)))
  (if two-voice?
  (let* ((v1-grob (ly:grob-array-ref elts 0))
  (v2-grob (ly:grob-array-ref elts 1))
  (v1-rest (ly:grob-object v1-grob 'rest))
  (v2-rest (ly:grob-object v2-grob 'rest)))
  (and
  (ly:grob? v1-rest)
  (ly:grob? v2-rest)
  (let* ((v1-duration-log (ly:grob-property v1-rest 'duration-log))
  (v2-duration-log (ly:grob-property v2-rest 'duration-log))
  (v1-dot (ly:grob-object v1-rest 'dot))
  (v2-dot (ly:grob-object v2-rest 'dot))
  (v1-dot-count (and (ly:grob? v1-dot)
  (ly:grob-property v1-dot 'dot-count -1)))
  (v2-dot-count (and (ly:grob? v2-dot)
  (ly:grob-property v2-dot 'dot-count -1
  (set! can-merge
  (and
  (number? v1-duration-log)
  (number? v2-duration-log)
  (= v1-duration-log v2-duration-log)
  (eq? v1-dot-count v2-dot-count)))
  (if can-merge
  ;; keep the rest that looks best:
  (let* ((keep-v1? (= (rest-score v1-rest)
  (rest-score v2-rest)))
  (rest-to-keep (if keep-v1? v1-rest v2-rest))
  (dot-to-kill (if keep-v1? v2-dot v1-dot)))
  ;; uncomment if you're curious of which rest was chosen:
  ;;(ly:grob-set-property! v1-rest 'color green)
  ;;(ly:grob-set-property! v2-rest 'color blue)
  (ly:grob-suicide! (if keep-v1? v2-rest v1-rest))
  (if (ly:grob? dot-to-kill)
  (ly:grob-suicide! dot-to-kill))
  (ly:grob-set-property! rest-to-keep 'direction 0)
  (ly:rest::y-offset-callback rest-to-keep)))
  (if can-merge
  #t
  (ly:rest-collision::calc-positioning-done grob
  global = {\key c\major \time 4/4 \tempo 4 = 63}
  TTj = \relative c {
 %{TT61-62%} ef2 r8. bf16 ef8 ef8 | ef4( c4 d8) d16 d16 b8 b8 |
 %{TT63 %} c2~ c2 |
  }
  BBj = \relative c {
 %{BB61-62%} bf2 r8. g16 g8 g8 | af2( g8) g16 g16 g8 g8 |
 %{BB63 %} c2( c2) |
  }
 %--
  TBk = \relative c {
 %{TB64 %} r2 r4 ef8 d16 ef(~ |
 %{TB65-66%} ef4~ ef16 f16) g8 f4. af8 | g1~ | g1
  }
 PianoRH = \relative c' { \global
 %{rh61 %} ef g bf4~ q8 g bf ef g16 af ef' af16 bf ef bf'8. ef16
 ef g bf ef8 d g bf d8
 %{rh62 %} c ef af c4 c,16 g16 af16 c16 f, a c d4 d' f d'8 d g d'8
 %{rh63 %} { g c ef4~ q4 af ef'2 }\\{ ef4~ ef8 ef16 r8 af,8 c~ g'8
 c f8 }
 %{rh64 %} { r8 bf''16 af16 ef16 df16 bf16 af16 ef8[ \grace{ bf16[ ef16]
 } bf8] ef, af ef'4 }\\{ f bf ef2. s4 }
 %{rh65 %} g bf ef2\stemUp af c f2
 %{rh66 %} g bf ef g2 c ef f af2 r1
 }

 %--
 PianoLH = \relative c { \global \clef bass
 %{lh61 %} { r16 bf16 ef16 f16 s2 r16 ef16 bf'8 }\\{ ef,,4 g'8 ef bf'
 ef16 f f'16 g bf ef g4 g,4 }
 %{lh62 %} { s4 af, af'4 g g'4 s4 }\\{ af' ef' c'4\arpeggio s2 g
 d' b'4\arpeggio }
 %{lh63 %} { r16 g16 c16 d16 ef16 g16 c8 f, c'2 }\\{c,2 r4 c'4 }
 %{lh64 %} df, af'2. cf gf'4_-
 %{lh65 %} { bf'2 bf2 }\\{ bf,4 bf4 bf4 bf4 }
 %{lh66 %} { bf'2 bf2 }\\{ bf,4 bf4 bf4 bf4 } r1
 }
 % SA_TB seperate + piano staff
 % {
 \score {
  \new GrandStaff = GrandStaff_score 
  \new ChoirStaff 
  \new Staff \with { \override RestCollision #'positioning-done =
 #merge-rests-on-positioning
  }
  \clef bass
  \global \partcombine
  \new Voice = Tenor {
  \voiceOne { \TTj \TBk }}
  \new Voice = Bass {
  \voiceTwo { \BBj \TBk }}
  
  
  \new PianoStaff 
  \set PianoStaff.connectArpeggios = ##t
  \new Staff = RH { \global \PianoRH }
  \new Staff = LH { \global \clef bass \PianoLH }
  
  
  \layout { indent = #'0
  \context { \RemoveEmptyStaffContext }