[Qgis-developer] WG: Re: some trouble with pointers in my c++-plugin
SSchmidt at gfi-gis.de
SSchmidt at gfi-gis.de
Wed Dec 11 23:39:49 PST 2013
Freundliche Grüße aus Leipzig
Susann Schmidt
Softwareentwicklung
**************************************************************
GFI - Gesellschaft für Informationstechnologie mbH
Philipp-Rosenthal-Straße 9
D-04103 Leipzig
Geschäftsführer: Andreas Richter
Amtsgericht Leipzig HRB 12054
USt.-IdNr.: DE179049354 Steuer-Nr.: 231/109/06412
ESRI Solution Partner und ER Mapper Reseller
Tel. 0341 961 3310 Fax 0341 961 3311 Mail info at gfi-gis.de
Web www.gfi-gis.de und www.themenbrowser.de
----- Forwarded by Susann Schmidt/gfi on 12.12.2013 08:39 -----
Susann Schmidt/gfi
12.12.2013 08:27
To
mmekuria <sailmcm at yahoo.com>
cc
Subject
Re: [Qgis-developer] some trouble with pointers in my c++-plugin
Thank you for your reply,
i tried this but in the first case QGis crashes on refreshing. What do I
wrong? It seems to be so easy...
QgsPoint pt;
double myX=440000.0;//(*adress->X);
double myY=570000.0;//(*adress->Y);
if (adress->geom==0)
{
//pt=QgsPoint(myX,myY);
pt=QgsPoint(440000.0,570000.0);
qDebug()<<"Geom is null"<<"X="
<<QString::number(pt.x())<<"Y="<<QString::number(pt.y());
}
else
{
pt = adress->geom->asPoint();
qDebug()<<"Geom is valid"<<"X="
<<QString::number(pt.x())<<"Y="<<QString::number(pt.y());
}
QgsRectangle extent( pt.x() - 50.0, pt.y() - 50.0, pt.x()
+ 50.0, pt.y() + 50.0);
mQGisIface->mapCanvas()->setExtent(extent);
mQGisIface->mapCanvas()->refresh();
Freundliche Grüße aus Leipzig
Susann Schmidt
mmekuria <sailmcm at yahoo.com>
Sent by: qgis-developer-bounces at lists.osgeo.org
11.12.2013 08:23
To
qgis-developer at lists.osgeo.org
cc
Subject
Re: [Qgis-developer] some trouble with pointers in my c++-plugin
I think you need to use a reference instead of a pointer as the argument.
-----
Maaza Christos, PhD
www.Axumcorp.com
--
View this message in context:
http://osgeo-org.1560.x6.nabble.com/some-trouble-with-pointers-in-my-c-plugin-tp5093507p5093700.html
Sent from the Quantum GIS - Developer mailing list archive at Nabble.com.
_______________________________________________
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/20131212/67c2a169/attachment.html>
More information about the Qgis-developer
mailing list