comparison view/View.cpp @ 574:95cf0d0f93af

Ignore hidden layers when exporting image - closes sf.net #3041878. (Commit is originally from my github copy, commit 03a966c7849335a059e7)
author Dan Stowell <dan.stowell@eecs.qmul.ac.uk>
date Wed, 13 Oct 2010 15:00:28 +0100
parents 3f698e237585
children bb1035a24958
comparison
equal deleted inserted replaced
573:462e4f59c261 574:95cf0d0f93af
2274 paint.setPen(getForeground()); 2274 paint.setPen(getForeground());
2275 paint.setBrush(Qt::NoBrush); 2275 paint.setBrush(Qt::NoBrush);
2276 2276
2277 for (LayerList::iterator i = m_layers.begin(); 2277 for (LayerList::iterator i = m_layers.begin();
2278 i != m_layers.end(); ++i) { 2278 i != m_layers.end(); ++i) {
2279 2279 if(!((*i)->isLayerDormant(this))){
2280 paint.setRenderHint(QPainter::Antialiasing, false); 2280
2281 2281 paint.setRenderHint(QPainter::Antialiasing, false);
2282 paint.save(); 2282
2283 paint.translate(xorigin + x, 0); 2283 paint.save();
2284 2284 paint.translate(xorigin + x, 0);
2285 std::cerr << "Centre frame now: " << m_centreFrame << " drawing to " << chunk.x() + x + xorigin << ", " << chunk.width() << std::endl; 2285
2286 2286 std::cerr << "Centre frame now: " << m_centreFrame << " drawing to " << chunk.x() + x + xorigin << ", " << chunk.width() << std::endl;
2287 (*i)->setSynchronousPainting(true); 2287
2288 2288 (*i)->setSynchronousPainting(true);
2289 (*i)->paint(this, paint, chunk); 2289
2290 2290 (*i)->paint(this, paint, chunk);
2291 (*i)->setSynchronousPainting(false); 2291
2292 2292 (*i)->setSynchronousPainting(false);
2293 paint.restore(); 2293
2294 paint.restore();
2295 }
2294 } 2296 }
2295 } 2297 }
2296 2298
2297 m_centreFrame = origCentreFrame; 2299 m_centreFrame = origCentreFrame;
2298 update(); 2300 update();