Skip to content
Browse files
Add a little debug output to make clear the source of the QPaintEngine

git-svn-id: c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
g_j_m committed Mar 20, 2006
1 parent be8446b commit a050eebe7a718b8284a27a381de87e8ac2659446
Showing 1 changed file with 9 additions and 0 deletions.
@@ -205,6 +205,15 @@ void QgsMapRender::render(QPainter* painter)
std::cout << "QgsMapRender::render: at layer item '" << (*li).toLocal8Bit().data() << "'." << std::endl;

// This call is supposed to cause the progress bar to
// advance. However, it seems that updating the progress bar is
// incompatible with having a QPainter active (the one that is
// passed into this function), as Qt produces a number of errors
// when try to do so. I'm (Gavin) not sure how to fix this, but
// added these comments and debug statement to help others...
std::cerr << "If there is a QPaintEngine here, it is caused by an emit "
"call just after line " << __LINE__ << " in file " << __FILE__ << ".\n";

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

0 comments on commit a050eeb

Please sign in to comment.