mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-19 14:50:53 +01:00
Same as previous commit, for the element editor.
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@5816 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -61,7 +61,6 @@ ElementPropertiesEditorWidget::ElementPropertiesEditorWidget(QString &basic_type
|
||||
ui->setupUi(this);
|
||||
setUpInterface();
|
||||
upDateInterface();
|
||||
qDebug() << "const";
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -180,8 +179,17 @@ void ElementPropertiesEditorWidget::on_m_buttonBox_accepted()
|
||||
m_kind_info.addValue("type", ui -> m_master_type_cb -> itemData(ui -> m_master_type_cb -> currentIndex()));
|
||||
}
|
||||
|
||||
for (QTreeWidgetItem *qtwi : ui->m_tree->invisibleRootItem()->takeChildren()) {
|
||||
m_elmt_info.addValue(qtwi->data(0, Qt::UserRole).toString(), qtwi->text(1));
|
||||
for (QTreeWidgetItem *qtwi : ui->m_tree->invisibleRootItem()->takeChildren())
|
||||
{
|
||||
QString txt = qtwi->text(1);
|
||||
//Replace html line feed
|
||||
txt.replace("
", " "); //hexa
|
||||
txt.replace(" ", " "); //decimal
|
||||
//Replace html carriage return
|
||||
txt.replace("
", " "); //hexa
|
||||
txt.replace(" ", " "); //decimal
|
||||
|
||||
m_elmt_info.addValue(qtwi->data(0, Qt::UserRole).toString(), txt);
|
||||
}
|
||||
|
||||
this->close();
|
||||
|
||||
@@ -238,11 +238,11 @@ DiagramContext ElementInfoWidget::currentInfo() const
|
||||
{
|
||||
QString txt = eipw->text();
|
||||
//Replace html line feed
|
||||
txt.replace("
", " "); //hexa
|
||||
txt.replace("
", " "); //decimal
|
||||
txt.replace("
", " "); //hexa
|
||||
txt.replace(" ", " "); //decimal
|
||||
//Replace html carriage return
|
||||
txt.replace("
", " "); //hexa
|
||||
txt.replace("
", " "); //decimal
|
||||
txt.replace("
", " "); //hexa
|
||||
txt.replace(" ", " "); //decimal
|
||||
info_.addValue(eipw->key(), txt);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user