]> git.donarmstrong.com Git - lilypond.git/commitdiff
* scm/stencil.scm (circle-stencil): don't center stencil argument,
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Mon, 9 Oct 2006 12:19:28 +0000 (12:19 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Mon, 9 Oct 2006 12:19:28 +0000 (12:19 +0000)
instead: move circle.

* scm/define-grobs.scm (all-grob-descriptions): set
allow-loose-spacing for PaperColumn and NonMusicalPaperColumn.

* lily/spacing-determine-loose-columns.cc (is_loose_column):
allow-loose-spacing property.

* scm/define-markup-commands.scm (postscript): gsave & grestore
around embedded PS. Do setlinewidth too. Fixes  #109.

ChangeLog
scm/define-grobs.scm
scm/define-markup-commands.scm
scm/stencil.scm

index 0a1fdbe85119f05ae31744a16d8946014c5d79f1..9031ef9a7161babdc6347d32bf4f371a7bcbc3fc 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2006-10-09  Han-Wen Nienhuys  <hanwen@lilypond.org>
 
+       * scm/stencil.scm (circle-stencil): don't center stencil argument,
+       instead: move circle.
+
        * scm/define-grobs.scm (all-grob-descriptions): set
        allow-loose-spacing for PaperColumn and NonMusicalPaperColumn.
 
index f35f29d59c57c7e45e552c3d9e281531c0877cc6..be8462be0a055aad3a792867fff2a711588594c3 100644 (file)
                                font-interface
                                text-interface))))))
 
+    (NonMusicalPaperColumn
+     . (
+       (allow-loose-spacing . #t)
+       (axes . (0))
+       (before-line-breaking . ,ly:paper-column::before-line-breaking)
+       (X-extent . ,ly:axis-group-interface::width)
+       ;;                    (stencil . ,ly:paper-column::print)
+       
+       (non-musical . #t)
+       (line-break-permission . allow)
+       (page-break-permission . allow)
+
+       ;; debugging stuff: print column number.
+       ;;               (font-size . -6) (font-name . "sans")  (Y-extent . #f)
+
+       (meta . ((class . Paper_column)
+                (interfaces . (paper-column-interface
+                               axis-group-interface
+                               spaceable-grob-interface))))))
+    
     (NoteCollision
      . (
        (axes . (0 1))
        (meta . ((class . Spanner)
                 (interfaces . (slur-interface))))))
 
-    (NonMusicalPaperColumn
-     . (
-       (allow-loose-spacing . #t)
-       (axes . (0))
-       (before-line-breaking . ,ly:paper-column::before-line-breaking)
-       (X-extent . ,ly:axis-group-interface::width)
-       ;;                    (stencil . ,ly:paper-column::print)
-       
-       (non-musical . #t)
-       (line-break-permission . allow)
-       (page-break-permission . allow)
-
-       ;; debugging stuff: print column number.
-       ;;               (font-size . -6) (font-name . "sans")  (Y-extent . #f)
 
-       (meta . ((class . Paper_column)
-                (interfaces . (paper-column-interface
-                               axis-group-interface
-                               spaceable-grob-interface))))))
 
     (PercentRepeat
      . (
index 03413d128f3ac9994d260d0b9bc0b03882bade64..e6d16ce5583aa88b318d69a1b47061c4407e4a35 100644 (file)
@@ -55,6 +55,7 @@ optionally filled."
   "Draw a circle around @var{arg}.  Use @code{thickness},
 @code{circle-padding} and @code{font-size} properties to determine line
 thickness and padding around the markup."
+  
   (let* ((th (chain-assoc-get 'thickness props  0.1))
         (size (chain-assoc-get 'font-size props 0))
         (pad
index f39328984ba3c2c64f646cd61dba1358a5e8809d..b2d425e6ead5c7061d7e327c0d08934b9a92dbe4 100644 (file)
@@ -100,9 +100,16 @@ encloses the contents.
         (y-ext (ly:stencil-extent stencil 1))
         (diameter (max (- (cdr x-ext) (car x-ext))
                        (- (cdr y-ext) (car y-ext))))
-        (radius (+ (/ diameter 2) padding thickness)))
+        (radius (+ (/ diameter 2) padding thickness))
+        (circle (make-circle-stencil radius thickness #f)))
+
     (ly:stencil-add
-     (centered-stencil stencil) (make-circle-stencil radius thickness #f))))
+     stencil
+     (ly:stencil-translate circle
+                          (cons
+                           (interval-center x-ext)
+                           (interval-center y-ext))))))
+
 
 (define-public (fontify-text font-metric text)
   "Set TEXT with font FONT-METRIC, returning a stencil."