[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Sketch for in-notes. (issue 5293053)
From: |
mtsolo |
Subject: |
Sketch for in-notes. (issue 5293053) |
Date: |
Thu, 20 Oct 2011 13:11:05 +0000 |
Reviewers: ,
Message:
Hey all,
As part of project markup & at the suggestion of Nicolas Sceaux by way
of Valentin's opera, I've implemented in-notes in LilyPond. These notes
hover above systems and come up a fair bit in vocal music.
It works, but I have one major and one semi-major snag that I'd like to
run by people. Please don't run the regtests on this yet until these
snags are worked out.
Semi-major-snag: get_footnotes_from_lines should only ever be called
once and should stash its results in the systems and/or probs. I'll
figure out how to do this in the near future.
Major snag. On about 1 out of every 5 runs of this patch, it leads to
way-too-big spacing. This is because the stencils of in notes are, for
some reason, registering infinite extents in page-spacing.cc when
they're being counted (check account_for_footnotes and you'll see that
the value of the extent for in_notes is occasionally really really
really large). This is strange because when the in_notes are added to
the breaker (System::get_in_notes_in_range), these extents are correct.
I think it is an issue with pointers and garbage collection of stencils
- does anyone have any intuition about this.
Here's a test file:
\version "2.15.15"
\header {
texidoc = "LilyPond does in-notes. The positioning of these notes can
be above or below the staff via the paper variable @code{in note
direction}
and spaced via the variable @{in-note-padding}.
"
}
\relative c' {
\repeat unfold 5 {
\repeat unfold 20 { a\< b c d\! }
% activates the in-note
\once \override FootnoteItem #'footnote = ##f
\footnoteGrob #'NoteHead #'(0 . 0)
"" \markup { \box \fill-line { "this is a test this is
a test" } }
a b c d
\repeat unfold 20 { a b c d }
\autoFootnoteGrob #'NoteHead #'(-1 . 1) "foo bar foo bar"
a b c d
\repeat unfold 20 { a\< b c d\! }
}
}
Description:
Sketch for in-notes.
Please review this at http://codereview.appspot.com/5293053/
Affected files:
M lily/constrained-breaking.cc
M lily/include/constrained-breaking.hh
M lily/include/page-breaking.hh
M lily/include/page-layout-problem.hh
M lily/include/system.hh
M lily/page-breaking.cc
M lily/page-layout-problem.cc
M lily/page-spacing.cc
M lily/system.cc
M scm/define-grob-interfaces.scm
M scm/define-grob-properties.scm
M scm/define-grobs.scm
M scm/paper-system.scm
- Sketch for in-notes. (issue 5293053),
mtsolo <=
- Re: Sketch for in-notes. (issue 5293053), mtsolo, 2011/10/20
- Re: Sketch for in-notes. (issue 5293053), mtsolo, 2011/10/20
- Re: Sketch for in-notes. (issue 5293053), bordage . bertrand, 2011/10/21
- Re: Sketch for in-notes. (issue 5293053), mtsolo, 2011/10/21
- Re: Sketch for in-notes. (issue 5293053), bordage . bertrand, 2011/10/21
- Re: Sketch for in-notes. (issue 5293053), bordage . bertrand, 2011/10/21
- Re: Sketch for in-notes. (issue 5293053), percival . music . ca, 2011/10/21
- Re: Sketch for in-notes. (issue 5293053), n . puttock, 2011/10/21