summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2019-05-29 22:36:34 +0200
committerRicardo Wurmus <rekado@elephly.net>2019-05-29 22:36:34 +0200
commitbf25c3964fd2d19d9942968a0e4ee6702c268fb6 (patch)
tree7a44680a0f94f9dc05eebdc99d140e3a75be34ad
parent9e37ecede37cbde048e28162cda5869077bebe11 (diff)
pict: line: Add docstring.
* pict.scm (line): Add docstring.
-rw-r--r--pict.scm6
1 files changed, 6 insertions, 0 deletions
diff --git a/pict.scm b/pict.scm
index 25cc21b..1d421c3 100644
--- a/pict.scm
+++ b/pict.scm
@@ -519,6 +519,12 @@ full transparency) and 1 (for full opacity)."
#:key
(color "black")
(stroke-width 1))
+ "Return a straight line connecting the start point described by the
+numbers X1 and Y1 and the end point described by the numbers X2 and
+Y2. Optionally, the numbers MAXW and MAXH can be provided to set the
+width or height, respectively, of the resulting picture. The keys
+COLOR (a string) and STROKE-WIDTH (a number) are accepted to override
+the line color and line thickness."
(make-pict
`(svg (@ (width ,(max maxw (let ((new-width (+ (min x1 x2)
(abs (- x2 x1)))))