On Wed, Sep 10, 2025 at 1:15 AM Walt North <waltno...@gmail.com> wrote:
> My case is that I have some notes that may be played on guitars with > differing turnings. To accomplish this I would like to separate the fret > specifics from the actual notes. What is happening is that only the first > section of music reflects the fret details for a given tuning. Following > is a trimmed down example with just two measures along with result screen > shots. > > \version "2.24.2" > > \language "english" > > %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% > > bckngNotes = \relative c' { > b'1 | > } > > gtrBackingNoteDetails = { > \set restrainOpenStrings = ##t > \set minimumFret = #12 > s1 | > } > > verseScore = << > \tag #'gtrBackingNotes \context TabStaff = "gtrBackingNotes" > << \bckngNotes \gtrBackingNoteDetails >> > > >> > > %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% > > bckngNotes = \relative c' { > b1 | > } > > gtrBackingNoteDetails = { > \set restrainOpenStrings = ##t > \set minimumFret = #4 > s1 | > } > > chorusScore = << > \tag #'gtrBackingNotes \context TabStaff = "gtrBackingNotes" > << \bckngNotes \gtrBackingNoteDetails >> > > >> > > %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% > fullScore = { > \verseScore > \chorusScore > } > > %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% > \book { > \score { > << > \keepWithTag #'(gtrBackingNotes) > \fullScore > >> > } > } > > > Here is a screen shot of the result. What I was hoping for is that the > second measure would indicate the 4th fret. > > fullScore = { > \verseScore > \chorusScore > } > > If I flip the verse and chorus measures I get and would have wanted the > second measure to be 12. > > fullScore = { > \chorusScore > \verseScore > } > > > Walt, The fret numbers come from calculating pitches based on the current stringTunings property. The properties you were changing don't change the fret number for the pitch, they just change the allowed range of fret numbers. I'm not sure how you are handling your different tunings. You must have clipped those parts out of your example. If you could show us how you are changing the tunings, I could possibly give you a better answer. The issue with which you are wrestling is that LilyPond won't allow you specify a string and a fret for a note. You can specify a string, and then the fret will be defined for a given stringTunings. Sorry I can't be of more help with the information you've given. Carl