racket/gui: adjust label size on some controls

Extra margins added by instantiating `message%' inside
`radio-box%', etc., made labels line up especially badly.
This commit is contained in:
Matthew Flatt 2013-08-20 13:52:32 -06:00
parent ccead82841
commit b24eb311dd
2 changed files with 2 additions and 0 deletions

View File

@ -83,6 +83,7 @@
RacketImageButtonCell)
numberOfRows: #:type _NSInteger (if horiz? 1 (length labels))
numberOfColumns: #:type _NSInteger (if horiz? (length labels) 1)))])
(tellv cocoa setIntercellSpacing: #:type _NSSize (make-NSSize 2 2))
(for ([label (in-list labels)]
[i (in-naturals)])
(let ([button (tell cocoa

View File

@ -42,6 +42,7 @@
(define (make-label label proxy p font)
(and label
(let ([l (make-object wx-message% #f proxy p label -1 -1 null font)])
(send l x-margin 0) (send l y-margin 0)
(send l skip-enter-leave-events #t)
(send l skip-subwindow-events? #t)
l)))