Reginald Stadlbauer wrote: > > On Wed, 04 Aug 1999, Leon Widdershoven wrote: > >Reginald Stadlbauer wrote: > >> > >> On Wed, 04 Aug 1999, Stephan Kulow wrote: > >> >Matthias Ettrich wrote: > >> >> > >> >> Hi, > >> >> > >> >> I noticed one slightly annoying thing with KDE-2.0's layout management: very > >> >> few groupboxes get the layout right. > >> >> > >> >> Problem: the very first row often overlaps with the group box text. > >> >> > >> >> Qt-2.0 makes groupbox layouting finally easier. Simply remove all your custom > >> >> layout code for the groupbox and create the groupbox with the new constructor: > >> >> > >> >> > >> >> /*! > >> >> Constructs a group box with a \a title. Child widgets will be arranged > >> >> in \a strips rows or columns (depending on \a orientation). > >> >> > >> >> The \e parent and \e name arguments are passed to the QWidget constructor. > >> >> */ > >> >> > >> >> QGroupBox::QGroupBox( int strips, Orientation orientation, > >> >> const QString &title, QWidget *parent, > >> >> const char *name ) > >> >> > >> >> That's it. Less code in KDE and looks nicer :-) > >> >> > >> >Well, but you can hardly blame KDE programmers. > >> > >> He doesn't blame anyone, it's just a hint :-)) > > > >I hope the good-old > >vbox->addSpacing( this->fontMetrics().height() ); > >does still work... > > You really don't need to set all spacings and stretches with the Qt 2.0 layout > anymore! This should simplify ksnapshot a lot - half of the code is sorting out the geom management for the view. The snapshot code is almost trivial in comparison! Rich. > > -- > Reggie -- Richard Moore rich@ipso-facto.freeserve.co.uk http://www.robocast.com/ richard@robocast.com http://developer.kde.org/ rich@kde.org