On 5/23/20 11:21 AM, Jorge Gustavo Rocha wrote:
> Hi Seggie,
> 
> Just one line of code to add a folder to browser panel:
> 
> iface.browserModel().addFavoriteDirectory('/home/jgr/tmp')

And to add some more context: QGIS is build using Qt widgets, which has
a model/view programming paradigm:

https://doc.qt.io/qt-5/model-view-programming.html

So the 'model' behind the 'browserDockWidget'-view is the QgsBrowserModel:

https://qgis.org/pyqgis/master/core/QgsBrowserModel.html

^^ also have a look there to see what else is possible/needed

Regards,

Richard Duivenvoorde
_______________________________________________
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Reply via email to