LibrePCB Developers Documentation
Loading...
Searching...
No Matches
cmdremoveselectedschematicitems.h
Go to the documentation of this file.
1/*
2 * LibrePCB - Professional EDA for everyone!
3 * Copyright (C) 2013 LibrePCB Developers, see AUTHORS.md for contributors.
4 * https://librepcb.org/
5 *
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 3 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#ifndef LIBREPCB_EDITOR_CMDREMOVESELECTEDSCHEMATICITEMS_H
21#define LIBREPCB_EDITOR_CMDREMOVESELECTEDSCHEMATICITEMS_H
22
23/*******************************************************************************
24 * Includes
25 ******************************************************************************/
26#include "../../undocommandgroup.h"
27
28#include <QtCore>
29
30/*******************************************************************************
31 * Namespace / Forward Declarations
32 ******************************************************************************/
33namespace librepcb {
34
35class ComponentSignalInstance;
36class SI_NetLabel;
37class SI_NetLine;
38class SI_NetPoint;
39class SI_NetSegment;
40class SI_Symbol;
41
42namespace editor {
43
44class SchematicGraphicsScene;
45
46/*******************************************************************************
47 * Class CmdRemoveSelectedSchematicItems
48 ******************************************************************************/
49
54public:
55 // Constructors / Destructor
57 SchematicGraphicsScene& scene) noexcept;
59
60private:
61 // Private Methods
62
64 bool performExecute() override;
65
66 void removeNetSegmentItems(SI_NetSegment& netsegment,
67 const QSet<SI_NetPoint*>& netpointsToRemove,
68 const QSet<SI_NetLine*>& netlinesToRemove,
69 const QSet<SI_NetLabel*>& netlabelsToRemove);
70 void removeSymbol(SI_Symbol& symbol);
72
73 // Attributes from the constructor
75};
76
77/*******************************************************************************
78 * End of File
79 ******************************************************************************/
80
81} // namespace editor
82} // namespace librepcb
83
84#endif
The ComponentSignalInstance class.
Definition componentsignalinstance.h:49
The SI_NetSegment class.
Definition si_netsegment.h:53
The SI_Symbol class.
Definition si_symbol.h:54
The CmdRemoveSelectedSchematicItems class.
Definition cmdremoveselectedschematicitems.h:53
void disconnectComponentSignalInstance(ComponentSignalInstance &signal)
Definition cmdremoveselectedschematicitems.cpp:325
SchematicGraphicsScene & mScene
Definition cmdremoveselectedschematicitems.h:74
void removeNetSegmentItems(SI_NetSegment &netsegment, const QSet< SI_NetPoint * > &netpointsToRemove, const QSet< SI_NetLine * > &netlinesToRemove, const QSet< SI_NetLabel * > &netlabelsToRemove)
Definition cmdremoveselectedschematicitems.cpp:154
~CmdRemoveSelectedSchematicItems() noexcept
Definition cmdremoveselectedschematicitems.cpp:83
bool performExecute() override
Execute the command the first time.
Definition cmdremoveselectedschematicitems.cpp:90
void removeSymbol(SI_Symbol &symbol)
Definition cmdremoveselectedschematicitems.cpp:301
The SchematicGraphicsScene class.
Definition schematicgraphicsscene.h:67
The UndoCommandGroup class makes it possible to pack multiple undo commands together (it acts as a pa...
Definition undocommandgroup.h:44
Definition occmodel.cpp:76