[racket] Racket/gui : How to rotate a bitmap% ?
Ok, I don't understand what you want then. I tried the code below and
it did what I expect.
N.
racket@> (define (display-bitmap bitmap)
(define f
(new frame%
[label "Bitmap"]
[width (send bitmap get-width)]
[height (send bitmap get-height)]))
(define c (new canvas%
[parent f]
[paint-callback
(lambda (canvas dc)
(send dc translate 10 10)
(send dc rotate .1)
(send dc draw-bitmap bitmap 0 0))]))
(send f show #t)
f)
racket@> (define texture
(make-object bitmap%
"cauliflower.jpg"
'jpeg))
racket@> (display-bitmap texture)
2011/5/10 Jyu 。 <julien-0659 at hotmail.fr>:
> @noelWelsh : I tested your advice, but it not run.. I tested to rotate and
> translate then : The bitmap is turn around another point..
> I test to translate and rotate then, the result is the same. Thanks you
> anyway.