update 'info' tool to work with new feature impl
This commit is contained in:
parent
946667948f
commit
aa1976c824
1 changed files with 13 additions and 14 deletions
|
@ -29,6 +29,7 @@
|
||||||
#include <mapnik/scale_denominator.hpp>
|
#include <mapnik/scale_denominator.hpp>
|
||||||
#include <mapnik/ctrans.hpp>
|
#include <mapnik/ctrans.hpp>
|
||||||
#include <mapnik/memory_datasource.hpp>
|
#include <mapnik/memory_datasource.hpp>
|
||||||
|
#include <mapnik/feature_kv_iterator.hpp>
|
||||||
#include "mapwidget.hpp"
|
#include "mapwidget.hpp"
|
||||||
#include "info_dialog.hpp"
|
#include "info_dialog.hpp"
|
||||||
|
|
||||||
|
@ -42,6 +43,7 @@ using mapnik::geometry_ptr;
|
||||||
using mapnik::CoordTransform;
|
using mapnik::CoordTransform;
|
||||||
using mapnik::projection;
|
using mapnik::projection;
|
||||||
using mapnik::scale_denominator;
|
using mapnik::scale_denominator;
|
||||||
|
using mapnik::feature_kv_iterator;
|
||||||
|
|
||||||
double scales [] = {279541132.014,
|
double scales [] = {279541132.014,
|
||||||
139770566.007,
|
139770566.007,
|
||||||
|
@ -170,20 +172,17 @@ void MapWidget::mousePressEvent(QMouseEvent* e)
|
||||||
feature_ptr feat = fs->next();
|
feature_ptr feat = fs->next();
|
||||||
if (feat)
|
if (feat)
|
||||||
{
|
{
|
||||||
// FIXME
|
|
||||||
/*
|
feature_kv_iterator itr(*feat,true);
|
||||||
std::map<std::string,mapnik::value> const& props = feat->props();
|
feature_kv_iterator end(*feat);
|
||||||
std::map<std::string,mapnik::value>::const_iterator itr=props.begin();
|
|
||||||
for (; itr!=props.end();++itr)
|
for ( ;itr!=end; ++itr)
|
||||||
{
|
{
|
||||||
if (itr->second.to_string().length() > 0)
|
info.push_back(QPair<QString,QString>(QString(boost::get<0>(*itr).c_str()),
|
||||||
{
|
boost::get<1>(*itr).to_string().c_str()));
|
||||||
info.push_back(QPair<QString,QString>(QString(itr->first.c_str()),
|
}
|
||||||
itr->second.to_string().c_str()));
|
|
||||||
}
|
typedef mapnik::coord_transform2<mapnik::CoordTransform,mapnik::geometry_type> path_type;
|
||||||
}
|
|
||||||
*/
|
|
||||||
typedef mapnik::coord_transform2<mapnik::CoordTransform,mapnik::geometry_type> path_type;
|
|
||||||
|
|
||||||
for (unsigned i=0; i<feat->num_geometries();++i)
|
for (unsigned i=0; i<feat->num_geometries();++i)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Reference in a new issue