@@ -634,19 +634,23 @@ std::pair<LayoutViewer::Edge, bool> LayoutViewer::searchNearestEdge(
634634
635635 const bool routing_visible = options_->areRoutingSegmentsVisible ();
636636 const bool vias_visible = options_->areRoutingViasVisible ();
637- if (routing_visible || vias_visible) {
637+ const bool io_pins_visible = options_->areIOPinsVisible ();
638+ if (routing_visible || vias_visible || io_pins_visible) {
638639 auto box_shapes = search_.searchBoxShapes (block_,
639640 layer,
640641 search_line.xMin (),
641642 search_line.yMin (),
642643 search_line.xMax (),
643644 search_line.yMax (),
644645 shape_limit);
645- for (const auto & [box, is_via , net] : box_shapes) {
646- if (!routing_visible && !is_via ) {
646+ for (const auto & [box, type , net] : box_shapes) {
647+ if (!routing_visible && type == Search::WIRE ) {
647648 continue ;
648649 }
649- if (!vias_visible && is_via) {
650+ if (!vias_visible && type == Search::VIA) {
651+ continue ;
652+ }
653+ if (!io_pins_visible && type == Search::BTERM) {
650654 continue ;
651655 }
652656 if (isNetVisible (net)) {
@@ -855,7 +859,8 @@ void LayoutViewer::selectAt(odb::Rect region, std::vector<Selected>& selections)
855859
856860 const bool routing_visible = options_->areRoutingSegmentsVisible ();
857861 const bool vias_visible = options_->areRoutingViasVisible ();
858- if (routing_visible || vias_visible) {
862+ const bool io_pins_visible = options_->areIOPinsVisible ();
863+ if (routing_visible || vias_visible || io_pins_visible) {
859864 auto box_shapes = search_.searchBoxShapes (block_,
860865 layer,
861866 region.xMin (),
@@ -864,11 +869,14 @@ void LayoutViewer::selectAt(odb::Rect region, std::vector<Selected>& selections)
864869 region.yMax (),
865870 shape_limit);
866871
867- for (auto & [box, is_via, net] : box_shapes) {
868- if (!routing_visible && !is_via) {
872+ for (auto & [box, type, net] : box_shapes) {
873+ if (!routing_visible && type == Search::WIRE) {
874+ continue ;
875+ }
876+ if (!vias_visible && type == Search::VIA) {
869877 continue ;
870878 }
871- if (!vias_visible && is_via ) {
879+ if (!io_pins_visible && type == Search::BTERM ) {
872880 continue ;
873881 }
874882 if (isNetVisible (net) && options_->isNetSelectable (net)) {
0 commit comments