[PyQt] QGraphicsItem missing method
phil at riverbankcomputing.com
Sat Apr 17 19:44:40 BST 2010
On Sat, 17 Apr 2010 12:27:51 -0600 (MDT), buddy+pyqt at nmt.edu wrote:
> I recently updated from 4.7 to 4.7.3 and suddenly the QGraphicsItem class
> no longer
> seems to have a setOpacity method. The documentation still indicated
> should be
> a valid method. In addition I noticed that the
> attribute is also missing from the QGraphicsItem class.
> Attached is some test code I have featuring has a class called CustomItem
> inherits from QGraphicsItem and attempts to call setOpacity in it's
> When I run it I get the following errror:
> Traceback (most recent call last):
> File "./test.py", line 63, in <module>
> File "./test.py", line 13, in __init__
> AttributeError: 'CustomItem' object has no attribute 'setOpacity'
> Please let me know if I somehow have a bad installation or if there's
> something I
> can do to fix this.
Works fine for me.
Make sure you aren't using an older version of Qt.
More information about the PyQt