Add Connections to SSG_LIB, reusing the TRO mechanisms
A connection is a CONNECTION_ARROW block sitting at the midpoint of an arrow
between two TRO markers. It stores the relationship as attributes rather than by
position:
TRO11 ----------> TRO14
UID 0062 UID 0065
Same architecture as the TRO feature, nothing new introduced:
Blockname CONNECTION_* -> c:CONNECTION_EDIT (Lisp/Connection_Edit.lsp)
-> dcl/connection_edit.dcl
The double-click and EATTEDIT hooks already route every INSERT through
SSG_BLOCKEDIT, so this is one more branch in that dispatcher - placed before the
TRO branch since both come from the same annotation run and the patterns must not
overlap. DCL path from DXFM_DCL, ssg-start/ssg-end, ssg-attrib-read and
ssg-attrib-set-on, all text via ssg-text/ssg-textf with 16 new keys in both
language files. Loading is lazy: not preloaded in the MNL, pulled by the menu
macros and the dispatcher with (ssg-ensure "Connection_Edit"), with a fallback to
native EATTEDIT if the module is missing.
CONNECTION_INSERT picks two TRO markers and draws the connection; the new
internal number comes from ssg-id-max/ssg-id-format, so it stays inside the
SSG_LIB number space. It refuses when the block definition is absent - the shape
comes from tro_annotate.py, this command does not invent one.
Menu: SSG_LIB > Connections with Verbindung einfuegen, Verbindung bearbeiten and
Bearbeiten (Auto), plus an entry in the POP501 edit context menu.
On the internal id: the markers keep their visible ID (TRO11) untouched - the
existing TRO_INSERT/tro-naechste-id read it and the request was explicit about
not changing it. The permanent unique number therefore lives in a separate
attribute UID, in the same four-digit space as ssg_id and the CSV TeileId.
Putting it into ID was tried and reverted: IDSCHECK treats ID as numeric and
would have overwritten TRO11 with a number while correcting duplicates.
Connections reference the UIDs, so the relationship survives a renamed or moved
marker.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,59 @@
|
||||
// ============================================================
|
||||
// connection_edit.dcl - Verbindung zwischen zwei TROs bearbeiten
|
||||
// Aendert Quelle und Ziel eines CONNECTION_*-Blocks. Gearbeitet wird
|
||||
// mit den internen IDs; die sprechenden Namen stehen daneben.
|
||||
// Aufruf ueber c:CONNECTION_EDIT (Lisp/Connection_Edit.lsp).
|
||||
// ============================================================
|
||||
|
||||
connection_edit : dialog {
|
||||
label = "Verbindung bearbeiten";
|
||||
|
||||
: column {
|
||||
|
||||
: text {
|
||||
key = "blockname";
|
||||
label = "";
|
||||
}
|
||||
|
||||
: boxed_column {
|
||||
label = "Quelle";
|
||||
: edit_box {
|
||||
key = "from_id";
|
||||
label = "Interne ID:";
|
||||
edit_width = 12;
|
||||
}
|
||||
: edit_box {
|
||||
key = "from_tro";
|
||||
label = "TRO-Kennung:";
|
||||
edit_width = 24;
|
||||
}
|
||||
}
|
||||
|
||||
: boxed_column {
|
||||
label = "Ziel";
|
||||
: edit_box {
|
||||
key = "to_id";
|
||||
label = "Interne ID:";
|
||||
edit_width = 12;
|
||||
}
|
||||
: edit_box {
|
||||
key = "to_tro";
|
||||
label = "TRO-Kennung:";
|
||||
edit_width = 24;
|
||||
}
|
||||
}
|
||||
|
||||
: text {
|
||||
key = "richtung";
|
||||
label = "";
|
||||
}
|
||||
|
||||
: text {
|
||||
key = "hinweis";
|
||||
label = "";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
ok_cancel;
|
||||
}
|
||||
Reference in New Issue
Block a user