]> git.donarmstrong.com Git - lilypond.git/blob - input/regression/flip-stencil.ly
Release: bump Welcome versions.
[lilypond.git] / input / regression / flip-stencil.ly
1 \version "2.19.19"
2
3 \header {
4   texidoc = "Stencils can be flipped horizontally or vertically within
5 their bounding box using @code{flip-stencil}."
6 }
7
8 square =
9 #(make-path-stencil
10   '(moveto 0 0 lineto 0 2 lineto 2 2 lineto 2 0 closepath)
11   0.1 1 1 #f)
12
13 triangle =
14 #(stencil-with-color
15   (make-path-stencil
16    '(moveto 0 0 lineto 2 2 lineto 2 0 closepath)
17    0.3 1 1 #f)
18   blue)
19
20 {
21   g'1^\markup \stencil
22   #(ly:stencil-add square triangle)
23   _\markup \teeny "baseline"
24
25   g'1^\markup \stencil
26   #(ly:stencil-add square (flip-stencil X triangle))
27   _\markup \teeny "flip X"
28
29   g'1^\markup \stencil
30   #(ly:stencil-add square (flip-stencil Y triangle))
31   _\markup \teeny "flip Y"
32 }