summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick McCarty <pnorcks@gmail.com>2010-08-13 14:42:46 -0700
committerPatrick McCarty <pnorcks@gmail.com>2010-08-13 15:03:08 -0700
commit01847735ed2800e8a7a74802c39b906ef7362015 (patch)
tree0e94dcd976be805f5a415fd3c0cd84cb8bab85e3
parent8a104f4a3f020c9fcd6ebbb1c9c4cf88f1020371 (diff)
Add regression tests for \path markup command.
-rw-r--r--input/regression/markup-path-fill.ly17
-rw-r--r--input/regression/markup-path-linecap.ly26
-rw-r--r--input/regression/markup-path-linejoin.ly27
-rw-r--r--input/regression/markup-path.ly23
4 files changed, 93 insertions, 0 deletions
diff --git a/input/regression/markup-path-fill.ly b/input/regression/markup-path-fill.ly
new file mode 100644
index 0000000000..e4c9a030ba
--- /dev/null
+++ b/input/regression/markup-path-fill.ly
@@ -0,0 +1,17 @@
+\version "2.13.31"
+
+\header {
+ texidoc = "
+The @code{\\path} markup command supports the @code{filled}
+property to toggle its fill.
+"
+}
+
+\markup {
+ \override #'(filled . #t) {
+ \path #0.2 #'((moveto 1 1)
+ (lineto 1 6)
+ (curveto 3 8 5 6 1 1)
+ (closepath))
+ }
+}
diff --git a/input/regression/markup-path-linecap.ly b/input/regression/markup-path-linecap.ly
new file mode 100644
index 0000000000..7ed4e62eca
--- /dev/null
+++ b/input/regression/markup-path-linecap.ly
@@ -0,0 +1,26 @@
+\version "2.13.31"
+
+\header {
+ texidoc = "
+The @code{\\path} markup command supports the
+@code{line-cap-style} property with values of @code{butt},
+@code{round}, and @code{square}.
+"
+}
+
+myPath =
+#'((moveto 0 0) (lineto 5 0))
+
+\markup {
+ \column {
+ \override #'(line-cap-style . butt) {
+ \path #1 #myPath
+ }
+ \override #'(line-cap-style . round) {
+ \path #1 #myPath
+ }
+ \override #'(line-cap-style . square) {
+ \path #1 #myPath
+ }
+ }
+}
diff --git a/input/regression/markup-path-linejoin.ly b/input/regression/markup-path-linejoin.ly
new file mode 100644
index 0000000000..f11879f872
--- /dev/null
+++ b/input/regression/markup-path-linejoin.ly
@@ -0,0 +1,27 @@
+\version "2.13.31"
+
+\header {
+ texidoc = "
+The @code{\\path} markup command supports the
+@code{line-join-style} property with values of @code{bevel},
+@code{round}, and @code{miter}.
+"
+}
+
+myPath =
+#'((moveto 0 0) (rlineto 2 5) (rlineto 2 -5))
+
+\markup {
+ \column {
+ \null
+ \override #'(line-join-style . bevel) {
+ \path #1 #myPath
+ }
+ \override #'(line-join-style . round) {
+ \path #1 #myPath
+ }
+ \override #'(line-join-style . miter) {
+ \path #1 #myPath
+ }
+ }
+}
diff --git a/input/regression/markup-path.ly b/input/regression/markup-path.ly
new file mode 100644
index 0000000000..deedf54a13
--- /dev/null
+++ b/input/regression/markup-path.ly
@@ -0,0 +1,23 @@
+\version "2.13.31"
+
+\header {
+ texidoc = "
+The @code{\\path} markup command allows the user to draw
+arbitrary paths using a simple syntax. The two paths below
+should be identical.
+"
+}
+
+\markup {
+ \column {
+ \path #0.2 #'((moveto 1 1)
+ (lineto 1 6)
+ (curveto 3 8 5 6 1 1)
+ (closepath))
+
+ \path #0.2 #'((rmoveto 1 1)
+ (rlineto 0 5)
+ (rcurveto 2 2 4 0 0 -5)
+ (closepath))
+ }
+}