QElectroTech  0.8-dev
qetelementeditor.h
Go to the documentation of this file.
1 /*
2  Copyright 2006-2020 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 CUSTOM_ELEMENT_EDITOR_H
19 #define CUSTOM_ELEMENT_EDITOR_H
20 #include "qetmainwindow.h"
21 #include "qet.h"
22 #include "elementscene.h"
23 #include "elementslocation.h"
24 
25 
26 class ElementItemEditor;
27 class ElementView;
28 
34  Q_OBJECT
35 
36  // constructor, destructor
37  public:
38  QETElementEditor(QWidget * = nullptr);
39  ~QETElementEditor() override;
40  private:
42  void setupActions();
43  void setupMenus();
44  void setupInterface();
45 
46  // attributes
47  private:
49  bool read_only;
57  QDockWidget *m_tools_dock;
59  QStackedWidget *m_tools_dock_stack;
63  QHash<QString, ElementItemEditor *> m_editors;
65  QDockWidget *m_undo_dock;
67  QDockWidget *m_parts_dock;
69  QListWidget *m_parts_list;
75  QAction *undo, *redo;
82  QString min_title;
84  QString filename_;
89 
90  // methods
91  public:
92  void setNames(const NamesList &);
93  void setLocation(const ElementsLocation &);
94  ElementsLocation location() const;
95  void setFileName(const QString &);
96  QString fileName() const;
97  void setReadOnly(bool);
98  bool isReadOnly() const;
99  void fromFile(const QString &);
100  void fromLocation(const ElementsLocation &);
101  bool toFile(const QString &);
102  bool toLocation(const ElementsLocation &location);
103  bool isEditing(const ElementsLocation &);
104  bool isEditing(const QString &);
105  ElementScene *elementScene() const;
106  void readSettings();
107  void writeSettings();
108  static QPointF pasteOffset();
109  static QString getOpenElementFileName(QWidget * = nullptr, const QString & = QString());
110  void contextMenu(QPoint p, QList<QAction *> actions = QList<QAction*>());
111 
112  signals:
114 
115  protected:
116  void closeEvent(QCloseEvent *) override;
117  void firstActivation(QEvent *) override;
118 
119  private:
120  bool canClose();
121  QWidget *clearToolsDock();
122  void copyAndPasteXml(const QDomDocument &);
123 
124  public slots:
125  void addLine();
126  void addRect();
127  void addEllipse();
128  void addPolygon();
129  void addArc();
130  void addText();
131  void addTerminal();
132  void addDynamicTextField();
133  void UncheckAddPrimitive();
134 
135  void slot_new();
136  void slot_open();
137  void slot_openDxf();
138  void slot_openFile();
139  void openRecentFile(const QString &);
140  void openElement(const QString &);
141  void slot_reload();
142  bool slot_save();
143  bool slot_saveAs();
144  bool slot_saveAsFile();
146  void slot_setNoDragToView();
148  void slot_updateMenus();
149  void slot_updateTitle();
150  void slot_createPartsList();
151  void slot_updatePartsList();
153  bool checkElement();
154  void pasteFromFile();
155  void pasteFromElement();
157 };
158 
162 inline void QETElementEditor::setNames(const NamesList &nameslist) {
163  m_elmt_scene -> setNames(nameslist);
164 }
165 
170  return(location_);
171 }
172 
176 inline QString QETElementEditor::fileName() const {
177  return(filename_);
178 }
179 
184  return(m_elmt_scene);
185 }
186 
187 #endif
LineEditor
Definition: lineeditor.h:32
ElementsLocation::exist
bool exist() const
ElementsLocation::exist.
Definition: elementslocation.cpp:472
StyleEditor::isStyleEditable
static bool isStyleEditable(QList< CustomElementPart * > cep_list)
StyleEditor::isStyleEditable.
Definition: styleeditor.cpp:553
elementitemeditor.h
NewElementWizard
Definition: newelementwizard.h:39
QETElementEditor::setFileName
void setFileName(const QString &)
Definition: qetelementeditor.cpp:123
QET_MAX_PARTS_IN_ELEMENT_EDITOR_LIST
#define QET_MAX_PARTS_IN_ELEMENT_EDITOR_LIST
Definition: qetelementeditor.cpp:65
QETElementEditor::paste_in_area
QAction * paste_in_area
Definition: qetelementeditor.h:74
QETElementEditor::canClose
bool canClose()
Definition: qetelementeditor.cpp:1315
QETElementEditor::slot_updateMenus
void slot_updateMenus()
Definition: qetelementeditor.cpp:464
QET::Icons::DocumentNew
QIcon DocumentNew
Definition: qeticons.cpp:53
styleeditor.h
QET::Icons::UserInformations
QIcon UserInformations
Definition: qeticons.cpp:169
QETElementEditor::deselectall
QAction * deselectall
Definition: qetelementeditor.h:73
QETElementEditor::openElement
void openElement(const QString &)
Definition: qetelementeditor.cpp:1154
DynamicTextFieldEditor
The DynamicTextFieldEditor class This class provide a widget used to edit the property of a dynamic t...
Definition: dynamictextfieldeditor.h:32
ElementView
Definition: elementview.h:27
QETElementEditor::addLine
void addLine()
QETElementEditor::addLine Set line creation interface to scene.
Definition: qetelementeditor.cpp:1009
QETElementEditor::slot_setNoDragToView
void slot_setNoDragToView()
Definition: qetelementeditor.cpp:602
QET::Icons::ZoomFitBest
QIcon ZoomFitBest
Definition: qeticons.cpp:178
QET::Icons::EditCopy
QIcon EditCopy
Definition: qeticons.cpp:64
ElementsLocation::setXml
bool setXml(const QDomDocument &xml_document) const
ElementsLocation::setXml Replace the current xml description by xml_document; The document element of...
Definition: elementslocation.cpp:667
QETElementEditor::closeEvent
void closeEvent(QCloseEvent *) override
Definition: qetelementeditor.cpp:1390
TextEditor
Definition: texteditor.h:32
texteditor.h
QETApp::realPath
static QString realPath(const QString &)
QETApp::realPath Allows you to know the absolute path of the * .elmt file corresponding to a symbolic...
Definition: qetapp.cpp:842
QETElementEditor::m_elmt_scene
ElementScene * m_elmt_scene
editing scene
Definition: qetelementeditor.h:55
ESEventAddPolygon
The ESEventAddPolygon class This ESEvent manage creation of polygon in an ElementScene.
Definition: eseventaddpolygon.h:32
lineeditor.h
QETMainWindow
Definition: qetmainwindow.h:26
QET::Icons::PartArc
QIcon PartArc
Definition: qeticons.cpp:127
ArcEditor
Definition: arceditor.h:32
QET::depthActionGroup
QActionGroup * depthActionGroup(QObject *parent=nullptr)
QET::depthActionGroup.
Definition: qet.cpp:676
QET::Icons::ZoomIn
QIcon ZoomIn
Definition: qeticons.cpp:179
ESEventAddArc
The ESEventAddArc class This ESEvent manage creation of arc in an ElementScene.
Definition: eseventaddarc.h:32
eseventaddpolygon.h
arceditor.h
QETApp::customElementsDir
static QString customElementsDir()
QETApp::customElementsDir.
Definition: qetapp.cpp:657
QETElementEditor::reload
QAction * reload
Definition: qetelementeditor.h:71
rectangleeditor.h
QETElementEditor::slot_updateSelectionFromPartsList
void slot_updateSelectionFromPartsList()
Definition: qetelementeditor.cpp:1467
qetmainwindow.h
QETElementEditor::file_menu
QMenu * file_menu
menus
Definition: qetelementeditor.h:51
QETElementEditor::slot_createPartsList
void slot_createPartsList()
Definition: qetelementeditor.cpp:1413
QETElementEditor::paste_from_elmt
QAction * paste_from_elmt
Definition: qetelementeditor.h:74
QET::Icons::ZoomOut
QIcon ZoomOut
Definition: qeticons.cpp:181
QETElementEditor::m_edit_properties
QAction * m_edit_properties
Definition: qetelementeditor.h:76
QETElementEditor::toFile
bool toFile(const QString &)
QETElementEditor::toFile Save to file the drawed element.
Definition: qetelementeditor.cpp:906
QETElementEditor::m_editors
QHash< QString, ElementItemEditor * > m_editors
Hash associating primitive names with their matching edition widget.
Definition: qetelementeditor.h:63
QET::Icons::PartTextField
QIcon PartTextField
Definition: qeticons.cpp:135
QETElementEditor::slot_setRubberBandToView
void slot_setRubberBandToView()
Definition: qetelementeditor.cpp:595
ESEventAddLine
The ESEventAddLine class This ESEvent manage creation of line in a ElementScene.
Definition: eseventaddline.h:32
QETElementEditor::edit_size_hs
QAction * edit_size_hs
Definition: qetelementeditor.h:76
QETElementEditor::m_parts_list
QListWidget * m_parts_list
List of primitives.
Definition: qetelementeditor.h:69
ESEventAddEllipse
The ESEventAddEllipse class This ESEvent manage creation of ellpise in an ElementScene.
Definition: eseventaddellipse.h:33
ElementsLocation::isWritable
bool isWritable() const
ElementsLocation::isWritable.
Definition: elementslocation.cpp:499
QET::Icons::EditUndo
QIcon EditUndo
Definition: qeticons.cpp:82
QETElementEditor::addDynamicTextField
void addDynamicTextField()
QETElementEditor::addDynamicTextField Set dynamic text field creation interface to scene.
Definition: qetelementeditor.cpp:1065
QETElementEditor::isEditing
bool isEditing(const ElementsLocation &)
Definition: qetelementeditor.cpp:948
QETElementEditor::openRecentFile
void openRecentFile(const QString &)
Definition: qetelementeditor.cpp:1120
eseventaddrect.h
QETElementEditor::copyAndPasteXml
void copyAndPasteXml(const QDomDocument &)
Definition: qetelementeditor.cpp:1370
QETElementEditor::slot_updateTitle
void slot_updateTitle()
Definition: qetelementeditor.cpp:500
QETElementEditor::quit
QAction * quit
Definition: qetelementeditor.h:71
QETElementEditor::undo
QAction * undo
Definition: qetelementeditor.h:75
QETElementEditor::location_
ElementsLocation location_
location of the currently edited element
Definition: qetelementeditor.h:86
QETElementEditor::setNames
void setNames(const NamesList &)
Definition: qetelementeditor.h:162
QETElementEditor::fromLocation
void fromLocation(const ElementsLocation &)
QETElementEditor::fromLocation Location of the element to edit.
Definition: qetelementeditor.cpp:1555
QET::Icons::PartText
QIcon PartText
Definition: qeticons.cpp:134
QETElementEditor::save_as_file
QAction * save_as_file
Definition: qetelementeditor.h:71
QETElementEditor::elementScene
ElementScene * elementScene() const
Definition: qetelementeditor.h:183
QET::Icons::XmlTextFile
QIcon XmlTextFile
Definition: qeticons.cpp:176
eseventaddline.h
QETElementEditor::firstActivation
void firstActivation(QEvent *) override
Definition: qetelementeditor.cpp:1405
PolygonEditor
Definition: polygoneditor.h:32
qetmessagebox.h
ellipseeditor.h
QETMainWindow::event
bool event(QEvent *) override
Definition: qetmainwindow.cpp:233
QETElementEditor::open
QAction * open
Definition: qetelementeditor.h:71
QETElementEditor::new_element
QAction * new_element
actions for the "file" menu
Definition: qetelementeditor.h:71
QETElementEditor::~QETElementEditor
~QETElementEditor() override
Destructeur.
Definition: qetelementeditor.cpp:96
QETElementEditor::opened_from_file
bool opened_from_file
whether the currently edited element comes from a file or a location
Definition: qetelementeditor.h:88
QETElementEditor::setReadOnly
void setReadOnly(bool)
Definition: qetelementeditor.cpp:989
QETElementEditor::setLocation
void setLocation(const ElementsLocation &)
QETElementEditor::setLocation The new location to edit.
Definition: qetelementeditor.cpp:113
QET::Icons::Element
QIcon Element
Definition: qeticons.cpp:83
QETElementEditor::slot_saveAs
bool slot_saveAs()
QETElementEditor::slot_saveAs Ask a location to user and save the current edited element to this loca...
Definition: qetelementeditor.cpp:1245
dynamictextfieldeditor.h
QETElementEditor::main_toolbar
QToolBar * main_toolbar
Definition: qetelementeditor.h:78
ElementDialog::getOpenElementLocation
static ElementsLocation getOpenElementLocation(QWidget *parent=nullptr)
ElementDialog::getOpenElementLocation Display a dialog for open an element through her location.
Definition: elementdialog.cpp:280
eseventaddtext.h
QETElementEditor::updateCurrentPartEditor
void updateCurrentPartEditor()
Definition: qetelementeditor.cpp:1662
ChangeZValueCommand
Definition: editorcommands.h:175
QETElementEditor::m_view
ElementView * m_view
view widget for the editing scene
Definition: qetelementeditor.h:53
QET::Icons::EditSelectInvert
QIcon EditSelectInvert
Definition: qeticons.cpp:71
QETElementEditor::m_parts_dock
QDockWidget * m_parts_dock
Container for the list of existing primitives.
Definition: qetelementeditor.h:67
qetapp.h
QETElementEditor::setupMenus
void setupMenus()
QETElementEditor::setupMenus.
Definition: qetelementeditor.cpp:364
QETElementEditor::edit_names
QAction * edit_names
Definition: qetelementeditor.h:76
ElementsLocation::isElement
bool isElement() const
ElementsLocation::isElement.
Definition: elementslocation.cpp:412
qetelementeditor.h
QETElementEditor::paste_from_file
QAction * paste_from_file
Definition: qetelementeditor.h:74
QETElementEditor::open_dxf
QAction * open_dxf
Definition: qetelementeditor.h:71
StyleEditor
Definition: styleeditor.h:35
QETElementEditor::min_title
QString min_title
minimum window title
Definition: qetelementeditor.h:82
QETMainWindow::insertMenu
void insertMenu(QMenu *, QMenu *, bool=true)
Definition: qetmainwindow.cpp:172
QETElementEditor::edit_menu
QMenu * edit_menu
Definition: qetelementeditor.h:51
QETElementEditor::checkElement
bool checkElement()
QETElementEditor::checkElement Do several check about element. If error is occurred return false.
Definition: qetelementeditor.cpp:755
ElementItemEditor
Definition: elementitemeditor.h:34
QETElementEditor::save_as
QAction * save_as
Definition: qetelementeditor.h:71
QETApp::elementsRecentFiles
static RecentFiles * elementsRecentFiles()
QETApp::elementsRecentFiles.
Definition: qetapp.cpp:1395
eseventadddynamictextfield.h
QETElementEditor::paste
QAction * paste
Definition: qetelementeditor.h:74
QET::Icons::PartRectangle
QIcon PartRectangle
Definition: qeticons.cpp:132
qeticons.h
ESEventAddDynamicTextField
The ESEventAddDynamicTextField class This ESEvent manage creation of dynamic text field in an Element...
Definition: eseventadddynamictextfield.h:32
partterminal.h
ElementsLocation::isNull
bool isNull() const
ElementsLocation::isNull.
Definition: elementslocation.cpp:387
qet.h
QET::QetMessageBox::question
QMessageBox::StandardButton question(QWidget *, const QString &, const QString &, QMessageBox::StandardButtons=QMessageBox::Ok, QMessageBox::StandardButton=QMessageBox::NoButton)
Definition: qetmessagebox.cpp:53
terminaleditor.h
QET::Icons::ElementEdit
QIcon ElementEdit
Definition: qeticons.cpp:85
QETElementEditor::addArc
void addArc()
QETElementEditor::addArc Set arc creation interface to scene.
Definition: qetelementeditor.cpp:1041
ElementsLocation::xml
QDomElement xml() const
ElementsLocation::xml.
Definition: elementslocation.cpp:575
QET::Icons::FolderOpen
QIcon FolderOpen
Definition: qeticons.cpp:99
QETElementEditor::addEllipse
void addEllipse()
QETElementEditor::addEllipse Set ellipse creation interface to scene.
Definition: qetelementeditor.cpp:1025
QETElementEditor::redo
QAction * redo
Definition: qetelementeditor.h:75
QETElementEditor::slot_reload
void slot_reload()
QETElementEditor::slot_reload Reload the element from the file or location.
Definition: qetelementeditor.cpp:1177
elementslocation.h
QETElementEditor::pasteOffset
static QPointF pasteOffset()
Definition: qetelementeditor.cpp:1520
QETElementEditor::isReadOnly
bool isReadOnly() const
Definition: qetelementeditor.cpp:1001
QETElementEditor::getOpenElementFileName
static QString getOpenElementFileName(QWidget *=nullptr, const QString &=QString())
Definition: qetelementeditor.cpp:1534
QETElementEditor::pasteFromElement
void pasteFromElement()
QETElementEditor::pasteFromElement Ask an element to user, copy the xml definition of the element to ...
Definition: qetelementeditor.cpp:1630
RectangleEditor
The RectangleEditor class This class provides a widget to edit rectangles within the element editor.
Definition: rectangleeditor.h:36
QETElementEditor::m_undo_dock
QDockWidget * m_undo_dock
container for the undo list
Definition: qetelementeditor.h:65
QETElementEditor::clearToolsDock
QWidget * clearToolsDock()
Definition: qetelementeditor.cpp:1354
QETElementEditor::QETElementEditor
QETElementEditor(const QETElementEditor &)
ESEventAddRect
Definition: eseventaddrect.h:29
QETElementEditor::setupInterface
void setupInterface()
QETElementEditor::setupInterface.
Definition: qetelementeditor.cpp:517
QETElementEditor::readSettings
void readSettings()
QETElementEditor::readSettings Read settings.
Definition: qetelementeditor.cpp:1487
elementscene.h
recentfiles.h
QET::Icons::Names
QIcon Names
Definition: qeticons.cpp:119
QETElementEditor::display_menu
QMenu * display_menu
Definition: qetelementeditor.h:51
QETElementEditor::fileName
QString fileName() const
Definition: qetelementeditor.h:176
QETElementEditor::parts
QActionGroup * parts
Action group.
Definition: qetelementeditor.h:80
QETElementEditor::open_file
QAction * open_file
Definition: qetelementeditor.h:71
eseventaddellipse.h
QETElementEditor::slot_saveAsFile
bool slot_saveAsFile()
QETElementEditor::slot_saveAsFile Ask a file to user and save the current edited element to this file...
Definition: qetelementeditor.cpp:1272
QET::Icons::EditSelectNone
QIcon EditSelectNone
Definition: qeticons.cpp:72
QET::Icons::EditSelectAll
QIcon EditSelectAll
Definition: qeticons.cpp:70
QET::writeXmlFile
bool writeXmlFile(QDomDocument &xml_doc, const QString &filepath, QString *error_message=nullptr)
Definition: qet.cpp:584
QETElementEditor::addText
void addText()
QETElementEditor::addText Set text creation interface to scene.
Definition: qetelementeditor.cpp:1049
QETElementEditor::read_only
bool read_only
whether the editor is "read-only"
Definition: qetelementeditor.h:49
QETElementEditor::m_tools_dock_stack
QStackedWidget * m_tools_dock_stack
Stack of widgets for tools_dock.
Definition: qetelementeditor.h:59
QET::Icons::PartEllipse
QIcon PartEllipse
Definition: qeticons.cpp:129
QETElementEditor::slot_openDxf
void slot_openDxf()
QETElementEditor::slot_openDxf.
Definition: qetelementeditor.cpp:1132
QETElementEditor::view_toolbar
QToolBar * view_toolbar
Definition: qetelementeditor.h:78
QETElementEditor::setupActions
void setupActions()
QETElementEditor::setupActions Create action used in Element editor.
Definition: qetelementeditor.cpp:138
eseventaddterminal.h
QET::Icons::ViewRefresh
QIcon ViewRefresh
Definition: qeticons.cpp:173
QET::Icons::QETLogo
QIcon QETLogo
Definition: qeticons.cpp:151
QET::Icons::EditRedo
QIcon EditRedo
Definition: qeticons.cpp:68
elementview.h
editorcommands.h
QET::compareCanonicalFilePaths
bool compareCanonicalFilePaths(const QString &, const QString &)
Definition: qet.cpp:559
QETElementEditor::depth_toolbar
QToolBar * depth_toolbar
Definition: qetelementeditor.h:78
QETElementEditor::m_tools_dock
QDockWidget * m_tools_dock
container for widgets dedicated to primitive edition
Definition: qetelementeditor.h:57
ElementsLocation
The ElementsLocation class This class represents the location, the location of an element or of a cat...
Definition: elementslocation.h:46
eseventaddarc.h
QETMainWindow::settings_menu_
QMenu * settings_menu_
Settings menu.
Definition: qetmainwindow.h:65
QETElementEditor::slot_openFile
void slot_openFile()
Definition: qetelementeditor.cpp:1103
QETApp::instance
static QETApp * instance()
QETApp::instance.
Definition: qetapp.cpp:153
QETElementEditor::element_toolbar
QToolBar * element_toolbar
Definition: qetelementeditor.h:78
QET::Icons::ZoomOriginal
QIcon ZoomOriginal
Definition: qeticons.cpp:180
QET::Icons::RunDxf
QIcon RunDxf
Definition: qeticons.cpp:157
QETElementEditor::copy
QAction * copy
Definition: qetelementeditor.h:74
newelementwizard.h
QETElementEditor::addRect
void addRect()
QETElementEditor::addRect Set rectangle creation interface to scene.
Definition: qetelementeditor.cpp:1017
QETElementEditor::parts_toolbar
QToolBar * parts_toolbar
toolbars
Definition: qetelementeditor.h:78
QETElementEditor::slot_new
void slot_new()
Definition: qetelementeditor.cpp:1082
NamesList
Definition: nameslist.h:30
QETElementEditor::toLocation
bool toLocation(const ElementsLocation &location)
QETElementEditor::toLocation Save the element to Location.
Definition: qetelementeditor.cpp:929
QETElementEditor::paste_from_menu
QMenu * paste_from_menu
Definition: qetelementeditor.h:51
QET::Icons::ro
QIcon ro
Definition: qeticons.cpp:200
ElementScene::clipboardMayContainElement
static bool clipboardMayContainElement()
ElementScene::clipboardMayContainElement.
Definition: elementscene.cpp:621
QETElementEditor::save
QAction * save
Definition: qetelementeditor.h:71
QET::QetMessageBox::warning
QMessageBox::StandardButton warning(QWidget *, const QString &, const QString &, QMessageBox::StandardButtons=QMessageBox::Ok, QMessageBox::StandardButton=QMessageBox::NoButton)
Definition: qetmessagebox.cpp:68
QETElementEditor::addTerminal
void addTerminal()
QETElementEditor::addTerminal Set terminal creation interface to scene.
Definition: qetelementeditor.cpp:1057
QETElementEditor::slot_updatePartsList
void slot_updatePartsList()
Definition: qetelementeditor.cpp:1444
CustomElementPart
The CustomElementPart class This abstract class represents a primitive of the visual representation o...
Definition: customelementpart.h:40
QETElementEditor::location
ElementsLocation location() const
Definition: qetelementeditor.h:169
QET::Icons::EditPaste
QIcon EditPaste
Definition: qeticons.cpp:67
QETElementEditor::writeSettings
void writeSettings()
QETElementEditor::writeSettings Write the settings.
Definition: qetelementeditor.cpp:1510
QET::Icons::DocumentSave
QIcon DocumentSave
Definition: qeticons.cpp:58
QETElementEditor::selectall
QAction * selectall
actions for the "edit" menu
Definition: qetelementeditor.h:73
QET::Icons::PartLine
QIcon PartLine
Definition: qeticons.cpp:130
ElementsLocation::toString
QString toString() const
ElementsLocation::toString.
Definition: elementslocation.cpp:396
QETElementEditor::slot_updateInformations
void slot_updateInformations()
Definition: qetelementeditor.cpp:611
QETElementEditor::slot_open
void slot_open()
Definition: qetelementeditor.cpp:1090
QETElementEditor::m_depth_action_group
QActionGroup * m_depth_action_group
Definition: qetelementeditor.h:80
QETElementEditor::pasteFromFile
void pasteFromFile()
Definition: qetelementeditor.cpp:1597
ElementDialog::getSaveElementLocation
static ElementsLocation getSaveElementLocation(QWidget *parent=nullptr)
ElementDialog::getSaveElementLocation Display a dialog that allow to user to select an element (exist...
Definition: elementdialog.cpp:290
ESEventAddText
The ESEventAddText class This ESEvent manage creation of text in an ElementScene.
Definition: eseventaddtext.h:32
QETElementEditor::inv_select
QAction * inv_select
Definition: qetelementeditor.h:73
QET::QetMessageBox::critical
QMessageBox::StandardButton critical(QWidget *, const QString &, const QString &, QMessageBox::StandardButtons=QMessageBox::Ok, QMessageBox::StandardButton=QMessageBox::NoButton)
Definition: qetmessagebox.cpp:23
QETElementEditor::saveToLocation
void saveToLocation(ElementsLocation loc)
QETElementEditor::m_default_informations
QLabel * m_default_informations
label displayed when several primitives are selected
Definition: qetelementeditor.h:61
QETElementEditor::contextMenu
void contextMenu(QPoint p, QList< QAction * > actions=QList< QAction * >())
QETElementEditor::contextMenu Display a context menu, with all available action.
Definition: qetelementeditor.cpp:431
QET::Icons::PartPolygon
QIcon PartPolygon
Definition: qeticons.cpp:131
QETElementEditor::edit_delete
QAction * edit_delete
Definition: qetelementeditor.h:76
ESEventAddTerminal
The ESEventAddTerminal class This ESEvent manage creation of terminal in an ElementScene.
Definition: eseventaddterminal.h:32
QET::Icons::DocumentOpenRecent
QIcon DocumentOpenRecent
Definition: qeticons.cpp:55
ElementScene
The ElementScene class This class is the canvas allowing the visual edition of an electrial element....
Definition: elementscene.h:40
QET::Icons::EditDelete
QIcon EditDelete
Definition: qeticons.cpp:66
QETElementEditor::m_zoom_ag
QActionGroup * m_zoom_ag
Definition: qetelementeditor.h:80
EllipseEditor
Definition: ellipseeditor.h:31
elementdialog.h
TerminalEditor
The TerminalEditor class This class provides a widget to edit terminals within the element editor....
Definition: terminaleditor.h:33
QETElementEditor::addPolygon
void addPolygon()
QETElementEditor::addPolygon Set polygon creation interface to scene.
Definition: qetelementeditor.cpp:1033
QETElementEditor::filename_
QString filename_
filename of the currently edited element
Definition: qetelementeditor.h:84
QETElementEditor::QETElementEditor
QETElementEditor(QWidget *=nullptr)
Definition: qetelementeditor.cpp:71
polygoneditor.h
QET::Icons::tr
QIcon tr
Definition: qeticons.cpp:206
QET::Icons::EditCut
QIcon EditCut
Definition: qeticons.cpp:65
QETElementEditor::edit_author
QAction * edit_author
Definition: qetelementeditor.h:76
customelementpart.h
QETElementEditor::cut
QAction * cut
Definition: qetelementeditor.h:74
QET::Icons::DocumentSaveAs
QIcon DocumentSaveAs
Definition: qeticons.cpp:60
QETElementEditor::tools_menu
QMenu * tools_menu
Definition: qetelementeditor.h:51
QET::Icons::Cancel
QIcon Cancel
Definition: qeticons.cpp:34
QETElementEditor::slot_save
bool slot_save()
QETElementEditor::slot_save Save the current editing element. If the filepath or location is unknown,...
Definition: qetelementeditor.cpp:1206
QETElementEditor::fromFile
void fromFile(const QString &)
Definition: qetelementeditor.cpp:842
QETElementEditor
Definition: qetelementeditor.h:33
QET::Icons::Terminal
QIcon Terminal
Definition: qeticons.cpp:164
QET::Icons::ApplicationExit
QIcon ApplicationExit
Definition: qeticons.cpp:27
QETElementEditor::UncheckAddPrimitive
void UncheckAddPrimitive()
QETElementEditor::UncheckAddPrimitive Uncheck all action related to primitive.
Definition: qetelementeditor.cpp:1073