Fixed a few issues related to the "save <file>.tcl":

(1) Dimension properties were not output correctly.
(2) Magic insisted that the output file was <cell>.tcl, not <file>.tcl,
    although the error was only in the messaging
(3) Magic was incorrectly renaming the cell to <cell>.tcl after writing
    the file.
This commit is contained in:
R. Timothy Edwards
2026-03-01 11:29:25 -05:00
parent ba5154698d
commit f3478cba7b
3 changed files with 15 additions and 12 deletions
+8 -5
View File
@@ -761,13 +761,16 @@ cmdSaveCell(
if (!tryRename || (fileName == NULL) || (strcmp(cellDef->cd_name, fileName) == 0))
goto cleanup;
/* Rename the cell */
if (!DBCellRenameDef(cellDef, fileName))
/* Rename the cell, unless fileName is a .tcl file (scripted output) */
if ((strlen(fileName) <= 4) || strcmp(fileName + strlen(fileName) - 4, ".tcl"))
{
/* This should never happen */
TxError("Magic error: there is already a cell named \"%s\"\n",
if (!DBCellRenameDef(cellDef, fileName))
{
/* This should never happen */
TxError("Magic error: there is already a cell named \"%s\"\n",
fileName);
goto cleanup;
goto cleanup;
}
}
if (EditCellUse && (cellDef == EditCellUse->cu_def))