mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-10-04 01:44:13 +02:00
Give each end of the wiring export its terminal index and uuid
Most shipped symbols leave their terminals unnamed, so --export-wiring wrote both terminal columns empty and a reader had to work each end out from the .qet: terminal uuid, then its place in the definition, then the index. The terminal table now keeps the index the scripting API's addConductor() takes, from both fills of the database (the document and the folios give the same value: Element::parseTerminal()'s sort, top to bottom then left to right), and wiring_list_view and the CSV gain from/to_terminal_index and from/to_terminal_uuid as their last columns. The index is left empty for two terminals at one point, where the sort is not stable and the index is not defined; the uuid tells them apart. The wiring list dialog reads named columns and is unaffected. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -150,7 +150,7 @@ class projectDataBase : public QObject
|
||||
void watchConductor(Conductor *conductor);
|
||||
void insertTerminal(Terminal *terminal);
|
||||
void insertTerminal(const QString &uuid, const QString &element_uuid,
|
||||
const QString &name);
|
||||
const QString &name, const QVariant &index);
|
||||
void prepareQuery();
|
||||
static QHash<QString, QString> elementInfoToString(
|
||||
Element *elmt);
|
||||
|
||||
Reference in New Issue
Block a user