Seamly2D
Code documentation
DialogPatternProperties Class Reference

#include <dialogpatternproperties.h>

Inheritance diagram for DialogPatternProperties:
Collaboration diagram for DialogPatternProperties:

Signals

void UpdateGradation ()
 

Public Member Functions

 DialogPatternProperties (VPattern *doc, VContainer *pattern, QWidget *parent=nullptr)
 
virtual ~DialogPatternProperties () Q_DECL_OVERRIDE
 

Private Slots

void DefValueChanged ()
 
void LabelDataChanged ()
 
void Apply ()
 
void Ok ()
 
void SelectAll (int state)
 
void CheckStateHeight (int state)
 
void CheckStateSize (int state)
 
void DescEdited ()
 
void ChangeImage ()
 
void SaveImage ()
 
void EditLabel ()
 

Private Member Functions

void SetHeightsChecked (bool enabled)
 
void SetSizesChecked (bool enabled)
 
void InitHeights ()
 
void InitSizes ()
 
template<typename Func >
void Init (QCheckBox *check, int val, Func slot)
 
template<typename GVal >
void SetOptions (const QMap< GVal, bool > &option)
 
template<typename GVal >
void InitComboBox (QComboBox *box, const QMap< GVal, bool > &option)
 
void initComboBoxFormats (QComboBox *box, const QStringList &items, const QString &currentFormat)
 
void CheckApplyOk ()
 
void SaveDescription ()
 
void SaveGradation ()
 
void SaveDefValues ()
 
void SaveLabelData ()
 
void SaveTemplateData ()
 
void SaveReadOnlyState ()
 
void SetDefaultHeight (const QString &def)
 
void SetDefaultSize (const QString &def)
 
void UpdateDefHeight ()
 
void UpdateDefSize ()
 
void InitImage ()
 
QImage GetImage ()
 

Private Attributes

Ui::DialogPatternProperties * ui
 
VPatterndoc
 
VContainerpattern
 
int heightsChecked
 
int sizesChecked
 
QMap< GHeights, bool > heights
 
QMap< GSizes, bool > sizes
 
QMap< QCheckBox *, int > data
 
bool descriptionChanged
 
bool gradationChanged
 
bool defaultChanged
 
bool securityChanged
 
bool labelDataChanged
 
bool askSaveLabelData
 
bool templateDataChanged
 
QAction * deleteAction
 
QAction * changeImageAction
 
QAction * saveImageAction
 
QAction * showImageAction
 
QVector< VLabelTemplateLinetemplateLines
 

Detailed Description

Definition at line 68 of file dialogpatternproperties.h.

Constructor & Destructor Documentation

◆ DialogPatternProperties()

◆ ~DialogPatternProperties()

DialogPatternProperties::~DialogPatternProperties ( )
virtual

Definition at line 222 of file dialogpatternproperties.cpp.

References ui.

Member Function Documentation

◆ Apply

void DialogPatternProperties::Apply ( )
privateslot

◆ ChangeImage

void DialogPatternProperties::ChangeImage ( )
privateslot

◆ CheckApplyOk()

void DialogPatternProperties::CheckApplyOk ( )
private

Definition at line 558 of file dialogpatternproperties.cpp.

References heightsChecked, sizesChecked, and ui.

Referenced by CheckStateHeight(), and CheckStateSize().

◆ CheckStateHeight

void DialogPatternProperties::CheckStateHeight ( int  state)
privateslot

◆ CheckStateSize

void DialogPatternProperties::CheckStateSize ( int  state)
privateslot

◆ DefValueChanged

void DialogPatternProperties::DefValueChanged ( )
privateslot

Definition at line 399 of file dialogpatternproperties.cpp.

References defaultChanged.

Referenced by DialogPatternProperties().

◆ DescEdited

void DialogPatternProperties::DescEdited ( )
privateslot

Definition at line 393 of file dialogpatternproperties.cpp.

References descriptionChanged.

Referenced by DialogPatternProperties().

◆ EditLabel

◆ GetImage()

QImage DialogPatternProperties::GetImage ( )
private

◆ Init()

template<typename Func >
void DialogPatternProperties::Init ( QCheckBox *  check,
int  val,
Func  slot 
)
private

Definition at line 713 of file dialogpatternproperties.cpp.

References data.

Referenced by InitHeights(), and InitSizes().

◆ InitComboBox()

template<typename GVal >
void DialogPatternProperties::InitComboBox ( QComboBox *  box,
const QMap< GVal, bool > &  option 
)
private

◆ initComboBoxFormats()

void DialogPatternProperties::initComboBoxFormats ( QComboBox *  box,
const QStringList &  items,
const QString &  currentFormat 
)
private

Definition at line 540 of file dialogpatternproperties.cpp.

References SCASSERT.

Referenced by DialogPatternProperties().

◆ InitHeights()

void DialogPatternProperties::InitHeights ( )
private

◆ InitImage()

void DialogPatternProperties::InitImage ( )
private

◆ InitSizes()

void DialogPatternProperties::InitSizes ( )
private

Definition at line 507 of file dialogpatternproperties.cpp.

References ALL, CheckStateSize(), Init(), S22, S24, S26, S28, S30, S32, S34, S36, S38, S40, S42, S44, S46, S48, S50, S52, S54, S56, S58, S60, S62, S64, S66, S68, S70, S72, SelectAll(), and ui.

Referenced by DialogPatternProperties().

◆ LabelDataChanged

void DialogPatternProperties::LabelDataChanged ( )
privateslot

Definition at line 405 of file dialogpatternproperties.cpp.

References askSaveLabelData, and labelDataChanged.

Referenced by DialogPatternProperties().

◆ Ok

◆ SaveDefValues()

void DialogPatternProperties::SaveDefValues ( )
private

