% URG

changequote(^, @)
define(comma, r16 [$1$4 $2 $3] [$2 $1 $2 $6$1] r $1$7 r $5$1 |)
define(s, ^comma(translit($*,^ @, ^,@))@)
define(t, r16 [$1$4 $2 $3] [$2 $1 $2 $6$1] r $1$7 r $5$1 |)

\header{
filename =	 "preludes-3.ly";
% Pr"aludum in C Moll f"ur Laute
% blz 16
% Six Petits Preludes`
% Collection Johann Peter Kellner
% ca 1703 - 1707
composer =	 "Johann Sebastian Bach (1685-1750)";
enteredby =	 "jcn";
copyright =	 "public domain";
}

\version "1.1.60";


upper = \context Staff \notes \transpose c'' {
	\context Voice=i
	\property Voice . textstyle = "italic"
%#	s(^c@ ^es@ ^g@ ^\p(\<@ ^\!@ ^)\!@ ^\>@)
	t(c,es,g,^\p(\<@,\!,^)\!@,\>)
%#	s(c es g ^(@ ^@ ^)@)
	t(c,es,g,^(@,^@,^)@)
%#	s(c f as ^(@ ^@ ^)@)
	t(c,f,as,^(@,^@,^)@)
	s(c f as)
	s(b` d f \< \!)
	s(b` d f)
	s(g` c es \> \!)
	s(g` c es)
	s(g` c es \< \!)
	s(g` c es)
	s(a` c es)
	s(a` c es)
	s(a` bes` d \> \!)
	s(g` bes` d)
	s(bes` d g)
	s(a` es g \mf)
	s(a` c fis)
	s(a` c fis)
	s(bes` d g)


%#	s(c fis a -"poco a poco cresc.")
%# 	t(c,fis,a,-"poco a poco cresc.")
	s(c fis a)
	s(d g bes)
	s(d fis c`)

	s(cis g bes)
%#	s(c es a !-"dim.")
	s(c es a !)
	s(bes` e g)
	s(a` c g)

	s(a` c fis)
	s(g` bes` e)
	s(fis` a` es)

	s(g` bes` d -"dim.")
	s(g` a` c)
	s(fis` a` c)
	s(fis` a` c)
	r16\p [g` a` c] [b` g` b` g`] r g` r g`
%#	s(a` c fis -"poco cresc.")
%# 	t(a`,c,fis,-"poco cresc.")
	s(a` c fis)
	s(c fis a)
	s(b` d g)
%#	s(b` d f -"dim.")
	s(b` d f)
	s(g` c es)
	s(fis` c es)
	s(fis` c es)
	r16 [g`(\< b` d] [b` g` b` d] [es c a` \!fis] |
	\context Staff <
		\context Voice=i {\stemup ) g2.-\fermata\mf}
		\context Voice=ii {\stemdown <b`2. d>}
	>
	\stemboth
	\bar "|.";
}

lower = \context Staff \notes{
	% c4 r [g8-.(\ped )es-.\*] |
	c4 r [g8-.( )es-.] |
	c4 r [g8-.( )es-.] |
	c4 r [as8-.( )f-.] |

	c4 r [as8-.( )f-.] |
	c4 r [as8-.( )f-.] |
	c4 r [as8-.( )f-.] |

	c4-- r [es8 c] |
	bes`!4-- r [es8 c] |
	as`!4-- r [es8 c] |

	g`4-- r [es8 c] |
	fis`4-- r [es8 c] |
	fis`4 r [fis8 d] |

	g`4 r [d8 bes`] |
	g`4 r [bes`8 g`] |
	es`4 r [g8 es] |

	c4 r [c8 a`] |
	d`4 r [d8 a`] |
	d`4 r [d8 a`] |
	d`4 r [d8 bes`] |


	d`4 r [es8 c] |
	d`4 r [g8 d] |
	d`4 r [a8 fis] |

	d`4 r [g8 es] |
	d`4 r [fis8 d] |
	d`4 r [e8 cis] |
	d`4 r [es8 c] |

	d`4 r [d8 a`] |
	d`4 r [cis8 bes`] |
	d`4 r [c!8 a`] |

	d`4 r [bes`8 g`] |
	d`4 r [es8 c] |
	d`4 r [d8 a] |

	g`4 r [es8 c] |
	g`4 r [d8 b`] |
	g`4 r [es8 c] |
	
	g`4 r [es8 c] |
	g`4 r [g8 d] |
	g`4 r [as8 f] |
	g`4 r [es8 c] |

	g`4 r [es8 c] |
	g`4 r [es8 c] |
	g`4 r r |
	g`2._\fermata 
	\bar "|.";
}

global  = \notes{
	\time 3/4;
	\key es;
}

\score{
	% Semplice e non troppo legato
	\context GrandStaff <
		\context Staff = upper <
			\global
			\upper
		>
		\context Staff = lower <
			\global
			\clef "bass";
			\lower
		>
	>
	\paper{
		\include "preludes-paper.ly";
		gourlay_maxmeasures = 4.0;
	}
	\midi{ \tempo 4 = 100; }
	\header{
		opus = 	"BWV 999";
		piece = "3";
	}
}
