]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/slur.cc (outside_slur_callback): epsilon-delta management
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Wed, 29 Sep 2004 22:42:03 +0000 (22:42 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Wed, 29 Sep 2004 22:42:03 +0000 (22:42 +0000)
for slur edges.

* scm/framework-tex.scm (dump-page): put stencil height in dumped
page.

ChangeLog
lily/slur.cc
scm/framework-tex.scm

index e0c230bc9e07c034e86ab32e8dc24d65b3dab076..feeb553770518818a5727f656ad1b0f79539a083 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2004-09-30  Han-Wen Nienhuys   <hanwen@xs4all.nl>
 
+       * lily/slur.cc (outside_slur_callback): epsilon-delta management
+       for slur edges.
        * scm/framework-tex.scm (dump-page): put stencil height in dumped
        page.
 
index 7be89976d8fe6db83b554eecc554255992f5ece5..2f83d045a3a07db6e8a69140886508c49db7f583 100644 (file)
@@ -169,8 +169,14 @@ Slur::outside_slur_callback (SCM grob, SCM axis)
   
   if (!bezext.contains (x))
     return scm_make_real (0);
-
-  Real y = curve.get_other_coordinate (X_AXIS, x);
+  Real dist = fabs (x - bezext[LEFT]) <? fabs (x - bezext[RIGHT]);
+  
+  Real y = (dist >  1e-3)
+    ? curve.get_other_coordinate (X_AXIS, x)
+    : ((x < bezext.center())
+       ? curve.control_[0][Y_AXIS]
+       : curve.control_[3][Y_AXIS]);
+       
   if (yext.contains (y)) 
     {
       Direction dir = get_grob_direction (script); 
index d27785d75c741fbe9efee4dbcd73dfaaedb2be41..98dc39fc3873be095fcca39464a381e8dcac5f46 100644 (file)
   (ly:outputter-dump-string
    putter
    (if last?
-       "}\\vss\n}\n\\vfill\n"
-       "}\\vss\n}\n\\vfill\\lilypondpagebreak\n")))
+       "}\\vss\n}\n\\vss\n"
+       "}\\vss\n}\n\\vss\\lilypondpagebreak\n")))
 
 (define-public (output-framework outputter book scopes fields basename )
   (let* ((bookpaper (ly:paper-book-book-paper book))