[PyKDE] Re: pyuic and Access to QGridLayout
Andreas Pakulat
apaku at gmx.de
Fri Feb 3 13:15:09 GMT 2006
On 03.02.06 00:05:21, Chad Brantly wrote:
> >>My next thought was that I would access the layout widget by name using:
> >>
> >> self.group_box.layout().child('mygridlayout')
> >?? group_box.layout() gives you exactly the layout instance you want.
>
> Doesn't really return the same object. self.group_box.layout() returns a
> QVBoxLayout instead of QGridLayout.
>
> This is the code that pyuic creates. I need to access group_boxLayout later on
> in my code.
>
> self.group_box=QGroupBox(self.SampleBrowserTab,"group_box")
> self.group_box.setColumnLayout(0,Qt.Vertical)
> group_boxLayout=QGridLayout(self.group_box.layout())
>
> Any ideas?
Huh? Oh, I thought you were talking about PyQt4, but the code above is
from PyQt3...
Hmm, I think this is a bug in pyuic, it should
a) preserve the name of the layout
b) create the GridLayout with the groupbox as parent, effectivly setting
the layout for the groupbox.
Please report to Phil directly so he can fix pyuic.
Andreas
--
You will be married within a year.
More information about the PyQt
mailing list