QElectroTech
0.70
|
#include <projectconfigpages.h>
Public Member Functions | |
ProjectConfigPage (QETProject *, QWidget *=nullptr) | |
~ProjectConfigPage () override | |
virtual QETProject * | project () const |
virtual QETProject * | setProject (QETProject *project, bool=true) |
void | applyConf () override |
virtual void | applyProjectConf ()=0 |
![]() | |
ConfigPage (QWidget *parent) | |
~ConfigPage () override | |
Destructor. More... | |
virtual QString | title () const =0 |
virtual QIcon | icon () const =0 |
Protected Member Functions | |
virtual void | init () |
virtual void | initWidgets ()=0 |
virtual void | initLayout ()=0 |
virtual void | readValuesFromProject ()=0 |
virtual void | adjustReadOnly ()=0 |
Protected Attributes | |
QETProject * | m_project |
Currently edited project. More... | |
Private Member Functions | |
ProjectConfigPage (const ProjectConfigPage &) | |
This class, derived from ConfigPage, aims at providing the basic skeleton for a project configuration page.
Definition at line 39 of file projectconfigpages.h.
ProjectConfigPage::ProjectConfigPage | ( | QETProject * | project, |
QWidget * | parent = nullptr |
||
) |
Constructor
project | Project this page is editing. |
parent | Parent QWidget |
Definition at line 40 of file projectconfigpages.cpp.
|
override |
Destructor
Definition at line 49 of file projectconfigpages.cpp.
|
private |
|
protectedpure virtual |
Use this pure virtual method to adjust the "read only" state of your page widgets according to the currently edited project.
Implemented in ProjectAutoNumConfigPage, and ProjectMainConfigPage.
Referenced by init(), and setProject().
|
overridevirtual |
Apply the configuration after user input
Implements ConfigPage.
Definition at line 79 of file projectconfigpages.cpp.
References applyProjectConf(), and m_project.
|
pure virtual |
Apply configuration to the project after user input. This method is automatically called when the ConfigDialog is validated, and only if the project is both non-zero and not read-only.
Implemented in ProjectAutoNumConfigPage, and ProjectMainConfigPage.
Referenced by applyConf().
|
protectedvirtual |
Initialize the page by calling initWidgets() and initLayout(). Also call readValuesFromProject() and adjustReadOnly() if a non-zero project has been set. Typically, you should call this function in your subclass constructor.
Definition at line 89 of file projectconfigpages.cpp.
References adjustReadOnly(), initLayout(), initWidgets(), m_project, and readValuesFromProject().
Referenced by ProjectMainConfigPage::ProjectMainConfigPage().
|
protectedpure virtual |
Use this pure virtual method to initialize your page layout. This method is always called after initWidgets().
Implemented in ProjectAutoNumConfigPage, and ProjectMainConfigPage.
Referenced by init().
|
protectedpure virtual |
Use this pure virtual method to initialize your page widgets.
Implemented in ProjectAutoNumConfigPage, and ProjectMainConfigPage.
Referenced by init().
|
virtual |
Definition at line 55 of file projectconfigpages.cpp.
References m_project.
Referenced by ProjectAutoNumConfigPage::applyAutoNum(), ProjectAutoNumConfigPage::applyManagement(), ProjectAutoNumConfigPage::initWidgets(), ProjectAutoNumConfigPage::removeContextConductor(), ProjectAutoNumConfigPage::removeContextFolio(), ProjectAutoNumConfigPage::saveContextConductor(), and ProjectAutoNumConfigPage::saveContextFolio().
|
protectedpure virtual |
Use this pure virtual method to fill widgets with project values.
Implemented in ProjectAutoNumConfigPage, and ProjectMainConfigPage.
Referenced by init(), and setProject().
|
virtual |
Set new_project as the project being edited by this page.
read_values | True to read values from the project into widgets before setting them read only accordingly, false otherwise. Defaults to true. |
Definition at line 64 of file projectconfigpages.cpp.
References adjustReadOnly(), m_project, and readValuesFromProject().
|
protected |
Currently edited project.
Definition at line 83 of file projectconfigpages.h.
Referenced by ProjectMainConfigPage::adjustReadOnly(), ProjectAutoNumConfigPage::applyAutoNum(), applyConf(), ProjectMainConfigPage::applyProjectConf(), init(), project(), ProjectMainConfigPage::readValuesFromProject(), ProjectAutoNumConfigPage::readValuesFromProject(), ProjectAutoNumConfigPage::removeContextConductor(), ProjectAutoNumConfigPage::removeContextElement(), ProjectAutoNumConfigPage::removeContextFolio(), ProjectAutoNumConfigPage::saveContextConductor(), ProjectAutoNumConfigPage::saveContextElement(), ProjectAutoNumConfigPage::saveContextFolio(), setProject(), ProjectAutoNumConfigPage::updateContextConductor(), ProjectAutoNumConfigPage::updateContextElement(), and ProjectAutoNumConfigPage::updateContextFolio().