LibrePCB Developers Documentation
Loading...
Searching...
No Matches
boardsetupdialog.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_BOARDSETUPDIALOG_H
21#define LIBREPCB_EDITOR_BOARDSETUPDIALOG_H
22
23/*******************************************************************************
24 * Includes
25 ******************************************************************************/
26#include <QtCore>
27#include <QtWidgets>
28
29/*******************************************************************************
30 * Namespace / Forward Declarations
31 ******************************************************************************/
32namespace librepcb {
33
34class Board;
35class Layer;
36
37namespace editor {
38
39class UndoStack;
40
41namespace Ui {
42class BoardSetupDialog;
43}
44
45/*******************************************************************************
46 * Class BoardSetupDialog
47 ******************************************************************************/
48
52class BoardSetupDialog final : public QDialog {
53 Q_OBJECT
54
55public:
56 // Constructors / Destructor
57 BoardSetupDialog() = delete;
58 BoardSetupDialog(const BoardSetupDialog& other) = delete;
59 BoardSetupDialog(Board& board, UndoStack& undoStack,
60 QWidget* parent = 0) noexcept;
62
63 // General Methods
64 void openDrcSettingsTab() noexcept;
65
66 // Operator Overloadings
67 BoardSetupDialog& operator=(const BoardSetupDialog& rhs) = delete;
68
69private: // Methods
70 void buttonBoxClicked(QAbstractButton* button);
71 void load() noexcept;
72 bool apply() noexcept;
73 QVector<const Layer*> getTopSilkscreenLayers() const noexcept;
74 QVector<const Layer*> getBotSilkscreenLayers() const noexcept;
75
76private: // Date
79 QScopedPointer<Ui::BoardSetupDialog> mUi;
80
81 static const QString sSettingsPrefix;
82};
83
84/*******************************************************************************
85 * End of File
86 ******************************************************************************/
87
88} // namespace editor
89} // namespace librepcb
90
91#endif
The Board class represents a PCB of a project and is always part of a circuit.
Definition board.h:73
The Layer class provides all supported geometry layers.
Definition layer.h:42
The BoardSetupDialog class.
Definition boardsetupdialog.h:52
QVector< const Layer * > getBotSilkscreenLayers() const noexcept
Definition boardsetupdialog.cpp:470
void buttonBoxClicked(QAbstractButton *button)
Definition boardsetupdialog.cpp:264
static const QString sSettingsPrefix
Definition boardsetupdialog.h:81
Board & mBoard
Definition boardsetupdialog.h:77
UndoStack & mUndoStack
Definition boardsetupdialog.h:78
bool apply() noexcept
Definition boardsetupdialog.cpp:373
void load() noexcept
Definition boardsetupdialog.cpp:283
QVector< const Layer * > getTopSilkscreenLayers() const noexcept
Definition boardsetupdialog.cpp:455
void openDrcSettingsTab() noexcept
Definition boardsetupdialog.cpp:256
QScopedPointer< Ui::BoardSetupDialog > mUi
Definition boardsetupdialog.h:79
BoardSetupDialog(const BoardSetupDialog &other)=delete
The UndoStack class holds UndoCommand objects and provides undo/redo commands.
Definition undostack.h:106
Definition occmodel.cpp:76