[Qgis-developer] obtain QgisApplication instance reference inside python plugin?

G. Allegri giohappy at gmail.com
Tue Apr 3 09:19:07 EDT 2012


Thanks to Jurgen's suggestion I've been able to connect the application
instance signals through QCoreApplication.instance().

giovanni

2012/4/3 G. Allegri <giohappy at gmail.com>

> Yes, the static methods let me access informations, but now I'm quite dure
> (having searched the source code) that the application instance is kept
> "hided" to plugins, probably to avoid interferences (especially from
> bugous plugins!).
>
> giovanni
>
>
> 2012/4/3 ASAHI Kosuke <asahi at hcc.co.jp>
>
>> Hi Giovanni.
>>
>> If you want to get some information from QgisApplication, just type like
>> "QgsApplication.showSettings()**".
>> But I'm not sure you can control some aspects of the application....
>>
>>
>> (2012/04/03 17:19), G. Allegri wrote:
>>
>>> Is there a way to reach the QgisApplication reference from a python
>>> plugin? The iface object is exposed by the application object, but afaik
>>> it doesn't expose it.
>>> I need to control some aspects of the application lifecycle, but I fear
>>> the plugin system is designed to not allow it...
>>>
>>> giovanni
>>>
>>>
>>> ______________________________**_________________
>>> Qgis-developer mailing list
>>> Qgis-developer at lists.osgeo.org
>>> http://lists.osgeo.org/**mailman/listinfo/qgis-**developer<http://lists.osgeo.org/mailman/listinfo/qgis-developer>
>>>
>>
>> --
>> ASAHI Kosuke
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/qgis-developer/attachments/20120403/74cc1066/attachment.html


More information about the Qgis-developer mailing list