diff --git a/draw.cpp b/draw.cpp index 0602c99..0b69870 100644 --- a/draw.cpp +++ b/draw.cpp @@ -648,14 +648,6 @@ void GraphicsWindow::Paint(int w, int h) { nogrid:; } - // Draw filled paths in all groups, when those filled paths were requested - // specially by assigning a style with a fill color. - Group *g; - for(g = SK.group.First(); g; g = SK.group.NextAfter(g)) { - if(!(g->IsVisible())) continue; - g->DrawFilledPaths(); - } - // Draw the active group; this does stuff like the mesh and edges. (SK.GetGroup(activeGroup))->Draw(); @@ -663,6 +655,17 @@ nogrid:; if(showHdnLines) glDisable(GL_DEPTH_TEST); Entity::DrawAll(); + // Draw filled paths in all groups, when those filled paths were requested + // specially by assigning a style with a fill color, or when the filled + // paths are just being filled by default. This should go last, to make + // the transparency work. + Group *g; + for(g = SK.group.First(); g; g = SK.group.NextAfter(g)) { + if(!(g->IsVisible())) continue; + g->DrawFilledPaths(); + } + + glDisable(GL_DEPTH_TEST); // Draw the constraints for(i = 0; i < SK.constraint.n; i++) {