lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Question regarding ChordNames


From: John Helly
Subject: Re: Question regarding ChordNames
Date: Tue, 12 Mar 2024 23:08:52 -1000
User-agent: Mozilla Thunderbird

Wow.  Mahalo.

I don't understand this yet but I very much appreciate your response.

J.

On 3/12/24 22:55, Jean Abou Samra wrote:

Mahalo, X. I am using the naturalizeMusic function and will look into extending that.  Maybe that has some nuggets to mine.

\naturalizeMusic is not going to work well on \chordmode music (it will destroy the interval in chords, leading to wrong chord names), but you can use code like this instead:

\version "2.24.2"

enharmonization = { c cis d ees e f fis g gis a bes b }

converter = #(make-semitone->pitch (music-pitches enharmonization))

\layout {
  \set ChordNames.chordRootNamer =
    #(lambda (pitch lowercase)
       (note-name->markup (converter (ly:pitch-semitones pitch)) lowercase))
}

bflat = \chordmode { cis dis e fis gis a bis cis bes }

\transpose cis' a {
  \new ChordNames { \bflat  }
}

Best,

Jean


-- 
John Helly / San Diego Supercomputer Center / Scripps Institution of Oceanography 
https://www.sdsc.edu/~hellyj / 808 205 9882 / 760 8408660

reply via email to

[Prev in Thread] Current Thread [Next in Thread]