Hi Nyall, Thanks a lot. I've been playing (for a long moment) with masterLayout and openLayoutDesigner, trying different combinations but I just overlooked the plural form. Works like a charm.
Harrissou 2018-05-23 5:39 GMT+02:00 Nyall Dawson <[email protected]>: > On 22 May 2018 at 23:54, DelazJ <[email protected]> wrote: > > Hi, > > > > From the Python Console, how can I close a print layout dialog, knowing > its > > name? > > In 3.0 something like this will work: > > designers = [d for d in iface.openLayoutDesigners() if > d.masterLayout().name() == 'Layout 1'] > if designers: > designers[0].close() > > Nyall > > > > > > > Thanks for any hint, > > Harrissou > > > > _______________________________________________ > > Qgis-user mailing list > > [email protected] > > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user > > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user >
_______________________________________________ Qgis-user mailing list [email protected] List info: https://lists.osgeo.org/mailman/listinfo/qgis-user Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
