tempG.fillRect(0, 0, getWidth(), getHeight());
for (int i = layers.size() - 1; i >= 0; --i) {
Layer l = layers.get(i);
if (l.visible/* && l != getActiveLayer() */)
l.paint(tempG, this);
}
/*
* if (getActiveLayer() != null && getActiveLayer().visible)
* getActiveLayer().paint(tempG, this);