◆ SaveDescription()

void DialogPatternProperties::SaveDescription ( )
private

◆ SaveGradation()

void DialogPatternProperties::SaveGradation ( )
private

◆ SaveImage

void DialogPatternProperties::SaveImage ( )
privateslot

◆ SaveLabelData()

◆ SaveReadOnlyState()

void DialogPatternProperties::SaveReadOnlyState ( )
private

◆ SaveTemplateData()

void DialogPatternProperties::SaveTemplateData ( )
private

◆ SelectAll

void DialogPatternProperties::SelectAll ( int  state)
privateslot

Definition at line 268 of file dialogpatternproperties.cpp.

References data, heights, SetHeightsChecked(), SetSizesChecked(), sizes, and ui.

Referenced by InitHeights(), and InitSizes().

◆ SetDefaultHeight()

void DialogPatternProperties::SetDefaultHeight ( const QString &  def)
private

Definition at line 654 of file dialogpatternproperties.cpp.

References defaultChanged, VContainer::height(), and ui.

Referenced by DialogPatternProperties(), and UpdateDefHeight().

◆ SetDefaultSize()

void DialogPatternProperties::SetDefaultSize ( const QString &  def)
private

Definition at line 675 of file dialogpatternproperties.cpp.

References defaultChanged, VContainer::size(), and ui.

Referenced by DialogPatternProperties(), and UpdateDefSize().

◆ SetHeightsChecked()

void DialogPatternProperties::SetHeightsChecked ( bool  enabled)
private

Definition at line 412 of file dialogpatternproperties.cpp.

References ui.

Referenced by SelectAll().

◆ SetOptions()

template<typename GVal >
void DialogPatternProperties::SetOptions ( const QMap< GVal, bool > &  option)
private

Definition at line 721 of file dialogpatternproperties.cpp.

References data.

Referenced by DialogPatternProperties().

◆ SetSizesChecked()

void DialogPatternProperties::SetSizesChecked ( bool  enabled)
private

Definition at line 443 of file dialogpatternproperties.cpp.

References ui.

Referenced by SelectAll().

◆ UpdateDefHeight()

void DialogPatternProperties::UpdateDefHeight ( )
private

Definition at line 696 of file dialogpatternproperties.cpp.

References heights, InitComboBox(), SetDefaultHeight(), and ui.

Referenced by CheckStateHeight().

◆ UpdateDefSize()

void DialogPatternProperties::UpdateDefSize ( )
private

Definition at line 704 of file dialogpatternproperties.cpp.

References InitComboBox(), SetDefaultSize(), sizes, and ui.

Referenced by CheckStateSize().

◆ UpdateGradation

void DialogPatternProperties::UpdateGradation ( )
signal

Referenced by SaveGradation().

Member Data Documentation

◆ askSaveLabelData

bool DialogPatternProperties::askSaveLabelData
private

Definition at line 103 of file dialogpatternproperties.h.

Referenced by EditLabel(), LabelDataChanged(), and SaveLabelData().

◆ changeImageAction

QAction* DialogPatternProperties::changeImageAction
private

Definition at line 106 of file dialogpatternproperties.h.

Referenced by InitImage().

◆ data

QMap<QCheckBox *, int> DialogPatternProperties::data
private

◆ defaultChanged

bool DialogPatternProperties::defaultChanged
private

◆ deleteAction

QAction* DialogPatternProperties::deleteAction
private

Definition at line 105 of file dialogpatternproperties.h.

Referenced by ChangeImage(), and InitImage().

◆ descriptionChanged

bool DialogPatternProperties::descriptionChanged
private

Definition at line 98 of file dialogpatternproperties.h.

Referenced by DescEdited(), and SaveDescription().

◆ doc

◆ gradationChanged

bool DialogPatternProperties::gradationChanged
private

◆ heights

QMap<GHeights, bool> DialogPatternProperties::heights
private

◆ heightsChecked

int DialogPatternProperties::heightsChecked
private

Definition at line 93 of file dialogpatternproperties.h.

Referenced by CheckApplyOk(), and CheckStateHeight().

◆ labelDataChanged

bool DialogPatternProperties::labelDataChanged
private

Definition at line 102 of file dialogpatternproperties.h.

Referenced by EditLabel(), LabelDataChanged(), and SaveLabelData().

◆ pattern

VContainer* DialogPatternProperties::pattern
private

Definition at line 92 of file dialogpatternproperties.h.

Referenced by InitComboBox().

◆ saveImageAction

QAction* DialogPatternProperties::saveImageAction
private

Definition at line 107 of file dialogpatternproperties.h.

Referenced by ChangeImage(), and InitImage().

◆ securityChanged

bool DialogPatternProperties::securityChanged
private

Definition at line 101 of file dialogpatternproperties.h.

Referenced by DialogPatternProperties(), and SaveReadOnlyState().

◆ showImageAction

QAction* DialogPatternProperties::showImageAction
private

Definition at line 108 of file dialogpatternproperties.h.

Referenced by ChangeImage(), and InitImage().

◆ sizes

QMap<GSizes, bool> DialogPatternProperties::sizes
private

◆ sizesChecked

int DialogPatternProperties::sizesChecked
private

Definition at line 94 of file dialogpatternproperties.h.

Referenced by CheckApplyOk(), and CheckStateSize().

◆ templateDataChanged

bool DialogPatternProperties::templateDataChanged
private

Definition at line 104 of file dialogpatternproperties.h.

Referenced by EditLabel(), and SaveTemplateData().

◆ templateLines

QVector<VLabelTemplateLine> DialogPatternProperties::templateLines
private

Definition at line 110 of file dialogpatternproperties.h.

Referenced by EditLabel(), and SaveTemplateData().

◆ ui


The documentation for this class was generated from the following files: