Skip to content
Permalink
Browse files

pal: don't convert distance from feature, leave it up to caller to sp…

…ecify exact distance

git-svn-id: http://svn.osgeo.org/qgis/branches/symbology-ng-branch@11020 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
wonder
wonder committed Jul 4, 2009
1 parent 0a6dfa1 commit dfd7490ab7f5648b50af68147fe17a265a3a0a72
Showing with 9 additions and 9 deletions.
  1. +4 −4 src/core/pal/feature.cpp
  2. +1 −1 src/core/pal/feature.h
  3. +2 −2 src/core/pal/layer.cpp
  4. +2 −2 src/core/pal/layer.h
@@ -189,10 +189,10 @@ namespace pal
//if (nbp==2)
// beta = M_PI/2;

double distlabel = unit_convert( this->distlabel,
/*double distlabel = unit_convert( this->distlabel,
pal::PIXEL,
layer->pal->map_unit,
dpi, scale, delta_width );
dpi, scale, delta_width );*/

double lx, ly; /* label pos */

@@ -335,10 +335,10 @@ namespace pal
dpi, scale, delta_width );


double distlabel = unit_convert( this->distlabel,
/*double distlabel = unit_convert( this->distlabel,
pal::PIXEL,
layer->pal->map_unit,
dpi, scale, delta_width );
dpi, scale, delta_width );*/


double *d; // segments lengths distance bw pt[i] && pt[i+1]
@@ -84,7 +84,7 @@ namespace pal
char *uid;
Layer *layer;

int distlabel;
double distlabel;

GEOSGeometry *the_geom;
int currentAccess;
@@ -422,7 +422,7 @@ Cell<Feature*>* Layer::getFeatureIt( const char * geom_id )
return NULL;
}

void Layer::setFeatureDistlabel( const char * geom_id, int distlabel )
void Layer::setFeatureDistlabel( const char * geom_id, double distlabel )
{
int i;

@@ -459,7 +459,7 @@ void Layer::setFeatureDistlabel( const char * geom_id, int distlabel )
}


int Layer::getFeatureDistlabel( const char *geom_id )
double Layer::getFeatureDistlabel( const char *geom_id )
{
modMutex->lock();
Cell<Feature*>* it = getFeatureIt( geom_id );
@@ -326,7 +326,7 @@ namespace pal
* @throws PalException::UnknownFeature
* @throws PalException::ValueNotInRange
*/
void setFeatureDistlabel( const char *geom_id, int distlabel );
void setFeatureDistlabel( const char *geom_id, double distlabel );

/**
* \brief get the symbol size (pixel) for a specific feature
@@ -336,7 +336,7 @@ namespace pal
*
* @throws PalException::UnknownFeature
*/
int getFeatureDistlabel( const char *geom_id );
double getFeatureDistlabel( const char *geom_id );

};

0 comments on commit dfd7490

Please sign in to comment.
You can’t perform that action at this time.