From 148498f8405751eca5a23905ca248c8f33b4a6ca Mon Sep 17 00:00:00 2001 From: Matthias Koefferlein Date: Sat, 26 Apr 2025 16:15:25 +0200 Subject: [PATCH] Fixing issue #2026 (after 2.5D display main 2D layout does not display anymore with visible shapes) --- .../view_25d/lay_plugin/layD25ViewWidget.cc | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/plugins/tools/view_25d/lay_plugin/layD25ViewWidget.cc b/src/plugins/tools/view_25d/lay_plugin/layD25ViewWidget.cc index b3b0a0e31..7a29a7ff0 100644 --- a/src/plugins/tools/view_25d/lay_plugin/layD25ViewWidget.cc +++ b/src/plugins/tools/view_25d/lay_plugin/layD25ViewWidget.cc @@ -661,15 +661,15 @@ D25ViewWidget::enter (const db::RecursiveShapeIterator *iter, double zstart, dou void D25ViewWidget::entry (const db::Region &data, double dbu, double zstart, double zstop) { - // try to establish a default color from the region's origin if required - const db::RecursiveShapeIterator *iter = 0; const db::OriginalLayerRegion *original = dynamic_cast (data.delegate ()); if (original) { - iter = original->iter (); + // try to establish a default color from the region's origin if required + auto it = original->begin_iter (); + enter (&it.first, zstart, zstop); + } else { + enter (0, zstart, zstop); } - enter (iter, zstart, zstop); - tl::AbsoluteProgress progress (tl::to_string (tr ("Rendering ..."))); render_region (progress, *m_layers.back ().vertex_chunk, *m_layers.back ().normals_chunk, *m_layers.back ().line_chunk, data, dbu, db::CplxTrans (dbu).inverted () * m_bbox, zstart, zstop); } @@ -677,15 +677,15 @@ D25ViewWidget::entry (const db::Region &data, double dbu, double zstart, double void D25ViewWidget::entry (const db::Edges &data, double dbu, double zstart, double zstop) { - // try to establish a default color from the region's origin if required - const db::RecursiveShapeIterator *iter = 0; const db::OriginalLayerEdges *original = dynamic_cast (data.delegate ()); if (original) { - iter = original->iter (); + // try to establish a default color from the region's origin if required + auto it = original->begin_iter (); + enter (&it.first, zstart, zstop); + } else { + enter (0, zstart, zstop); } - enter (iter, zstart, zstop); - tl::AbsoluteProgress progress (tl::to_string (tr ("Rendering ..."))); render_edges (progress, *m_layers.back ().vertex_chunk, *m_layers.back ().normals_chunk, *m_layers.back ().line_chunk, data, dbu, db::CplxTrans (dbu).inverted () * m_bbox, zstart, zstop); } @@ -693,15 +693,15 @@ D25ViewWidget::entry (const db::Edges &data, double dbu, double zstart, double z void D25ViewWidget::entry (const db::EdgePairs &data, double dbu, double zstart, double zstop) { - // try to establish a default color from the region's origin if required - const db::RecursiveShapeIterator *iter = 0; const db::OriginalLayerEdgePairs *original = dynamic_cast (data.delegate ()); if (original) { - iter = original->iter (); + // try to establish a default color from the region's origin if required + auto it = original->begin_iter (); + enter (&it.first, zstart, zstop); + } else { + enter (0, zstart, zstop); } - enter (iter, zstart, zstop); - tl::AbsoluteProgress progress (tl::to_string (tr ("Rendering ..."))); render_edge_pairs (progress, *m_layers.back ().vertex_chunk, *m_layers.back ().normals_chunk, *m_layers.back ().line_chunk, data, dbu, db::CplxTrans (dbu).inverted () * m_bbox, zstart, zstop); }