[Qt-jambi-interest] Customizing QFileDialog
Eskil Abrahamsen Blomfeldt
eblomfel at trolltech.com
Fri May 2 14:41:05 CEST 2008
Bartko, Zoltan wrote:
> is there any way of customizing QFileDialog? I have seen the following in
> a swing app: the file open dialog was used in directory selection mode.
> The directories were searched for specific files - if a certain file has
> been found in the directory, a custom directory icon was displayed,
> allowing only these special directories to be selected.
>
> Is it possible to do anything like this with Qt/Jambi with QFileDialog or
> do I have to code my own dialog?
>
You might be able to use a proxy model on your file dialog:
http://doc.trolltech.com/qtjambi-4.4.0_01/doc/html/com/trolltech/qt/gui/QFileDialog.html#setProxyModel(com.trolltech.qt.gui.QAbstractProxyModel)
This should let you filter out directories that you do not wish to
include as well as provide them with special decorations etc.
-- Eskil
More information about the Qt-jambi-interest
mailing list