From 1c23d7707313e37cccdd41eb893ef2c307e7d27e Mon Sep 17 00:00:00 2001 From: Matthias Koefferlein Date: Sat, 23 Nov 2024 15:19:33 +0100 Subject: [PATCH] By default, layer properties are initialized when no .lyp file is specified in a technology You can turn this feature off by disabling the "Initialize other layers with default properties" option on the techology's "General" page. --- src/lay/lay/TechBaseEditorPage.ui | 416 ++++++++++----------- src/lay/lay/layTechSetupDialog.cc | 3 +- src/laybasic/laybasic/layLayoutViewBase.cc | 2 +- 3 files changed, 210 insertions(+), 211 deletions(-) diff --git a/src/lay/lay/TechBaseEditorPage.ui b/src/lay/lay/TechBaseEditorPage.ui index 17d89749d..5d2cf64f3 100644 --- a/src/lay/lay/TechBaseEditorPage.ui +++ b/src/lay/lay/TechBaseEditorPage.ui @@ -14,74 +14,18 @@ Form - - + + Qt::Horizontal - - - - - - Qt::Horizontal + + + 40 + 20 + - - - - - - - - - Database -unit - - - Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop - - - - - - - Qt::Horizontal - - - - - - - ... - - - - - - - QAbstractItemView::NoSelection - - - - - - - (Use the rename button to change this) - - - - - - - - - - The base path is used to locate auxiliary files if those are specified with a relative path. If none is specified, the default path is used. The default path is the one from which a technology was imported. - - - true - - + @@ -124,122 +68,13 @@ unit - - - - - + + - (Used for creating tech groups) + Group - - - - Qt::Vertical - - - QSizePolicy::Fixed - - - - 20 - 5 - - - - - - - - Technology -specific -libraries - - - - - - - Grids - - - - - - - Base path - - - - - - - Description - - - - - - - Qt::Horizontal - - - - 40 - 20 - - - - - - - - QFrame::NoFrame - - - QFrame::Raised - - - - 0 - - - 0 - - - 0 - - - 0 - - - - - - - - µm (g1,g2,...) - - - - - - - - - - Qt::Vertical - - - - 20 - 40 - - - - @@ -284,10 +119,61 @@ libraries - - + + + + + + + false + + + + + + + The default database unit is used as database unit for freshly created layouts + + + true + + + + + + + Name + + + + + + + QFrame::NoFrame + + + QFrame::Raised + + + + 0 + + + 0 + + + 0 + + + 0 + + + + + + - Automatically add other layers + µm (g1,g2,...) @@ -305,37 +191,79 @@ properties - - + + - Name - - - - - - - false - - - - - - - Group - - - - - - - The default database unit is used as database unit for freshly created layouts + The base path is used to locate auxiliary files if those are specified with a relative path. If none is specified, the default path is used. The default path is the one from which a technology was imported. true + + + + These grids are available for selection from the "View" menu and will override the general ones. You can declare one grid as a strong default to enforce an editing grid from this list. To do so, add an exclamation mark to the grid - e.g. "0.01!,0.02,0.05". + + + true + + + + + + + Technology +specific +libraries + + + + + + + Qt::Horizontal + + + + + + + Qt::Horizontal + + + + + + + Qt::Horizontal + + + + + + + Qt::Vertical + + + QSizePolicy::Fixed + + + + 20 + 5 + + + + + + + + Base path + + + @@ -352,13 +280,85 @@ properties - - + + - These grids are available for selection from the "View" menu and will override the general ones. You can declare one grid as a strong default to enforce an editing grid from this list. To do so, add an exclamation mark to the grid - e.g. "0.01!,0.02,0.05". + Database +unit - - true + + Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + QAbstractItemView::NoSelection + + + + + + + (Used for creating tech groups) + + + + + + + ... + + + + + + + Grids + + + + + + + Description + + + + + + + + + + (Use the rename button to change this) + + + + + + + + + + + + + Initialize other layers with default properties diff --git a/src/lay/lay/layTechSetupDialog.cc b/src/lay/lay/layTechSetupDialog.cc index b690ce8c1..e3773fd1c 100644 --- a/src/lay/lay/layTechSetupDialog.cc +++ b/src/lay/lay/layTechSetupDialog.cc @@ -173,11 +173,10 @@ TechBaseEditorPage::commit () if (! mp_ui->lyp_grp->isChecked ()) { tech ()->set_layer_properties_file (std::string ()); - tech ()->set_add_other_layers (true); } else { tech ()->set_layer_properties_file (tl::to_string (mp_ui->lyp_le->text ())); - tech ()->set_add_other_layers (mp_ui->add_other_layers_cbx->isChecked ()); } + tech ()->set_add_other_layers (mp_ui->add_other_layers_cbx->isChecked ()); } void diff --git a/src/laybasic/laybasic/layLayoutViewBase.cc b/src/laybasic/laybasic/layLayoutViewBase.cc index 4213ffe6d..46dfca454 100644 --- a/src/laybasic/laybasic/layLayoutViewBase.cc +++ b/src/laybasic/laybasic/layLayoutViewBase.cc @@ -2522,7 +2522,7 @@ LayoutViewBase::signal_apply_technology (lay::LayoutHandle *layout_handle) lyp_file = tech->eff_layer_properties_file (); } - if (! lyp_file.empty ()) { + if (! lyp_file.empty () || tech->add_other_layers ()) { // interpolate the layout properties file name tl::Eval expr;