lilypond-user
[Top][All Lists]
Advanced

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

Re: Chromatic clashes


From: Lukas-Fabian Moser
Subject: Re: Chromatic clashes
Date: Sat, 17 Apr 2021 14:32:04 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1

Hi Jean,

\version "2.22.0"

{ <c' cis'> 4 }

[...]

(1) Do you folks agree that the default behaviour qualifies as a bug?

Indeed. There is also an ugly-looking dependence on the input order:

{ <cis' ces'> cis' }
{ <ces' cis'> cis' }

We should probably have a special case when there are several accidentals in the same staff position. I suggest to open an issue on GitLab.

Ok, thanks - will try! 


For what it's worth, I think I found a not-quite-easy way for (2), which I'm happy to share of course (see below), but I am doubtful that this is the most elegant solution...

At any rate, that's pretty much how I'd do it personally.

After posting my engraver yesterday, I noticed some unforeseen behaviour that gave me an idea for a possible addition to your excellent tutorial on https://extending-lilypond.readthedocs.io/ (which I unfortunately only today had time to skim through). Namely:

The engraver I posted yesterday collects notes across all voices or staves, for instance in situations like

<<
  \new Staff { c' }
  \new Staff { cis' }
>>

While this might actually be desirable (at least I tell my students never ever to produce

since nobody knows if the clash is intended or not), I was surprised that it did so. That's how I found out that if I wrap the engraver in a (lambda (ctx) .... ) construct, then it seems to work independently for each voice context, even if it's \consist'ed to all Voices or Staves in the \layout {} block.

Maybe that would be an interesting addition to your engraver tutorial?

And while we're at it, here's another question: It turns out it's possible to add note-event properties like force-accidental inside the process-music hook. But when I tried to change the _pitch_ of a note at this stage, there was no effect. I _can_ change the pitch of a note-event in the note-head listener, but that's too early in my use case (since I need to know all simultaneous pitches).
So, in which parts of an engraver do I still have the opportunity to change pitches?

Lukas


reply via email to

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