From 38b3d53b5f2ce818284b096a265897427c06b49d Mon Sep 17 00:00:00 2001 From: Tim Edwards Date: Sun, 9 Feb 2025 14:51:40 -0500 Subject: [PATCH] Modified the behavior of "select area subcell" so that it no longer requires that subcells be unexpanded in order to select them. This seems to be more in line with what one would expect from the documented description of the "select area" command, and more in line with common-sense expectations. --- select/selCreate.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/select/selCreate.c b/select/selCreate.c index d6a8d308..23c2ebdc 100644 --- a/select/selCreate.c +++ b/select/selCreate.c @@ -473,10 +473,15 @@ SelectArea(scx, types, xMask, globmatch) } else (void) DBCellCopyAllLabels(scx, types, xMask, SelectUse, &labelArea); - /* Select unexpanded cell uses. */ + /* Select cell uses. */ + /* NOTE: Changed 2/9/2025; Previously this was restricted to unexpanded + * cell instances, which is an unnecessary restriction. By changing "xMask" + * to "CU_DESCEND_ALL", this now only ever looks one level down and will + * select any instance that is a child of the edit cell, expanded or not. + */ if (TTMaskHasType(types, L_CELL)) - (void) DBCellCopyAllCells(scx, xMask, SelectUse, &cellArea); + (void) DBCellCopyAllCells(scx, CU_DESCEND_ALL, SelectUse, &cellArea); else { cellArea.r_xbot = 0;