lilypond-devel
[Top][All Lists]
Advanced

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

Re: Implements the 2nd of 5 legs of getting footnotes up and running. (i


From: address@hidden
Subject: Re: Implements the 2nd of 5 legs of getting footnotes up and running. (issue4254055)
Date: Fri, 11 Mar 2011 18:00:28 +0100

On Mar 11, 2011, at 2:44 PM, Han-Wen Nienhuys wrote:

Hi Mike,

can fix the below points before continuing with pushing stuff for this
patch series?

On Sun, Mar 6, 2011 at 8:46 PM,  <address@hidden> wrote:
+// ugh...code dup...hopefully can be consolidated w/ above one day

can you make a priority to do this right now?  If it's not done
directly, 'one day' usually does not happen at all.

Sorry - the consolidation already happened in the internal print function.  I forgot
to remove the comment.


+      int pos = orig->spanned_rank_interval ()[LEFT];
+      Real spanner_placement = min (1.0,
+                                    max (robust_scm2double
(me->get_property ("spanner-placement"), -1.0),
+                                         -1.0));
+
+      spanner_placement = (spanner_placement + 1.0) / 2.0;
+      int rpos = orig->spanned_rank_interval ()[RIGHT];
+      pos = (int)((rpos - pos) * spanner_placement + pos + 0.5);
+
+      if (pos < me->spanned_rank_interval () [LEFT])
+        return SCM_EOL;

Can you rethink this? The rank numbers are not good measures of
anything.  In particular, adding a new voice/staff with different
rhythmic texture will cause these numbers to fluctuate, and mess up
your positioning.  I still think this is a overall bad idea, and would
love to see examples where users need placement of footnotes, but
placement so inexact that they do not want to use per-item
positioning.  One possibility is to use column->when() as a measure,
as it is least somewhat invariant, but preferably I'd like to scrap
this (especially given the code dup and overall ugliness) until we
have proof that it's really needed.

Done.

http://codereview.appspot.com/4286042/

Cheers,
MS

reply via email to

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