Mercurial > hg > svgui
diff 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 |
line wrap: on
line diff
--- a/view/View.cpp Fri Oct 08 13:30:52 2010 +0100 +++ b/view/View.cpp Wed Oct 13 15:00:28 2010 +0100 @@ -2276,21 +2276,23 @@ for (LayerList::iterator i = m_layers.begin(); i != m_layers.end(); ++i) { - - paint.setRenderHint(QPainter::Antialiasing, false); - - paint.save(); - paint.translate(xorigin + x, 0); - - std::cerr << "Centre frame now: " << m_centreFrame << " drawing to " << chunk.x() + x + xorigin << ", " << chunk.width() << std::endl; - - (*i)->setSynchronousPainting(true); - - (*i)->paint(this, paint, chunk); - - (*i)->setSynchronousPainting(false); - - paint.restore(); + if(!((*i)->isLayerDormant(this))){ + + paint.setRenderHint(QPainter::Antialiasing, false); + + paint.save(); + paint.translate(xorigin + x, 0); + + std::cerr << "Centre frame now: " << m_centreFrame << " drawing to " << chunk.x() + x + xorigin << ", " << chunk.width() << std::endl; + + (*i)->setSynchronousPainting(true); + + (*i)->paint(this, paint, chunk); + + (*i)->setSynchronousPainting(false); + + paint.restore(); + } } }