outlined-ellipse

Categories: Image procedures , Shape procedures

Documentation

;;; (outlined-ellipse width height color line-width [description]) -> image?
;;;   width : nonnegative-real?
;;;   height : nonnegative-real?
;;;   color : color?
;;;   line-width : positive-integer?
;;;   description : string?
;;; An ellipse of the specified width and height, outlined with a
;;; line of the specified color and width.

Examples

> (outlined-ellipse 50 20 "blue" 10)
an outlined blue 50-by-20 ellipse
> (outlined-ellipse 20 50 "red" 15)
an outlined red 20-by-50 ellipse

Tests

> (check-true (ellipse? (outlined-ellipse 50 20 "blue" 10)))
> (check-= (image-width (outlined-ellipse 50 20 "blue" 10))
           70
           0.1)
> (check-= (image-height (outlined-ellipse 50 20 "blue" 10))
           40
           0.1)
> (check-equal? (image-color (outlined-ellipse 50 20 "blue" 10))
                (color-name->rgb "blue"))

See also

outlined-circle solid-ellipse

Questions

Forthcoming