(set-fix-rect-position! extent x y)
(drawing-damage ink)))))))
-(define (set-fix-ink-%size! ink width height)
- (let ((extent (fix-ink-extent ink)))
- (without-interrupts
- (lambda ()
- (if (not (and (fix:= width (fix-rect-width extent))
- (fix:= height (fix-rect-height extent))))
- (begin
- (drawing-damage ink)
- (set-fix-rect-size! extent width height)
- (drawing-damage ink)))))))
-
(define (set-fix-ink! ink x y width height)
(let ((extent (fix-ink-extent ink)))
(without-interrupts
(define (image-ink-size-prepared ink)
(named-lambda (image-ink-size-prepared-handler width height)
(%trace ";image-ink-size-prepared-handler "ink" "width" "height"\n")
- (set-fix-ink-%size! ink width height)))
+ (let ((extent (fix-ink-extent ink)))
+ (if (not (and (fix:= width (fix-rect-width extent))
+ (fix:= height (fix-rect-height extent))))
+ (begin
+ (drawing-damage ink)
+ (set-fix-rect-size! extent width height)
+ (drawing-damage ink))))))
(define (image-ink-pixbuf-prepared ink)
(named-lambda (image-ink-pixbuf-prepared-handler pixbuf)
(define (image-ink-pixbuf-updated ink)
(named-lambda (image-ink-pixbuf-updated-handler x y width height)
- (let ((rect (make-fix-rect x y width height)))
+ (let* ((extent (fix-ink-extent ink))
+ (rect (make-fix-rect
+ (fix:+ x (fix-rect-x extent))
+ (fix:+ y (fix-rect-y extent))
+ width height)))
(%trace ";image-ink-pixbuf-updated-handler "ink" "rect"\n")
(drawing-damage ink rect))))