fix text part of label when it goes to the edge (or slightly outside) the bounding box

svn: r1466

original commit: 3e46c52c2c40154027b23dbd549508030b514066
This commit is contained in:
Matthew Flatt 2005-12-01 20:49:45 +00:00
parent 382ee43994
commit 6157ff3fe2

View File

@ -86,10 +86,11 @@
(send bitmap-dc clear)
(send bitmap-dc set-pen (send the-pen-list find-or-create-pen "black" 1 'solid))
(send bitmap-dc set-brush (send the-brush-list find-or-create-brush "black" 'solid))
;; Black rectangle to be masked by text:
(send bitmap-dc draw-rectangle
(+ outside-margin img-width middle-margin)
(- (/ new-height 2) (/ height 2))
width height)
(sub1 (+ outside-margin img-width middle-margin))
0
(add1 width) new-height)
(send bitmap-dc draw-bitmap
img-bitmap
outside-margin