Reviewers: hanwenn, Message: On 2009/08/20 03:12:26, hanwenn wrote:
http://codereview.appspot.com/110047/diff/1/11 File scm/output-lib.scm (right):
http://codereview.appspot.com/110047/diff/1/11#newcode778 Line 778: (ly:grob-suicide! grob) this does not make sense. did you forget to check the length of the
noteheads
array? - why would someone not set join-heads?
I don't know; I just copied it from the C++ code. Since it's possible to hide the line using 'transparent or 'stencil, I guess it's pretty much redundant anyway.
http://codereview.appspot.com/110047/diff/1/11#newcode782 Line 782: (head-up (ly:grob-array-ref heads 1)) you need to check the length of the array
I thought this would be unnecessary, since the array must have two elements ordered by pitch if the pitch interval isn't empty; otherwise the engraver suicides the AmbitusLine. Of course, if you prefer, I'll add a check using ly:grob-array-length.
http://codereview.appspot.com/110047/diff/1/11#newcode795 Line 795: (x-ext (cons (/ (- width) 2) (/ width 2))) this looks like a nice candidate for a small function
(symmetric-interval (/ width 2))
OK.
http://codereview.appspot.com/110047/diff/1/11#newcode801 Line 801: (ly:grob-suicide! grob)))))) it would be nice to explicitly return something, eg '() in the suicide
case -
with all the nesting it is hard to tell what the final result is.
OK. Thanks, Neil Description: Move ambitus print callback to scheme. * implement ambitus::print callback in output-lib.scm * add interface description to define-grob-interfaces.scm * allow user override of padding using grob property 'gap * move 'join-heads to user properties * remove ambitus.cc/.hh * tidy ambitus-engraver.cc * add regression test for 'gap * add convert rule for ly:ambitus::print Please review this at http://codereview.appspot.com/110047 Affected files: A input/regression/ambitus-gap.ly M input/regression/ambitus.ly M lily/ambitus-engraver.cc M lily/ambitus.cc M lily/include/ambitus.hh M python/convertrules.py M scm/define-grob-interfaces.scm M scm/define-grob-properties.scm M scm/define-grobs.scm M scm/output-lib.scm M scm/safe-lily.scm _______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-devel