%% Generated by lilypond-book
%% Options: [exampleindent=10.16\mm,indent=0\mm,line-width=110\mm,noragged-right,quote]
\include "lilypond-book-preamble.ly"


% ****************************************************************
% Start cut-&-pastable-section
% ****************************************************************

#(ly:set-option 'eps-box-padding 3.000000)



\paper {
  indent = 0\mm
  line-width = 110\mm
  % offset the left padding, also add 1mm as lilypond creates cropped
  % images with a little space on the right
  line-width = #(- line-width (* mm  3.000000) (* mm 1))
  ragged-right = ##f
  line-width = 110\mm - 2.0 * 10.16\mm
  % offset the left padding, also add 1mm as lilypond creates cropped
  % images with a little space on the right
  line-width = #(- line-width (* mm  3.000000) (* mm 1))
}

\layout {
  
}




% ****************************************************************
% ly snippet:
% ****************************************************************
\sourcefileline 2151
#(define zero-space '((padding . -inf.0) (basic-distance . 0)))

alignToZero = \with {
  \override VerticalAxisGroup.nonstaff-relatedstaff-spacing = #zero-space
  \override VerticalAxisGroup.nonstaff-nonstaff-spacing = #zero-space
  \override VerticalAxisGroup.staff-affinity = #DOWN
  \remove Text_engraver % impedeix que n'hi hagi dos
  \consists Text_engraver
}
lowerCaseChords = \with {
  chordNameLowercaseMinor = ##t
}
labelContext =
#(define-music-function
     (context)
     (string?)
     #{ s1*0^\markup { \upright {\typewriter #context } } #})

\layout {
  \context { \Dynamics    \alignToZero }
  \context { \FiguredBass \alignToZero }
  \context { \Lyrics      \alignToZero }
  \context { \NoteNames   \alignToZero }
  \context { \ChordNames  \alignToZero \lowerCaseChords }
  \context { \FretBoards  \alignToZero }
  \context { \Score
    \omit BarLine
    \override DynamicText.self-alignment-X = #-1
    \override FretBoard.X-offset = #1.75
    \override InstrumentName.minimum-Y-extent = #'(-1 . 2)
    \textLengthOn
    \omit TimeSignature
  }
}

%% Aquests contextos tenen punts de referència a la línia base:
%%   ChordNames, NoteNames, i Lyrics
<<
  \new ChordNames { \chords { \labelContext "ChordNames"  g1:m } }
  \new NoteNames { s1 |\labelContext "NoteNames"  g1 | }
  \new Lyrics { \lyrics { \skip 1*2 | \labelContext "Lyrics" ghijk1 | } }
  \new RhythmicStaff \with { instrumentName = "baseline " } s1*3
>>

%% El punt de referència per a Dynamics és la línia mitjana de 'm' al tipus de lletra
<<
  \new Dynamics { \labelContext "Dynamics" s1\mp s\fp }
  \new RhythmicStaff \with { instrumentName = "mid-height " } s1*3
>>

%% EL punt de referència per a FiguredBass és el punt més alt
<<
  \new FiguredBass { \labelContext "FiguredBass" \figuremode { <6 5>1 } }
  \new RhythmicStaff \with { instrumentName = "highest point " } s1
>>

%% El punt de referència per a FretBoards és la línia de més a dalt
\include "predefined-guitar-fretboards.ly"
<<
  \new FretBoards { \labelContext "FretBoards" \chordmode { e1 } }
  \new RhythmicStaff \with { instrumentName = "top line " } s1
>>



% ****************************************************************
% end ly snippet
% ****************************************************************
