[Qgis-developer] Using api to move features
    Marco Gomes 
    marco.gomes at edisoft.pt
       
    Fri Jun 14 03:34:57 PDT 2013
    
    
  
I am trying to move features in a Qt timer without success. What it is
missing?
 
Below all my trials to make this work.  
 
 
//pointMarkersLayer->dataProvider()->changeGeometryValues(geomMap);
       //pointMarkersLayer->updateFeature(featureRoute_p);
                    
 
       //pointMarkersLayer->changeGeometry(featureRoute_p.id(),
geometry);
       //pointMarkersLayer->moveVertex(finalPoint.x(), finalPoint.y(),
featureRoute_p.id(), 0);
 
       //pointMarkersLayer->changeGeometry(featureRoute_p.id(),
geometry);
       //pointMarkersLayer->updateFeature(featureRoute_p);
       //categorizedSymbolRendererV2->renderFeature(featureRoute_p,
QgsRenderContext(), pointMarkersLayer->id().toInt(), false, false);
 
       //pointMarkersLayer->startEditing();
       //pointMarkersLayer->select(featureRoute_p.id(), false);
 
       //featureRoute_p.setGeometry(QgsGeometry::fromPoint(finalPoint));
       //pointMarkersLayer->updateFeature(featureRoute_p);
 
       //float dx = finalPoint.x() -
featureRoute_p.geometry()->asPoint().x();
       //float dy = finalPoint.y() -
featureRoute_p.geometry()->asPoint().y();
 
       //pointMarkersLayer->translateFeature(featureRoute_p.id(), dx,
dy);
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20130614/90de5d3e/attachment.html>
    
    
More information about the Qgis-developer
mailing list