umbrello  2.32.2
Umbrello UML Modeller is a Unified Modelling Language (UML) diagram program based on KDE Technology
generaloptionpage.h
Go to the documentation of this file.
1 /*
2  SPDX-License-Identifier: GPL-2.0-or-later
3  SPDX-FileCopyrightText: 2002-2020 Umbrello UML Modeller Authors <umbrello-devel@kde.org>
4 */
5 
6 #ifndef GENERALOPTIONPAGE_H
7 #define GENERALOPTIONPAGE_H
8 
9 #include "dialogpagebase.h"
10 
11 #if QT_VERSION < 0x050000
12 class KIntSpinBox;
13 #endif
14 class KLineEdit;
15 class KComboBox;
16 class QGroupBox;
17 class QCheckBox;
18 class QLabel;
19 #if QT_VERSION >= 0x050000
20 class QSpinBox;
21 #endif
22 
24 
33 {
34  Q_OBJECT
35 public:
36  explicit GeneralOptionPage(QWidget* parent = 0);
37  virtual ~GeneralOptionPage();
38 
39  void setDefaults();
40  void apply();
41 
42 signals:
43  void applyClicked();
44 
45 protected:
46  struct GeneralWidgets {
47  QGroupBox * miscGB;
48  QGroupBox * autosaveGB;
49  QGroupBox * startupGB;
50 
51 #if QT_VERSION >= 0x050000
52  QSpinBox * timeISB;
53 #else
54  KIntSpinBox * timeISB;
55 #endif
56  KComboBox * diagramKB;
57  KComboBox * languageKB;
58 
59  QCheckBox * undoCB;
60  QCheckBox * tabdiagramsCB;
61  QCheckBox * newcodegenCB;
62  QCheckBox * footerPrintingCB;
63  QCheckBox * uml2CB;
64 
65  QCheckBox * autosaveCB;
66  QCheckBox * loadlastCB;
67 
68  // Allow definition of Suffix for autosave
69  // (Default: ".xmi"), private Ui::GeneralOptionPage
70  KLineEdit * autosaveSuffixT;
71  QLabel * autosaveSuffixL;
72  // End AutoSave Suffix
73 
74  QLabel * startL;
75  QLabel * autosaveL;
76  QLabel * defaultLanguageL;
78 
79  void insertDiagram(const QString& type, int index);
80  void insertLayoutType(const QString& type, int index);
81 
82 protected slots:
83  void slotAutosaveCBClicked();
84 
85 };
86 #endif
GeneralOptionPage::GeneralWidgets::undoCB
QCheckBox * undoCB
Definition: generaloptionpage.h:59
GeneralOptionPage::GeneralOptionPage
GeneralOptionPage(QWidget *parent=0)
Definition: generaloptionpage.cpp:38
Settings::GeneralState::tabdiagrams
bool tabdiagrams
Definition: optionstate.h:53
SelectLayoutTypeWidget
Definition: selectlayouttypewidget.h:13
GeneralOptionPage::apply
void apply()
Definition: generaloptionpage.cpp:193
GeneralOptionPage::GeneralWidgets::miscGB
QGroupBox * miscGB
Definition: generaloptionpage.h:47
GeneralOptionPage::GeneralWidgets
Definition: generaloptionpage.h:46
Uml::ProgrammingLanguage::Reserved
@ Reserved
Definition: basictypes.h:312
GeneralOptionPage::insertLayoutType
void insertLayoutType(const QString &type, int index)
Uml::ProgrammingLanguage::fromInt
Enum fromInt(int item)
Definition: basictypes.cpp:1012
Uml::DiagramType::Enum
Enum
Definition: basictypes.h:63
Dialog_Utils::makeLabeledEditField
KLineEdit * makeLabeledEditField(QGridLayout *layout, int row, QLabel *&label, const QString &labelText, KLineEdit *&editField, const QString &editFieldText, int columnOffset)
Definition: dialog_utils.cpp:47
Settings::GeneralState::newcodegen
bool newcodegen
Definition: optionstate.h:54
Settings::GeneralState::diagram
Uml::DiagramType::Enum diagram
Definition: optionstate.h:63
GeneralOptionPage::GeneralWidgets::newcodegenCB
QCheckBox * newcodegenCB
Definition: generaloptionpage.h:61
Settings::OptionState::generalState
GeneralState generalState
Definition: optionstate.h:322
GeneralOptionPage::GeneralWidgets::loadlastCB
QCheckBox * loadlastCB
Definition: generaloptionpage.h:66
dialogpagebase.h
GeneralOptionPage::GeneralWidgets::languageKB
KComboBox * languageKB
Definition: generaloptionpage.h:57
optionstate.h
Settings::optionState
OptionState & optionState()
Definition: optionstate.cpp:357
GeneralOptionPage::GeneralWidgets::startL
QLabel * startL
Definition: generaloptionpage.h:74
Uml::ProgrammingLanguage::toString
QString toString(Enum item)
Definition: basictypes.cpp:910
GeneralOptionPage::GeneralWidgets::footerPrintingCB
QCheckBox * footerPrintingCB
Definition: generaloptionpage.h:62
Settings::GeneralState::autosave
bool autosave
Definition: optionstate.h:58
Uml::DiagramType::fromInt
Enum fromInt(int item)
Definition: basictypes.cpp:253
GeneralOptionPage::GeneralWidgets::autosaveCB
QCheckBox * autosaveCB
Definition: generaloptionpage.h:65
GeneralOptionPage::GeneralWidgets::diagramKB
KComboBox * diagramKB
Definition: generaloptionpage.h:56
DialogPageBase
Definition: dialogpagebase.h:19
i18n
#define i18n
Definition: main.cpp:34
GeneralOptionPage::GeneralWidgets::uml2CB
QCheckBox * uml2CB
Definition: generaloptionpage.h:63
Settings::GeneralState::uml2
bool uml2
Definition: optionstate.h:66
Uml::ProgrammingLanguage::Cpp
@ Cpp
Definition: basictypes.h:294
Uml::DiagramType::toString
QString toString(Enum item)
Definition: basictypes.cpp:154
Settings::GeneralState::autosavetime
int autosavetime
Definition: optionstate.h:60
MyProject\connect
connect()
Definition: namespaces-multiple.php:5
selectlayouttypewidget.h
Settings::GeneralState::footerPrinting
bool footerPrinting
Definition: optionstate.h:57
GeneralOptionPage::setDefaults
void setDefaults()
Definition: generaloptionpage.cpp:179
GeneralOptionPage::GeneralWidgets::tabdiagramsCB
QCheckBox * tabdiagramsCB
Definition: generaloptionpage.h:60
GeneralOptionPage::insertDiagram
void insertDiagram(const QString &type, int index)
Definition: generaloptionpage.cpp:216
Settings::OptionState
Definition: optionstate.h:310
Settings::GeneralState::autosavesuffix
QString autosavesuffix
Text input field for suffix of autosave.
Definition: optionstate.h:61
GeneralOptionPage::GeneralWidgets::autosaveSuffixT
KLineEdit * autosaveSuffixT
Definition: generaloptionpage.h:70
GeneralOptionPage::m_GeneralWidgets
struct GeneralOptionPage::GeneralWidgets m_GeneralWidgets
GeneralOptionPage::GeneralWidgets::timeISB
KIntSpinBox * timeISB
Definition: generaloptionpage.h:54
Settings::GeneralState::defaultLanguage
Uml::ProgrammingLanguage::Enum defaultLanguage
Definition: optionstate.h:64
GeneralOptionPage::slotAutosaveCBClicked
void slotAutosaveCBClicked()
Definition: generaloptionpage.cpp:225
GeneralOptionPage::GeneralWidgets::autosaveGB
QGroupBox * autosaveGB
Definition: generaloptionpage.h:48
GeneralOptionPage::GeneralWidgets::autosaveL
QLabel * autosaveL
Definition: generaloptionpage.h:75
GeneralOptionPage::GeneralWidgets::defaultLanguageL
QLabel * defaultLanguageL
Definition: generaloptionpage.h:76
dialog_utils.h
Settings::GeneralState::undo
bool undo
Definition: optionstate.h:52
GeneralOptionPage::GeneralWidgets::autosaveSuffixL
QLabel * autosaveSuffixL
Definition: generaloptionpage.h:71
Settings::GeneralState::loadlast
bool loadlast
Definition: optionstate.h:62
GeneralOptionPage::applyClicked
void applyClicked()
Definition: moc_generaloptionpage.cpp:137
generaloptionpage.h
GeneralOptionPage::~GeneralOptionPage
virtual ~GeneralOptionPage()
Definition: generaloptionpage.cpp:172
GeneralOptionPage
Definition: generaloptionpage.h:32
GeneralOptionPage::GeneralWidgets::startupGB
QGroupBox * startupGB
Definition: generaloptionpage.h:49
language
and that you know you can do these things To protect your we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights These restrictions translate to certain responsibilities for you if you distribute copies of the or if you modify it For if you distribute copies of such a whether gratis or for a you must give the recipients all the rights that you have You must make sure that receive or can get the source code And you must show them these terms so they know their rights We protect your rights with two distribute and or modify the software for each author s protection and we want to make certain that everyone understands that there is no warranty for this free software If the software is modified by someone else and passed we want its recipients to know that what they have is not the so that any problems introduced by others will not reflect on the original authors reputations any free program is threatened constantly by software patents We wish to avoid the danger that redistributors of a free program will individually obtain patent in effect making the program proprietary To prevent we have made it clear that any patent must be licensed for everyone s free use or not licensed at all The precise terms and conditions for distribution and modification follow TERMS AND CONDITIONS FOR DISTRIBUTION AND MODIFICATION This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License The refers to any such program or and a work based on the Program means either the Program or any derivative work under copyright a work containing the Program or a portion of either verbatim or with modifications and or translated into another language(Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". Activities other than copying