lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Ledger-line-spanner: symmetric extents; issue 2493 (issue 6490043)


From: Keith OHara
Subject: Re: Ledger-line-spanner: symmetric extents; issue 2493 (issue 6490043)
Date: Wed, 29 Aug 2012 14:20:15 -0700
User-agent: Opera Mail/12.01 (Win32)

On Wed, 29 Aug 2012 11:23:42 -0700, <address@hidden> wrote:

http://codereview.appspot.com/6490043/diff/7001/lily/ledger-line-spanner.cc#newcode50
lily/ledger-line-spanner.cc:50: < Paper_column::get_rank
(previous_column)))
It seems that previous_column should have a rank falling before current column,
not after.

This is a helper function for the loop down on line 100, which runs backwards.
There is already a comment just below "we go from right to left."
The loop can now run forwards; maybe I should un-reverse it.

Also, it seems like if the variables are called this, then the order
should be correct when they are passed into the function (meaning the
one supposed to come before the other comes before the other).
Otherwise a programming error should be raised.  What would be the case
where the ranks of the columns would be reversed and what would justify
that happening?


Master does raise a programming for ambitus note heads
  \new Staff \with { \consists "Ambitus_engraver" } { c''' d'' e' f }
The ambitus engraver creates the heads when it first starts, and adds them 
using add_grob(), but somehow that puts them between the c''' and d'' in the 
array.

The array contains every note-head in the Staff (that is, thousands) so I would 
rather not take the time to sort it.  Creating an add_front() through all the 
layers of classes, for use in ambitus_engraver.cc, did not seem wise.

Given at least one known exception to ordering, I added a test for ordering.  
Now I think it better to test for the known exception: skip over any 
ambitus-note-heads.  Or, we could continue to issue a programming-error for 
this case.

http://codereview.appspot.com/6490043/


My motivation is to replace the non-looping loop
  Direction d=DOWN; do {...} while (flip (&d) != DOWN);




reply via email to

[Prev in Thread] Current Thread [Next in Thread]