[Top][All Lists]

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

Re: proposal: second style for quartertone accidentals

From: Juergen Reuter
Subject: Re: proposal: second style for quartertone accidentals
Date: Wed, 31 Jan 2007 12:32:47 +0100 (CET)

On Mon, 29 Jan 2007, Han-Wen Nienhuys wrote:

. So it seems that the use of "Accidental #'style" is deprecated and one
should set the alteration-alist directly. (But changing the style
property still works in v2.11.13, even if I don't know why, given that I
couldn't find the code handling it). What is the reason for this? To me
the former notation seems much more intuitive and easy to use.

The recent microtone improvements needed a much more flexible way to map
pitches onto symbols, and it seems superfluous to have two mechanisms for
setting glyphname at the same time.  It would be possible  to have a
mechanism to set the alist based on the style property, but I thought it
would be overkill.

Maybe I should re-propose an idea that I posted maybe 5 years ago, but which was considered overkill at that time.

Styles could be defined in a cascaded way. Say, there is an Accidental style "default" that just maps the standard non-microtonal accidentals to the modern accidental glyphs. The style should be however undefined for microtonal accidentals. Now, suppose that there is another style "arrow-microtonals" that only maps microtonal accidentals to arrow-style glyphs, but keeps silent on non-microtonal accidentals. Then it would be nice for the lily user to compose a style by setting a list of such predefined styles: "\override Accidental #'style = #'(arrow-microtonals default)". That is, for each accidental, lily should first search in the "arrow-microtonals" mapping if the acciental is mapped to some glyph. If no glyph is defined in this mapping, lily should look at the next mapping "default". That is, you get a combination of standard modern accidentals with arrowed microtonals.

There is one downside: If the style "default" defines only the glyphs for non-microtonal accidentals, one always has to explicitly set a microtonal style, if microtonals are to be used. In other ways, the value for the style property tends to become a long list. In order to fix this downside, one may also allow a style to "import" further styles. For example, suppose accidental style "standard" implicitly imports "non-arrow-microtonals". That is, if you set "\override Accidental #'style = #'(default)", you also implicitly get non-arrow-microtonal accidentals, just as if you would have said "\override Accidental #'style = #'(default non-arrow-microtonals)". Note that you still can say "\override Accidental #'style = #'(arrow-microtonals default)". This will effectively override the non-arrowed microtonals that are implicit in the default style with arrowed microtonals, because the arrowed microtonals mapping occurs earlier in the list.

Another downside of this approach could be performance, since each glyph lookup would result in iterating through nested scheme lists. Maybe, a sophisticated caching or precomputing approach could alleviate any performance issues.

No, unfortunately I have currently no time to work on this :-(. These are just generic thoughts...


reply via email to

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