QElectroTech 0.100.0-dev
Loading...
Searching...
No Matches
conductorpropertieswidget.h
Go to the documentation of this file.
1/*
2 Copyright 2006-2024 The QElectroTech Team
3 This file is part of QElectroTech.
4
5 QElectroTech is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 2 of the License, or
8 (at your option) any later version.
9
10 QElectroTech is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with QElectroTech. If not, see <http://www.gnu.org/licenses/>.
17*/
18#ifndef CONDUCTORPROPERTIESWIDGET_H
19#define CONDUCTORPROPERTIESWIDGET_H
20
21#include "../conductorproperties.h"
22
23#include <QWidget>
25class QComboBox;
26class QPushButton;
27
28namespace Ui {
30}
31
32class ConductorPropertiesWidget : public QWidget
33{
34 Q_OBJECT
35
36 public:
37 explicit ConductorPropertiesWidget(QWidget *parent = nullptr);
40 QWidget *parent = nullptr);
42
43 //METHODS
46 void setReadOnly(const bool &ro);
47
48 void addAutonumWidget (QWidget *widget);
49 void setHiddenOneTextPerFolio (const bool &hide);
50 void setDisabledShowText (const bool &disable = true);
51 void setHiddenAvailableAutonum (const bool &hide);
52 QComboBox *autonumComboBox() const;
53 QPushButton *editAutonumPushButton() const;
54
55 private:
56 void initWidget();
58
59 protected:
60 bool event(QEvent *event) override;
61
62 //SLOTS
63 public slots:
64 void updatePreview(bool b = true);
65
66 private slots:
67 void on_m_earth_cb_toggled(bool checked);
68 void on_m_neutral_cb_toggled(bool checked);
70
71 private:
72 Ui::ConductorPropertiesWidget *ui;
75};
76
77#endif // CONDUCTORPROPERTIESWIDGET_H
The ConductorProperties class This class represents the functional properties of a particular conduct...
Definition conductorproperties.h:68
ConductorType
The ConductorType enum Represents the kind of a particular conductor: Single: singleline symbols,...
Definition conductorproperties.h:79
Definition conductorpropertieswidget.h:33
void updatePreview(bool b=true)
ConductorPropertiesWidget::updatePreview Update the preview for single lien.
Definition conductorpropertieswidget.cpp:278
QPushButton * editAutonumPushButton() const
Definition conductorpropertieswidget.cpp:219
void on_m_neutral_cb_toggled(bool checked)
ConductorPropertiesWidget::on_m_neutral_cb_toggled Update the widget when toggled.
Definition conductorpropertieswidget.cpp:310
void initWidget()
ConductorPropertiesWidget::initWidget.
Definition conductorpropertieswidget.cpp:227
void setHiddenOneTextPerFolio(const bool &hide)
ConductorPropertiesWidget::setHiddenOneTextPerFolio.
Definition conductorpropertieswidget.cpp:190
void on_m_earth_cb_toggled(bool checked)
ConductorPropertiesWidget::on_m_earth_cb_toggled Update the widget when toggled.
Definition conductorpropertieswidget.cpp:299
ConductorProperties properties() const
ConductorPropertiesWidget::properties.
Definition conductorpropertieswidget.cpp:119
void setReadOnly(const bool &ro)
ConductorPropertiesWidget::setReadOnly.
Definition conductorpropertieswidget.cpp:174
~ConductorPropertiesWidget() override
ConductorPropertiesWidget::~ConductorPropertiesWidget destructor.
Definition conductorpropertieswidget.cpp:62
QTextOrientationSpinBoxWidget * m_horiz_select
Definition conductorpropertieswidget.h:74
void setDisabledShowText(const bool &disable=true)
ConductorPropertiesWidget::setDisabledShowText.
Definition conductorpropertieswidget.cpp:198
void setProperties(const ConductorProperties &properties)
ConductorPropertiesWidget::setProperties Set the properties.
Definition conductorpropertieswidget.cpp:72
void addAutonumWidget(QWidget *widget)
ConductorPropertiesWidget::addAutonumWidget.
Definition conductorpropertieswidget.cpp:182
QComboBox * autonumComboBox() const
Definition conductorpropertieswidget.cpp:214
Ui::ConductorPropertiesWidget * ui
Definition conductorpropertieswidget.h:72
void on_m_update_preview_pb_clicked()
ConductorPropertiesWidget::on_m_update_preview_pb_clicked Update the preview of single line....
Definition conductorpropertieswidget.cpp:323
bool event(QEvent *event) override
ConductorPropertiesWidget::event.
Definition conductorpropertieswidget.cpp:161
QTextOrientationSpinBoxWidget * m_verti_select
Definition conductorpropertieswidget.h:74
ConductorProperties m_properties
Definition conductorpropertieswidget.h:73
void setConductorType(ConductorProperties::ConductorType type)
ConductorPropertiesWidget::setConductorType Update this widget to the new conductor type.
Definition conductorpropertieswidget.cpp:258
void setHiddenAvailableAutonum(const bool &hide)
ConductorPropertiesWidget::setHiddenAvailableAutonum Hide the label, combo box and push button of ava...
Definition conductorpropertieswidget.cpp:207
Definition qtextorientationspinboxwidget.h:27
Definition autonumberingdockwidget.h:26