On Wed, 18 Aug 1999, Andrew Richards wrote: (...) > Selections are going to have to be very tricky (probably one of the hardest > things to implement well). I believe a greyscale layer may be the way to go. > Remember that the selection must be able to be feathered (ie it must be > able to have an alpha channel). Also remember that some selection mechanisms > produce very big selections (select by colour for example) and these would > probably be better described by a layer than by a set of vectors. The dynamic > tile allocation of layers should keep small selections small, however, > We could implement a simple selection mechanism now but that would probably > have to be replaced later. Hm, how are you going to render the selection? Animated selections (moving rubber band) are a must as it really helps to see complex selections. How do you propose to make the selection based on a grayscale layer visible? Render the layer into the image? This is to slow for animated selections. My opinion still is that we should go with QRegions to describe the selected area. You can easily draw the polygon described by a QRegion directly on the canvasview widget. You are right a selection area can become rather large/complex and a QRegion to describe the polygon may contain hundrets of points. But IMO the QRegion code is fast enough even with several hundret points. QRegion::contains(const QPoint&) is quite fast, we simply have to test the performance. You can still feather a selection based on a QRegion as only the borders of the selection are feathered. -> A selection is described by the selected area (QRegion) and a feather value. The tools and filters then have to handle the actual feathering. And by the way, please keep in mind that a canvas can have several views and each view can have a active selection. -> The views have to handle the selections, not the document. > I personally believe that we should wait until the canvas code has stabilized > an drawing/layers/brushes have been made to work well. Yes, I second this. :-) -- Matthias Elter me@kde.org / me@main-echo.net KDE developer