Skip to content
Permalink
Browse files
Misc. tidy ups of debugging output - make some output only happen when
in debug mode.

Disable updating the progress bar as it doesn't currently work and
just serves to produce a confusing error message from Qt


git-svn-id: http://svn.osgeo.org/qgis/trunk@5456 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
g_j_m committed May 15, 2006
1 parent d0c086c commit 989dfabdab1292e3d5b2eddf184ef57a7472989f
Showing with 14 additions and 18 deletions.
  1. +1 −1 src/gui/qgisapp.cpp
  2. +12 −15 src/gui/qgscoordinatetransform.cpp
  3. +1 −1 src/gui/qgsmaprender.cpp
  4. +0 −1 src/providers/grass/qgsgrass.cpp
@@ -3135,7 +3135,7 @@ void QgisApp::exportMapServer()
}
void QgisApp::zoomIn()
{
qDebug ("Setting map tool to zoomIn");
QgsDebugMsg ("Setting map tool to zoomIn");

QgsMapTool* tool = new QgsMapToolZoom(mMapCanvas, FALSE /* zoomOut */);
tool->setAction(mActionZoomIn);
@@ -21,8 +21,6 @@
//qt includes
#include <QDomNode>
#include <QDomElement>

// Qt4-only includes to go here
#include <QTextOStream>
#include <QApplication>

@@ -167,22 +165,21 @@ void QgsCoordinateTransform::initialise()

if (mInitialisedFlag)
{

std::cout << "------------------------------------------------------------"<< std::endl;
std::cout << "QgsCoordinateTransform::initialise()" << std::endl;
std::cout << "The OGR Coordinate transformation for this layer was set to" << std::endl;
// note overloaded << operator on qgsspatialrefsys cant be used on pointers -
// so we dereference them like this (*mSourceSRS) (Thanks Lars for pointing that out)
std::cout << "INPUT: " << std::endl << mSourceSRS << std::endl;
std::cout << "OUTPUT: " << std::endl << mDestSRS << std::endl;
std::cout << "------------------------------------------------------------" << std::endl;
#ifdef QGISDEBUG
std::cout << "------------------------------------------------------------\n"
<< "QgsCoordinateTransform::initialise()\n"
<< "The OGR Coordinate transformation for this layer was set to\n"
<< "INPUT: \n" << mSourceSRS << '\n'
<< "OUTPUT: \n" << mDestSRS << '\n'
<< "------------------------------------------------------------\n";
}
else
{
std::cout << "------------------------------------------------------------"<< std::endl;
std::cout << "QgsCoordinateTransform::initialise()" << std::endl;
std::cout << "The OGR Coordinate transformation FAILED TO INITIALISE!" << std::endl;
std::cout << "------------------------------------------------------------"<< std::endl;
std::cout<< "------------------------------------------------------------\n"
<< "QgsCoordinateTransform::initialise()\n"
<< "The OGR Coordinate transformation FAILED TO INITIALISE!\n"
<< "------------------------------------------------------------\n";
#endif
}
}

@@ -218,7 +218,7 @@ void QgsMapRender::render(QPainter* painter)
// added these comments and debug statement to help others...
QgsDebugMsg("If there is a QPaintEngine error here, it is caused by an emit call");

emit setProgress(myRenderCounter++,layers.size());
//emit setProgress(myRenderCounter++,layers.size());
QgsMapLayer *ml = QgsMapLayerRegistry::instance()->mapLayer(*li);

if (!ml)
@@ -80,7 +80,6 @@ void QgsGrass::init( void )
// or when set explicitly by the user.
// This value should always take precedence.
QString gisBase = getenv("GISBASE");
std::cerr << "gisBase = " << gisBase.toLocal8Bit().data() << std::endl;
#ifdef QGISDEBUG
qDebug( "%s:%d GRASS gisBase from GISBASE env var is: %s", __FILE__, __LINE__, (const char*)gisBase );
#endif

0 comments on commit 989dfab

Please sign in to comment.