extenderitem layout problems

Frederik Gladhorn gladhorn at kde.org
Wed Jul 8 19:28:04 CEST 2009


Hi all,
as you probably noticed, the NetworkManager Plasma applet has some layout 
problems.
They are caused by the following setup:
-we add a widget into the ExtenderItem
-QGraphicsGridLayout is added to the widget
-whenever for example a wireless network appears, some widget is added to the 
layout

The layouts in qgraphicsview do not support any signals/slots, so the 
ExtenderItem never gets notified about the layout change.
Possible solutions could be:
-making ExtenderItemPrivate::updateSizeHints() accessible to the outside world 
(I tested this solution and it works fine)
-subclassing the layout class to emit size change signals

I wrote a small test case for this to understand the problem, let me know if 
you are interested, I can send the files or put them somewhere in playground.
Is there any better approach/preferred way to do this?

Greetings,
Frederik



More information about the Plasma-devel mailing list