[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 'avoid-slur proposals
From: |
Neil Puttock |
Subject: |
Re: 'avoid-slur proposals |
Date: |
Sat, 11 Apr 2009 16:27:47 +0100 |
2009/4/11 Mark Polesky <address@hidden>:
> 'avoid-slur proposals:
>
> 1. remove 'avoid-slur from Slur properties
>
> Why does Slur have an 'avoid-slur property?
So they avoid phrasing slurs.
> Can anyone give an example where the command
> \override Slur #'avoid-slur = #<something>
> has an effect?
\relative c' {
\override Slur #'avoid-slur = #'outside
c\( d( e) f\)
}
> 2. add a choice: 'ignore
>
> \override Fingering #'avoid-slur = ##f triggers the
> message: "warning: Ignoring grob for slur: Fingering.
> avoid-slur not set?"
>
> Staff.Accidental also triggers the warning (and I don't
> know how many others). Perhaps the warning could be
> removed if the user demonstrates intent like this:
> \override Fingering #'avoid-slur = #'ignore
> By the way, is there a way to suppress this warning? I'm
> working on a macro that could potentially trigger this
> warning dozens of times in a single compile. Something
> akin to \override NoteColumn #'ignore-collision = ##t
> but for Slur instead?
Sounds like a good idea, and only requires one extra line of code for
#'avoid-slur = #'ignore.
> 3. rewrite the docstring.
> So here's my new docstring. Notice that I'm so adamant
> about the 'ignore choice that I've incorporated it
> already. Perhaps it's a little too long, but I prefer
> it this way. The super-concise version that's there
> nowhas confused me for long enough.
>
> __________________________________
>
>
> Method of handling slur collisions.
> Choices are 'inside, 'outside, 'around,and 'ignore.
>
> 'inside adjusts the slur if needed to keep the grob inside
> the slur. 'outside moves the grob vertically to the outside
> of the slur. 'around moves the grob vertically to the
> outside of the slur only if there is a collision. 'ignore
> does not move either. In grobs whose notational significance
> depends on vertical position (such as accidentals, clefs,
> etc.), 'outside and 'around behave like 'ignore.
>
> __________________________________
>
That's much clearer.
For 'around, though it's implied in your description, it's probably
better to say that it behaves like 'inside unless there's a collision.
> 4. implement 'avoid-ties and 'avoid-phrasing-slurs?
>
> just an idea.
An unnecessary complication for phrasing slurs, since they're nearly
identical to slurs (and duplicate most of the code).
Judging by the number of `ugh' comments related to avoid-slur in the
source, extending the same behaviour to ties is probably undesirable
(though it would be good if they avoided clefs and time signatures).
> 5. answer 2 more of my questions
>
> Why is it that\override Script #'avoid-slur = ##f
> looks like 'inside for staccato dots, but looks like
> 'around for accents? And why do neither of them actually
> ignore the slurs, as the current docstring suggests they
> might?
You can't override 'avoid-slur for scripts unless you use \tweak or
override scriptDefinitions; the engraver gets the default properties
from default-script-alist *after* you've used \override:
\relative c' {
c4-\tweak #'avoid-slur ##f ->( d)
\set scriptDefinitions =
#(cons '("staccato" .
((script-stencil . (feta . ("staccato" . "staccato")))
(side-relative-direction . -1)
(quantize-position . #t)
(avoid-slur . #f)
(toward-stem-shift . 0.5)
(padding . 0.20)
(script-priority . -100)))
default-script-alist)
c4-.( d)
}
> And finally, why trigger a warning for Fingering and
> Staff.Accidental (and, as previously stated, I don't know
> how many others) but not for Staff.TimeSignature and
> Staff.Clef?
You'll get a warning for any graphical grob that the Slur_engraver
acknowledges. If you take a look at slur-engraver.cc you'll see that
it acknowledges the following:
Accidental
Fingering
Script
TextScript
Tie
TupletNumber
The warning is inside the auxiliary method which does the acknowledging.
Regards,
Neil