Centering a stencil on another stencil: Difference between revisions

Import snippet from LSR
 
m New category
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
If you want to re-position a stencil so that it is centered relative to another stencil, on the X axis, the Y axis, or both, you can use the "center-stencil-on-stencil" function from this snippet.
If you want to re-position a stencil so that it is centered relative to another stencil, on the X axis, the Y axis, or both, you can use the "center-stencil-on-stencil" function from this snippet.


<lilypond version="2.24.0">
<lilypond version="2.24">
#(define* (center-stencil-on-stencil stil-a stil-b #:optional axis)
#(define* (center-stencil-on-stencil stil-a stil-b #:optional axis)
   "Return a copy of stencil @var{stil-b} that has been moved  
   "Return a copy of stencil @var{stil-b} that has been moved  
Line 45: Line 45:
[[Category:Scheme]]
[[Category:Scheme]]
[[Category:Symbols and glyphs]]
[[Category:Symbols and glyphs]]
[[Category:Snippet]]