KDE/kdevplatform/plugins/quickopen

Andreas Pakulat apaku at gmx.de
Thu Mar 19 13:39:38 UTC 2009


On 19.03.09 14:20:52, David Nolden wrote:
> Am Donnerstag 19 März 2009 14:00:03 schrieb Andreas Pakulat:
> > Can someone with some insight into the expandingtree widget please fix that
> > one up so it provides a proper sizeHint? This change is nothing but a
> > workaround for a bug in expandingtree, which simply has a far too small
> > sizehint.
> It is nothing more than a QTreeView. And QTreeViews are not good at providing 
> size-hints if they have thousands of items in them(At least unfeasably 
> inefficient). Also we don't want the quickopen widget to be as wide as the 
> widest entry, since that will be _very_ wide. So we should just pick a 
> reasonable default.

Then maybe it should override sizeHint and provide a meaningful value? As
it is this widget doesn't comply with Qt standards (meaning every widget
should provide a reasonable sizeHint).

Also why is there this huge whitespace area in the quickopen list on the
left of the entries? The first column should be a lot smaller in the
quickopen list, then we wouldn't even need a reasonable default size for
the dialog or the tree.

> Actually it did have a very reasonable default size, but maybe that got lost 
> during the conversion to KDialog(Which I wasn't a fan of, for exactly such 
> reasons)

You'd have the same problem if you'd use the form that we have now, apply
it onto a QWidget and put it into a QDialog with a layout. The reason it
worked with QDialog is that when you resize it inside designer a resize()
call is added to the generated code. So every time someone would resize the
dialog in designer and save that we'd have a different size on next start,
how good is that?

Oh and btw, 800x400 is _not_ a reasonable size, it spans the whole screen
on small laptops or monitors. Something like 550x350 seems a lot more
reasonable.

Andreas

-- 
You'll never see all the places, or read all the books, but fortunately,
they're not all recommended.




More information about the KDevelop-devel mailing list