On Feb 28, 2011, at 5:42 PM, Neil Puttock wrote:

> On 28 February 2011 00:32,  <mts...@gmail.com> wrote:
> 
>> For now, I'm just gonna remove this kludge and leave it as is.  It means
>> that certain spanners may budge when annotations are attached to them,
>> but I'll need more time to figure out a sustainable way to get the axis
>> engraver to ignore the height of these annotations.  My initial hunch
>> after reading your comment was to set cross-staff to #t, but this
>> segfaults on any spanner that has a line break.
> 
> Why can't you just set Y-extent to #f (like BalloonTextItem does)?
> 

cross-staff winds up doing the trick - it wasn't cross staff that segfaulted, 
but something else (see below).

I can use either (cross-staff . #t) , (Y-extent . #f) , or both depending on 
what floats people's boats.

>> This segfault for cross staff may reveal some problems with the way that
>> the FootnoteSpanner is being treated in the axis engraver - any
>> thoughts?
> 
> Can you post an example which segfaults?

Sorry - I've since fixed it in line 65-66 of balloon.cc .  Sometimes, 
parent-spanner is not set (this likely comes from the FoonoteSpanner getting 
broken into pieces and, for whatever reason, not getting passed a parent 
spanner property.  That or the parent spanner no longer exists).

This is part of a larger problem, which is that in the current implementation, 
the parent-spanner is not yet broken into pieces when passed to 
Balloon::print_spanner.  This means that the annotation cannot apply to 
anything but the first spanner of a series.  I am reticent to trigger line 
breaking of the parent-spanner, and I'm not even certain that I'd know how in a 
lilypondaic way.  If anyone has ideas on how to make this more flexible, I'd be 
happy to hear what you have to say!

> 
>> I think I do need it - a pretty print to the command line shows that the
>> parent of these spanners is a PaperColumn when the print function is
>> called in spite of the fact that I set it to be a spanner, whereas
>> "parent-spanner" doesn't change.  Somewhere in the code, this guy's
>> parents are getting reset.
> 
> I can't say I've noticed this.  Every example I tested had the correct 
> Y-parent.
> 

You're right...I was reading the code incorrectly.

>> http://codereview.appspot.com/4213042/diff/34032/lily/footnote-engraver.cc#newcode119
>> lily/footnote-engraver.cc:119: "Footnote ",
>> On 2011/02/27 22:42:24, Neil Puttock wrote:
>>> 
>>> "Footnote "
>>> "FootnoteSpanner ",
>> 
>>> Perhaps rename Footnote FootnoteItem.
>> 
>> I don't mind renaming it, but could you give a reason for doing so?
> 
> It makes the distinction between the two types clearer (and ties in
> with BalloonTextItem/ParenthesesItem).

Done - I misunderstood your original suggestion.
> 
>> http://codereview.appspot.com/4213042/diff/34032/scm/define-markup-commands.scm
>> File scm/define-markup-commands.scm (right):
>> 
>> http://codereview.appspot.com/4213042/diff/34032/scm/define-markup-commands.scm#newcode142
>> scm/define-markup-commands.scm:142: (define-markup-command (draw-hline
>> layout props)
>> On 2011/02/27 22:42:24, Neil Puttock wrote:
>>> 
>>> still needs simplifying via draw-line
>> 
>> I'm still not quite sure how to do this - do you want me to change the
>> thickness property of props and then call draw-line?
> 
> See my comment on your sixth patchset (it comes with an example 
> implementation).
> 

Done.

Cheers,
MS
_______________________________________________
lilypond-devel mailing list
lilypond-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-devel

Reply via email to