[Qgis-developer] making QgsMapToolIdentify available to plugins

Nathan Woodrow madmanwoo at gmail.com
Tue Jan 22 00:02:41 PST 2013


Hey Denis,

Yeah it's a bit of a pain.  I starting to move it a while ago and then lost
motivation as the code was really coupled.

The second option is the best if you can afford to fund it or spend time on
it :)

- Nathan


On Tue, Jan 22, 2013 at 5:13 PM, Denis Rouzaud <denis.rouzaud at gmail.com>wrote:

>  Hi all,
>
> Following my previous mail, I am trying to make the identify map tool
> available to plugins.
>
> With Matthias Kuhn's help, I've found two ways to achieve this:
>
> - Move QgsMapToolIdentify::identifyVectorLayer and identfiyRasterLayer to
> mapCanvas
>
> - Move QgsMapToolIdentify to gui, and inherits it in
> QgsMapToolIdentifyAction (or whatever) in app.
>
> As far as I understand it, it will be more complicated for the second
> option because app vs non-app code is deeply coupled in the current
> QgsMapToolIdentify. Indeed, features are added one by one to
> QgsIdentifyResults which is a dialog.
>
> But this second option would be much more powerful: the user could
> override the QGIS setting for identify mode (current layer, top-down,...)
> which is used in the canvasReleaseEvent or he could filter the type of
> layer... And he would not have to rewrite the canvasReleaseEvent.
>
> I might have missed something, but, I think this would be a great addition
> for plugin-devs.
> And before going further, I'd like to know experts' opinions and ideas.
>
> Greetings,
>
> Denis
>
> _______________________________________________
> Qgis-developer mailing list
> Qgis-developer at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-developer
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20130122/ab3b19c6/attachment.html>


More information about the Qgis-developer mailing list