Element editor : Add new tagg for text field (function and tension/protocol).

Report element : text field tagged function or tension/protocol display the function tension/protocol of the potential.


git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@4195 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
blacksun
2015-09-10 08:48:33 +00:00
parent b4d09020a3
commit 6b17088116
7 changed files with 160 additions and 76 deletions

View File

@@ -66,12 +66,14 @@ TextFieldEditor::TextFieldEditor(QETElementEditor *editor, PartTextField *textfi
t -> addWidget(qle_text);
main_layout -> addLayout(t);
//add the tagg combobox
//add the tagg combobox
QHBoxLayout *tagg_layout = new QHBoxLayout();
tagg_layout -> addWidget(new QLabel(tr("tagg :")));
tagg_layout -> addWidget(m_tagg_cb = new QComboBox());
m_tagg_cb -> addItem(tr("Aucun"), QVariant("none"));
m_tagg_cb -> addItem(tr("label"), QVariant("label"));
m_tagg_cb -> addItem(tr("Fonction"), QVariant("function"));
m_tagg_cb -> addItem(tr("Tension/protocole"), QVariant("tension-protocol"));
main_layout -> addLayout(tagg_layout);
QHBoxLayout *rotation_angle_layout = new QHBoxLayout();
@@ -184,6 +186,12 @@ void TextFieldEditor::updateTextFieldRotationAngle()
}
m_locked= false;
}
/**
* @brief TextFieldEditor::updateTagg
* Change the tagg of the text field.
* Change is apply with a QUndoCommand
*/
void TextFieldEditor::updateTagg()
{
if(m_locked) return;