racket/collects/scribblings/gui/widget-gallery.rkt
Diogo F. S. Ramos 54ab1bfbfa Add a Widget Gallery to Racket GUI documentation
It's very helpful to have a visual aid when dealing with a graphical
interface toolkit.

This patch adds an overview of the widgets available in the library
consisting of screen shots of the main ones and the snippets used to
produce them.

Each widget image link back to the full documentation.
2012-09-18 14:17:36 -04:00

19 lines
612 B
Racket

(module widget scheme/base
(require racket/string
"common.rkt")
(provide showcase-widget)
(define-syntax showcase-widget
(syntax-rules ()
((_ widget code ...)
(begin
(racketlink widget
(image #:suffixes
(list ".png")
(string-append "image/"
(string-trim (symbol->string 'widget)
"%"
#:left? #f))))
(racketblock code ...))))))