1 /* 2 * LibrePCB - Professional EDA for everyone! 3 * Copyright (C) 2018 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_ABOUTDIALOG_H 21 #define LIBREPCB_ABOUTDIALOG_H 22 23 /******************************************************************************* 24 * Includes 25 ******************************************************************************/ 26 #include "../version.h" 27 28 #include <QAbstractButton> 29 #include <QDialog> 30 #include <QLabel> 31 32 /******************************************************************************* 33 * Namespace / Forward Declarations 34 ******************************************************************************/ 35 namespace librepcb { 36 37 namespace Ui { 38 class AboutDialog; 39 } 40 41 /******************************************************************************* 42 * Class AboutDialog 43 ******************************************************************************/ 44 45 /** 46 * @brief The AboutDialog class 47 */ 48 class AboutDialog final : public QDialog { 49 Q_OBJECT 50 51 public: 52 // Constructors / Destructor 53 AboutDialog() = delete; 54 AboutDialog(const AboutDialog& other) = delete; 55 explicit AboutDialog(QWidget* parent = nullptr) noexcept; 56 ~AboutDialog() noexcept; 57 58 // Operator Overloadings 59 AboutDialog& operator=(const AboutDialog& rhs) = delete; 60 61 private: // Methods 62 void formatLabelHeading(QLabel* label) noexcept; 63 void formatLabelText(QLabel* label, bool selectable, 64 bool containsLinks) noexcept; 65 66 private: // Data 67 QScopedPointer<Ui::AboutDialog> mUi; 68 }; 69 70 /******************************************************************************* 71 * End of File 72 ******************************************************************************/ 73 74 } // namespace librepcb 75 76 #endif // LIBREPCB_ABOUTDIALOG_H 77