[Qt-qml] Rounded Corner Clipping Support in Rectangle

Adriano Rezende adriano.rezende at openbossa.org
Thu Feb 3 13:09:06 CET 2011


On Tue, Feb 1, 2011 at 8:04 PM,  <Bill.Bonney at nokia.com> wrote:
> Hello,
>
>
>
> Why can we not support rounded corners in Image element with clipping on. I
> realize it’s a performance hit, but if the image doesn’t change width and
> height the impact to animations could be minimal. It would be useful for
> some layouts we would like to achieve.

Currently you can achieve this creating a C++ element with a
QGraphicsEffect applied.
There is an element in qt-components called MaskedItem that does what
you want, but it's a little borderline (attached is the source code).

Br,
Adriano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mdeclarativemaskeditem.h
Type: text/x-chdr
Size: 1854 bytes
Desc: not available
Url : http://lists.qt.nokia.com/pipermail/qt-qml/attachments/20110203/75a1b60d/attachment.bin 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mdeclarativemaskeditem.cpp
Type: text/x-c++src
Size: 6321 bytes
Desc: not available
Url : http://lists.qt.nokia.com/pipermail/qt-qml/attachments/20110203/75a1b60d/attachment-0001.bin 


More information about the Qt-qml mailing list