diff --git a/sources/SearchAndReplace/searchandreplaceworker.cpp b/sources/SearchAndReplace/searchandreplaceworker.cpp index e9bfa0801..654f3b95c 100644 --- a/sources/SearchAndReplace/searchandreplaceworker.cpp +++ b/sources/SearchAndReplace/searchandreplaceworker.cpp @@ -503,8 +503,8 @@ ConductorProperties SearchAndReplaceWorker::replaceAdvanced(Conductor *conductor else if (what == "text") {properties.text.replace(rx, replace);} else if (what == "function") {properties.m_function.replace(rx, replace);} else if (what == "tension/protocol") {properties.m_tension_protocol.replace(rx, replace);} - else if (what == "couleur-conducteur") {properties.m_wire_color.replace(rx, replace);} - else if (what == "section-conducteur") {properties.m_wire_section.replace(rx, replace);} + else if (what == "conductor_color") {properties.m_wire_color.replace(rx, replace);} + else if (what == "conductor_section") {properties.m_wire_section.replace(rx, replace);} } return properties; diff --git a/sources/conductorproperties.cpp b/sources/conductorproperties.cpp index 1a21490bb..1a5b05dab 100644 --- a/sources/conductorproperties.cpp +++ b/sources/conductorproperties.cpp @@ -263,9 +263,9 @@ void ConductorProperties::toXml(QDomElement &e) const e.setAttribute("text_color", text_color.name()); e.setAttribute("formula", m_formula); e.setAttribute("function", m_function); - e.setAttribute("tension-protocol", m_tension_protocol); - e.setAttribute("couleur-conducteur", m_wire_color); - e.setAttribute("section-conducteur", m_wire_section); + e.setAttribute("tension_protocol", m_tension_protocol); + e.setAttribute("conductor_color", m_wire_color); + e.setAttribute("conductor_section", m_wire_section); e.setAttribute("numsize", QString::number(text_size)); e.setAttribute("condsize", QString::number(cond_size)); e.setAttribute("displaytext", m_show_text); @@ -320,9 +320,9 @@ void ConductorProperties::fromXml(QDomElement &e) text_color = (xml_text_color.isValid()? xml_text_color : QColor(Qt::black)); m_formula = e.attribute("formula"); m_function = e.attribute("function"); - m_tension_protocol = e.attribute("tension-protocol"); - m_wire_color = e.attribute("couleur-conducteur"); - m_wire_section = e.attribute("section-conducteur"); + m_tension_protocol = e.attribute("tension_protocol"); + m_wire_color = e.attribute("conductor_color"); + m_wire_section = e.attribute("conductor_section"); text_size = e.attribute("numsize", QString::number(9)).toInt(); cond_size = e.attribute("condsize", QString::number(1)).toDouble(); m_show_text = e.attribute("displaytext", QString::number(1)).toInt(); @@ -356,9 +356,9 @@ void ConductorProperties::toSettings(QSettings &settings, const QString &prefix) settings.setValue(prefix + "text_color", text_color.name()); settings.setValue(prefix + "formula", m_formula); settings.setValue(prefix + "function", m_function); - settings.setValue(prefix + "tension-protocol", m_tension_protocol); - settings.setValue(prefix + "couleur-conducteur", m_wire_color); - settings.setValue(prefix + "section-conducteur", m_wire_section); + settings.setValue(prefix + "tension_protocol", m_tension_protocol); + settings.setValue(prefix + "conductor_color", m_wire_color); + settings.setValue(prefix + "conductor_section", m_wire_section); settings.setValue(prefix + "textsize", QString::number(text_size)); settings.setValue(prefix + "size", QString::number(cond_size)); settings.setValue(prefix + "displaytext", m_show_text); @@ -398,9 +398,9 @@ void ConductorProperties::fromSettings(QSettings &settings, const QString &prefi text_color = (settings_text_color.isValid()? settings_text_color : QColor(Qt::black)); m_formula = settings.value(prefix + "formula", "").toString(); m_function = settings.value(prefix + "function", "").toString(); - m_tension_protocol = settings.value(prefix + "tension-protocol", "").toString(); - m_wire_color = settings.value(prefix + "couleur-conducteur", "").toString(); - m_wire_section = settings.value(prefix + "section-conducteur", "").toString(); + m_tension_protocol = settings.value(prefix + "tension_protocol", "").toString(); + m_wire_color = settings.value(prefix + "conductor_color", "").toString(); + m_wire_section = settings.value(prefix + "conductor_section", "").toString(); text_size = settings.value(prefix + "textsize", "7").toInt(); cond_size = settings.value(prefix + "size", "1").toInt(); m_show_text = settings.value(prefix + "displaytext", true).toBool(); @@ -574,7 +574,7 @@ void ConductorProperties::applyForEqualAttributes(QList lis m_tension_protocol = s_value; equal = true; - //couleur-conducteur + //conductor_color s_value = clist.first().m_wire_color; for(ConductorProperties cp : clist) { @@ -585,7 +585,7 @@ void ConductorProperties::applyForEqualAttributes(QList lis m_wire_color = s_value; equal = true; - //section-conducteur + //conductor_section s_value = clist.first().m_wire_section; for(ConductorProperties cp : clist) { diff --git a/sources/editor/ui/dynamictextfieldeditor.cpp b/sources/editor/ui/dynamictextfieldeditor.cpp index 15f4216cc..03592c122 100644 --- a/sources/editor/ui/dynamictextfieldeditor.cpp +++ b/sources/editor/ui/dynamictextfieldeditor.cpp @@ -190,7 +190,7 @@ void DynamicTextFieldEditor::fillInfoComboBox() QString type = elementEditor()->elementScene()->elementType(); if(type.contains("report")) - strl << "function" << "tension-protocol"; + strl << "function" << "tension_protocol"; else strl = QETApp::elementInfoKeys(); diff --git a/sources/qetgraphicsitem/dynamicelementtextitem.cpp b/sources/qetgraphicsitem/dynamicelementtextitem.cpp index cece1ed4b..4bd9461ab 100644 --- a/sources/qetgraphicsitem/dynamicelementtextitem.cpp +++ b/sources/qetgraphicsitem/dynamicelementtextitem.cpp @@ -1148,11 +1148,11 @@ void DynamicElementTextItem::conductorPropertiesChanged() { if(m_info_name == "function") setPlainText(m_watched_conductor? m_watched_conductor.data()->properties().m_function : ""); - else if (m_info_name == "tension-protocol") + else if (m_info_name == "tension_protocol") setPlainText(m_watched_conductor? m_watched_conductor.data()->properties().m_tension_protocol : ""); - else if (m_info_name == "couleur-conducteur") + else if (m_info_name == "conductor_color") setPlainText(m_watched_conductor? m_watched_conductor.data()->properties().m_wire_color : ""); - else if (m_info_name == "section-conducteur") + else if (m_info_name == "conductor_section") setPlainText(m_watched_conductor? m_watched_conductor.data()->properties().m_wire_section : ""); } else if (m_text_from == CompositeText) { @@ -1186,12 +1186,12 @@ QString DynamicElementTextItem::reportReplacedCompositeText() const { if(string.contains("%{function}")) string.replace("%{function}", m_watched_conductor.data()->properties().m_function); - if(string.contains("%{tension-protocol}")) - string.replace("%{tension-protocol}", m_watched_conductor.data()->properties().m_tension_protocol); - if(string.contains("%{}couleur-conducteur")) - string.replace("%{couleur-conducteur}", m_watched_conductor.data()->properties().m_wire_color); - if(string.contains("%{}section-conducteur")) - string.replace("%{section-conducteur}", m_watched_conductor.data()->properties().m_wire_section); + if(string.contains("%{tension_protocol}")) + string.replace("%{tension_protocol}", m_watched_conductor.data()->properties().m_tension_protocol); + if(string.contains("%{conductor_color}")) + string.replace("%{conductor_color}", m_watched_conductor.data()->properties().m_wire_color); + if(string.contains("%{conductor_section}")) + string.replace("%{conductor_section}", m_watched_conductor.data()->properties().m_wire_section); } } diff --git a/sources/ui/compositetexteditdialog.cpp b/sources/ui/compositetexteditdialog.cpp index 5f822f488..7c161c79f 100644 --- a/sources/ui/compositetexteditdialog.cpp +++ b/sources/ui/compositetexteditdialog.cpp @@ -56,7 +56,7 @@ void CompositeTextEditDialog::setUpComboBox() if(m_text && (m_text->parentElement()->linkType() & Element::AllReport)) //Special treatment for text owned by a folio report { - qstrl << "label" << "function" << "tension-protocol"; + qstrl << "label" << "function" << "tension_protocol"; } else { diff --git a/sources/ui/dynamicelementtextmodel.cpp b/sources/ui/dynamicelementtextmodel.cpp index e42e62164..fc9709d9e 100644 --- a/sources/ui/dynamicelementtextmodel.cpp +++ b/sources/ui/dynamicelementtextmodel.cpp @@ -1781,11 +1781,11 @@ QStringList DynamicTextItemDelegate::availableInfo(DynamicElementTextItem *deti) if (!cond->properties().m_function.isEmpty()) qstrl << "function"; if(!cond->properties().m_tension_protocol.isEmpty()) - qstrl << "tension-protocol"; + qstrl << "tension_protocol"; if(!cond->properties().m_wire_color.isEmpty()) - qstrl << "couleur-conducteur"; + qstrl << "conductor_color"; if(!cond->properties().m_wire_section.isEmpty()) - qstrl << "section-conducteur"; + qstrl << "conductor_section"; } return qstrl;