Discussion:
Custom AccidentalStyle
mansouraoun
2018-12-07 13:31:34 UTC
Permalink
Hello everyone,

I'm trying to have a custom accidental style but I don't know exactly how am
i supposed to achieve this.

The one I'm looking for is fairly simple, it's between 'dodecaphonic' and
'forget':
Knowing that there's no key signature: write all accidentals for all notes,
but write naturals only if the note has been altered earlier on the same
octave and in the same measure.

For example in the image below:
<Loading Image...>

The natural g should stay as it is, because it wasn't preceded with an
altered g on the same octave.
While the last note, the natural d, should have a natural sign because it
was preceded by a d sharp in the same measure.

I'm applying here the forget style.
The dodecaphonic style would insert a natural sign in front of the natural g
which I don't need and the forget style would not insert a natural sign in
front of the last d, which I need.

Thanks in advance,

Mansour



--
Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html
Phil Holmes
2018-12-07 14:32:33 UTC
Permalink
----- Original Message -----
From: "mansouraoun" <mansour-***@hotmail.com>
To: <lilypond-***@gnu.org>
Sent: Friday, December 07, 2018 1:31 PM
Subject: Custom AccidentalStyle
Post by mansouraoun
Hello everyone,
I'm trying to have a custom accidental style but I don't know exactly how am
i supposed to achieve this.
The one I'm looking for is fairly simple, it's between 'dodecaphonic' and
Knowing that there's no key signature: write all accidentals for all notes,
but write naturals only if the note has been altered earlier on the same
octave and in the same measure.
<http://lilypond.1069038.n5.nabble.com/file/t5738/Screenshot_2018-12-07_at_14.png>
The natural g should stay as it is, because it wasn't preceded with an
altered g on the same octave.
While the last note, the natural d, should have a natural sign because it
was preceded by a d sharp in the same measure.
I'm applying here the forget style.
The dodecaphonic style would insert a natural sign in front of the natural g
which I don't need and the forget style would not insert a natural sign in
front of the last d, which I need.
Thanks in advance,
Mansour
From the NR:

default

This is the default typesetting behavior. It corresponds to
eighteenth-century common
practice: accidentals are remembered to the end of the measure in which they
occur and only in their own octave. Thus, in the example below, no natural
signs
are printed before the b in the second measure or the last c:

Is this not what you want?


--
Phil Holmes
Mansour Aoun
2018-12-07 15:36:27 UTC
Permalink
Well not exactly. I'm just realising that what I'm after is a bit weirder
then it seems to me.
Here are three available styles and each with its respective problem (in
this case):

1- default:
<Loading Image...>
problem: the sharps are remembered along the measure like the first note and
the one before the last, both are d-sharp but the accidental is only
mentioned at the first instance and I don't want that, I want the
accidentals repeated even in the same measure.

2- forget:
<Loading Image...>
problem: doesn't add a natural sign if the note was preceded with an altered
note.

3- dodecaphonic:
<Loading Image...>
problem: adds natural signs where they are not needed. A natural note in a
measure without a key signature does not need a natural sign if it was not
preceded in the same measure by an altered note.

What I'm looking for is this:
<Loading Image...>
As you can see:
- the accidentals are not remembered along the measure
- if a note occurs in the measure for the first time in its natural state it
doesn't require a natural sign
- if note has been altered previously in the measure, when called in its
natural state requires a natural sign.

So if you want it is like a forget-cautionary if you want, reminding the
reader to recall the natural state of the note if it was altered earlier
during the measure.



--
Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html
Phil Holmes
2018-12-07 15:48:26 UTC
Permalink
----- Original Message -----
From: "Mansour Aoun" <mansour-***@hotmail.com>
To: <lilypond-***@gnu.org>
Sent: Friday, December 07, 2018 3:36 PM
Subject: Re: Custom AccidentalStyle
Post by Mansour Aoun
Well not exactly. I'm just realising that what I'm after is a bit weirder
then it seems to me.
Here are three available styles and each with its respective problem (in
<http://lilypond.1069038.n5.nabble.com/file/t5738/default.png>
problem: the sharps are remembered along the measure like the first note and
the one before the last, both are d-sharp but the accidental is only
mentioned at the first instance and I don't want that, I want the
accidentals repeated even in the same measure.
<http://lilypond.1069038.n5.nabble.com/file/t5738/forget.png>
problem: doesn't add a natural sign if the note was preceded with an altered
note.
<http://lilypond.1069038.n5.nabble.com/file/t5738/dodecaphonic.png>
problem: adds natural signs where they are not needed. A natural note in a
measure without a key signature does not need a natural sign if it was not
preceded in the same measure by an altered note.
<http://lilypond.1069038.n5.nabble.com/file/t5738/desired.png>
- the accidentals are not remembered along the measure
- if a note occurs in the measure for the first time in its natural state it
doesn't require a natural sign
- if note has been altered previously in the measure, when called in its
natural state requires a natural sign.
So if you want it is like a forget-cautionary if you want, reminding the
reader to recall the natural state of the note if it was altered earlier
during the measure.
neo-modern appears very close to what you want, and may be satisfactory for
your use case?

--
Phil Holmes
Mansour Aoun
2018-12-07 15:55:14 UTC
Permalink
Indeed it is. Thanks!
i was disregarding it because of the non-repetition of accidentals for
repeated notes since I was looking for an absolute solution where it would
repeat the accidental even for repeated notes but for the piece I'm working
on, neo-modern will do a good job.

Mansour



--
Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html
Simon Albrecht
2018-12-07 18:05:32 UTC
Permalink
In case you should arrive at the point where you really want a custom
accidental style: I have done that before and already posted a (brief)
explanation and full example file to this list. The search engine in the
archive seems to be on strike right now, but you should be able to find
it (maybe with ‘custom accidental style baroque’).

Best, Simon
Post by Mansour Aoun
Indeed it is. Thanks!
i was disregarding it because of the non-repetition of accidentals for
repeated notes since I was looking for an absolute solution where it would
repeat the accidental even for repeated notes but for the piece I'm working
on, neo-modern will do a good job.
Mansour
--
Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html
_______________________________________________
lilypond-user mailing list
https://lists.gnu.org/mailman/listinfo/lilypond-user
David Wright
2018-12-08 01:23:28 UTC
Permalink
Post by Simon Albrecht
In case you should arrive at the point where you really want a custom
accidental style: I have done that before and already posted a (brief)
explanation and full example file to this list. The search engine in
the archive seems to be on strike right now, but you should be able to
find it (maybe with ‘custom accidental style baroque’).
Is it perhaps this on lilypond-devel:
http://lists.gnu.org/archive/html/lilypond-devel/2016-05/msg00119.html

Cheers,
David.
Simon Albrecht
2018-12-08 20:38:24 UTC
Permalink
Post by David Wright
Post by Simon Albrecht
In case you should arrive at the point where you really want a custom
accidental style: I have done that before and already posted a (brief)
explanation and full example file to this list. The search engine in
the archive seems to be on strike right now, but you should be able to
find it (maybe with ‘custom accidental style baroque’).
http://lists.gnu.org/archive/html/lilypond-devel/2016-05/msg00119.html
Cheers,
David.
Yes it is, thank you :-)

Best, Simon

Loading...