[racket] regulating buttons

From: 김태윤 (kty1104 at gmail.com)
Date: Wed Nov 10 08:59:19 EST 2010

;hello
;is there any option that make it able to wrap the buttons(as like word
wrap) if set of buttons' width is larger than pane's width?
;I mean, I want to place 3 buttons in a row. so make it to two lines
;but this code not be able to make two lines but only one

#lang racket/gui
(define f (new frame% (label "1")))
(define hp (new horizontal-pane% (parent f) (min-width 50)
(stretchable-width #t)))
(define btn1 (new button% (label "btn1") (parent hp)))
(define btn2 (new button% (label "btn2") (parent hp)))
(define btn3 (new button% (label "btn3") (parent hp)))
(define btn4 (new button% (label "btn4") (parent hp)))
(define btn5 (new button% (label "btn5") (parent hp)))
(define btn6 (new button% (label "btn6") (parent hp)))

(send f show #t)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20101110/a38495a3/attachment.html>

Posted on the users mailing list.