[mcclim-devel] :clipping-region woes

Robert Uhl eadmund42 at gmail.com
Wed Jul 8 15:01:26 UTC 2009


Sumant Oemrawsingh <soemraws at xs4all.nl> writes:
>
> In the clim-listener, in the package clim-user, I do the following:
>
> (with-room-for-graphics (t)
>   (draw-rectangle* *standard-output* -10 -10 10 10))
>
> This gives a black, filled rectangle. Great, just as expected. Now, I want to
> try to define a clipping region:
>
> (with-room-for-graphics (t)
>   (draw-rectangle* *standard-output* -10 -10 10 10
>                    :clipping-region (make-rectangle* -5 -5 5 5)))
>
> What I expect is that it displays a smaller rectangle, namely the rectangle
> with side 20 clipped down to a side of 10. However, I don't see anything.
>
> So, I try the following:
>
> (with-room-for-graphics (t)
>   (draw-rectangle* *standard-output* -10 -10 10 10
>                    :clipping-region (make-rectangle* -20 -20 20 20)))
>
> Since the clipping region is _larger_ than the actual drawing, I expect to see
> the same as in the first sexp, where I didn't define any clipping region.
> Nevertheless, I see... NOTHING!
>
> Is this a bug, a feature, or am I hopelessly ignorant and should just give up
> ever trying to do anything remotely complicated in clim?

Sorry for the huge quote, but I thought some context would be good.
Looking at <http://www.mikemac.com/mikemac/clim/drawing-options.html>,
it sounds like you're doing the right thing: RECTANGLE is a subclass of
POLYGON which is a subclass of AREA, and that's what :CLIPPING-REGION
expects.

So I suspect it's a bug or unimplemented feature.

-- 
Robert Uhl <http://public.xdi.org/=ruhl>
It's all a conspiracy.  A conspiracy by us elites to shut people out
by giving away all our code under open source licenses.
 --Peter Samuelson in comp.os.linux.development.system




More information about the mcclim-devel mailing list