mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-10-13 08:14:13 +02:00
Stop reporting wires as excluded that the list is now showing
excludedConductorCount() counted conductors whose terminals had no uuid, which was the right rule when that was the reason they were dropped. It no longer is: Terminal::stableUuid() derives an identity from the terminal's geometry, so those conductors are in the table. Left unchanged, the dialog would have told the user "671 conductors excluded" on industrial.qet while listing all 671 of them -- a worse failure than the one the count exists to prevent, because it undermines a list that is now correct. The count and the dialog's explanation both now describe the case that actually remains: an endpoint attached to no element at all, which has no identity to key on under any scheme. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -77,14 +77,14 @@ WiringListDialog::WiringListDialog(QETProject *project, QWidget *parent) :
|
||||
summary->setWordWrap(true);
|
||||
if (excluded > 0)
|
||||
{
|
||||
//The count matters more than it looks: a project whose elements
|
||||
//all predate terminal uuids yields an entirely empty list, and
|
||||
//without this line that is indistinguishable from a project with
|
||||
//no wires in it.
|
||||
//Rare now that Terminal::stableUuid() gives every terminal an
|
||||
//identity: what is left is a conductor whose endpoint has no
|
||||
//parent element at all. Still worth saying out loud rather than
|
||||
//presenting a short list as if it were complete.
|
||||
summary->setText(tr("%n conducteur(s) listé(s).", "wiring list summary", listed)
|
||||
% QStringLiteral(" ")
|
||||
% tr("%n conducteur(s) exclu(s) : leurs éléments ne définissent pas"
|
||||
" d'identifiant de borne (définition d'élément trop ancienne).",
|
||||
% tr("%n conducteur(s) exclu(s) : une extrémité n'est rattachée"
|
||||
" à aucun élément.",
|
||||
"wiring list exclusion warning", excluded));
|
||||
}
|
||||
else {
|
||||
|
||||
Reference in New Issue
Block a user