37 bool diagram_is_read_only = diagram -> isReadOnly();
44 setWindowModality(Qt::WindowModal);
46 setWindowFlags(Qt::Sheet);
49 setWindowTitle(
tr(
"Propriétés du folio",
"window title"));
53 border_infos -> setReadOnly(diagram_is_read_only);
58 if (
QETProject *parent_project = diagram -> project())
63 titleblock_infos -> setReadOnly(diagram_is_read_only);
64 connect(titleblock_infos,SIGNAL(openAutoNumFolioEditor(QString)),
this,SLOT(
editAutoFolioNum()));
69 m_cpw -> setReadOnly(diagram_is_read_only);
78 QDialogButtonBox boutons(diagram_is_read_only ? QDialogButtonBox::Ok : QDialogButtonBox::Ok |
QDialogButtonBox::Cancel);
79 connect(&boutons, SIGNAL(accepted()),
this, SLOT(accept()));
80 connect(&boutons, SIGNAL(rejected()),
this, SLOT(reject()));
82 QGridLayout *glayout =
new QGridLayout;
83 glayout->addWidget(border_infos,0,0);
84 glayout->addWidget(titleblock_infos, 1, 0);
85 glayout->addWidget(
m_cpw, 0, 1, 0, 1);
87 QVBoxLayout vlayout(
this);
88 vlayout.addLayout(glayout);
89 vlayout.addWidget(&boutons);
92 if (
this -> exec() == QDialog::Accepted && !diagram_is_read_only)
99 if (new_titleblock != titleblock) {
104 if (new_border != border) {
109 if (new_conductors != conductors) {
111 diagram -> defaultConductorProperties = new_conductors;
The ProjectPropertiesDialog class this class builds a dialog to edit whole properties of a project...
ConductorPropertiesWidget * m_cpw
void setConductorsAutonumName(const QString &name)
Diagram::setConductorsAutonumName.
QHash< QString, NumerotationContext > conductorAutoNum() const
QETProject::conductorAutoNum.
The DiagramPropertiesDialog class This dialog open a windows for edit properties of a diagram...
DiagramPropertiesDialog(Diagram *diagram, QWidget *parent=nullptr)
DiagramPropertiesDialog::DiagramPropertiesDialog Deafult constructor.
The ChangeTitleBlockCommand class This command changes the title block properties for a particular di...
QString conductorsAutonumName() const
Diagram::conductorsAutonumName.
void editAutoFolioNum()
DiagramPropertiesDialog::editAutonum Open folio autonum editor.
static void diagramPropertiesDialog(Diagram *diagram, QWidget *parent=nullptr)
DiagramPropertiesDialog::diagramPropertiesDialog Static method to get a DiagramPropertiesDialog.
void editAutonum()
DiagramPropertiesDialog::editAutonum Open conductor autonum editor.
void conductorAutoNumChanged()
void setCurrentPage(ProjectPropertiesDialog::Page)
ProjectPropertiesDialog::setCurrentPage Change the current displayed page by p.
QETProject * project() const