#include <editlabeltemplate_dialog.h>
Public Member Functions | |
EditLabelTemplateDialog (VAbstractPattern *doc, QWidget *parent=nullptr) | |
virtual | ~EditLabelTemplateDialog () |
QVector< VLabelTemplateLine > | GetTemplate () const |
void | SetTemplate (const QVector< VLabelTemplateLine > &lines) |
void | SetPiece (const VPiece &piece) |
Private Slots | |
void | ShowLineDetails () |
void | AddLine () |
void | RemoveLine () |
void | SaveLineText (const QString &text) |
void | SaveFontStyle (bool checked) |
void | SaveTextFormating (bool checked) |
void | NewTemplate () |
void | ExportTemplate () |
void | ImportTemplate () |
void | InsertPlaceholder () |
void | TabChanged (int index) |
void | SaveAdditionalFontSize (int i) |
Private Member Functions | |
void | SetupControls () |
void | InitPlaceholdersMenu () |
void | InitPlaceholders () |
QString | ReplacePlaceholders (QString line) const |
void | InitPreviewLines (const QVector< VLabelTemplateLine > &lines) |
Private Attributes | |
Ui::EditLabelTemplateDialog * | ui |
QMenu * | m_placeholdersMenu |
VAbstractPattern * | m_doc |
QMap< QString, QPair< QString, QString > > | m_placeholders |
Definition at line 71 of file editlabeltemplate_dialog.h.
|
explicit |
Definition at line 72 of file editlabeltemplate_dialog.cpp.
References AddLine(), ExportTemplate(), ImportTemplate(), InitPlaceholders(), InitPlaceholdersMenu(), m_placeholdersMenu, NewTemplate(), RemoveLine(), SaveAdditionalFontSize(), SaveFontStyle(), SaveLineText(), SaveTextFormating(), ShowLineDetails(), TabChanged(), and ui.
|
virtual |
Definition at line 107 of file editlabeltemplate_dialog.cpp.
References ui.
|
privateslot |
Definition at line 173 of file editlabeltemplate_dialog.cpp.
References ui.
Referenced by EditLabelTemplateDialog().
|
privateslot |
Definition at line 313 of file editlabeltemplate_dialog.cpp.
References VLabelTemplate::AddLines(), VLabelTemplate::CreateEmptyTemplate(), GetTemplate(), qApp, and VDomDocument::SaveDocument().
Referenced by EditLabelTemplateDialog().
QVector< VLabelTemplateLine > EditLabelTemplateDialog::GetTemplate | ( | ) | const |
Definition at line 565 of file editlabeltemplate_dialog.cpp.
References VLabelTemplateLine::alignment, VLabelTemplateLine::bold, VLabelTemplateLine::fontSizeIncrement, VLabelTemplateLine::italic, VLabelTemplateLine::line, qApp, and ui.
Referenced by DialogPatternProperties::EditLabel(), PatternPieceDialog::editPatternLabel(), PatternPieceDialog::editPieceLabel(), ExportTemplate(), and TabChanged().
|
privateslot |
Definition at line 371 of file editlabeltemplate_dialog.cpp.
References VException::DetailedInformation(), VException::ErrorMessage(), qApp, VLabelTemplate::ReadLines(), SetTemplate(), VDomDocument::setXMLContent(), and ui.
Referenced by EditLabelTemplateDialog().
|
private |
Definition at line 491 of file editlabeltemplate_dialog.cpp.
References VAbstractPattern::GetCompanyName(), VAbstractPattern::GetCustomerName(), VAbstractPattern::GetLabelDateFormat(), VAbstractPattern::GetLabelTimeFormat(), VAbstractPattern::GetPatternName(), VAbstractPattern::GetPatternNumber(), VContainer::height(), Individual, m_doc, m_placeholders, VAbstractPattern::MPath(), Multisize, pl_author, pl_customer, pl_date, pl_height, pl_mExt, pl_mFabric, pl_mFileName, pl_mInterfacing, pl_mInterlining, pl_mLining, pl_pAnnotation, pl_patternName, pl_patternNumber, pl_pExt, pl_pFileName, pl_pFoldPosition, pl_pLetter, pl_pName, pl_pOrientation, pl_pQuantity, pl_pRotation, pl_pTilt, pl_size, pl_time, pl_wCut, pl_wOnFold, qApp, and VContainer::size().
Referenced by EditLabelTemplateDialog().
|
private |
Definition at line 476 of file editlabeltemplate_dialog.cpp.
References InsertPlaceholder(), m_placeholders, m_placeholdersMenu, and qApp.
Referenced by EditLabelTemplateDialog().
|
private |
Definition at line 640 of file editlabeltemplate_dialog.cpp.
References ReplacePlaceholders(), and ui.
Referenced by TabChanged().
|
privateslot |
Definition at line 408 of file editlabeltemplate_dialog.cpp.
References ui.
Referenced by InitPlaceholdersMenu().
|
privateslot |
Definition at line 292 of file editlabeltemplate_dialog.cpp.
References ShowLineDetails(), and ui.
Referenced by EditLabelTemplateDialog().
|
privateslot |
Definition at line 181 of file editlabeltemplate_dialog.cpp.
References ShowLineDetails(), and ui.
Referenced by EditLabelTemplateDialog().
|
private |
Definition at line 553 of file editlabeltemplate_dialog.cpp.
References m_placeholders.
Referenced by InitPreviewLines().
|
privateslot |
Definition at line 435 of file editlabeltemplate_dialog.cpp.
References ui.
Referenced by EditLabelTemplateDialog().
|
privateslot |
Definition at line 204 of file editlabeltemplate_dialog.cpp.
References ui.
Referenced by EditLabelTemplateDialog().
|
privateslot |
Definition at line 194 of file editlabeltemplate_dialog.cpp.
References ui.
Referenced by EditLabelTemplateDialog().
|
privateslot |
Definition at line 229 of file editlabeltemplate_dialog.cpp.
References ui.
Referenced by EditLabelTemplateDialog().
void EditLabelTemplateDialog::SetPiece | ( | const VPiece & | piece | ) |
Definition at line 622 of file editlabeltemplate_dialog.cpp.
References VPieceLabelData::GetAnnotation(), VPieceLabelData::GetFoldPosition(), VPieceLabelData::GetLetter(), VAbstractPiece::GetName(), VPieceLabelData::GetOrientation(), VPiece::GetPatternPieceData(), VPieceLabelData::GetQuantity(), VPieceLabelData::GetRotationWay(), VPieceLabelData::GetTilt(), VPieceLabelData::IsOnFold(), m_placeholders, pl_pAnnotation, pl_pFoldPosition, pl_pLetter, pl_pName, pl_pOrientation, pl_pQuantity, pl_pRotation, pl_pTilt, and pl_wOnFold.
Referenced by PatternPieceDialog::editPatternLabel(), and PatternPieceDialog::editPieceLabel().
void EditLabelTemplateDialog::SetTemplate | ( | const QVector< VLabelTemplateLine > & | lines | ) |
Definition at line 591 of file editlabeltemplate_dialog.cpp.
Referenced by DialogPatternProperties::EditLabel(), PatternPieceDialog::editPatternLabel(), PatternPieceDialog::editPieceLabel(), and ImportTemplate().
|
private |
Definition at line 448 of file editlabeltemplate_dialog.cpp.
References ui.
Referenced by ShowLineDetails().
|
privateslot |
Definition at line 113 of file editlabeltemplate_dialog.cpp.
References SetupControls(), and ui.
Referenced by EditLabelTemplateDialog(), NewTemplate(), and RemoveLine().
|
privateslot |
Definition at line 419 of file editlabeltemplate_dialog.cpp.
References GetTemplate(), InitPreviewLines(), and ui.
Referenced by EditLabelTemplateDialog().
|
private |
Definition at line 102 of file editlabeltemplate_dialog.h.
Referenced by InitPlaceholders().
|
private |
Definition at line 104 of file editlabeltemplate_dialog.h.
Referenced by InitPlaceholders(), InitPlaceholdersMenu(), ReplacePlaceholders(), and SetPiece().
|
private |
Definition at line 101 of file editlabeltemplate_dialog.h.
Referenced by EditLabelTemplateDialog(), and InitPlaceholdersMenu().
|
private |
Definition at line 100 of file editlabeltemplate_dialog.h.
Referenced by AddLine(), EditLabelTemplateDialog(), GetTemplate(), ImportTemplate(), InitPreviewLines(), InsertPlaceholder(), NewTemplate(), RemoveLine(), SaveAdditionalFontSize(), SaveFontStyle(), SaveLineText(), SaveTextFormating(), SetTemplate(), SetupControls(), ShowLineDetails(), TabChanged(), and ~EditLabelTemplateDialog().