Skip to content
Snippets Groups Projects
Commit 9cdcb043 authored by Matthias Puchner's avatar Matthias Puchner
Browse files

use platform independent UTF-8 coding

parent f69c2224
No related branches found
No related tags found
1 merge request!415Unit handling in layer oriented sample editor
Pipeline #47618 passed
......@@ -63,15 +63,15 @@ QString unitAsString(const Unit& unit)
case Unit::nanometer:
return "nm";
case Unit::nanometerPower2:
return "nm²";
return u8"nm\u00B2";
case Unit::nanometerPowerMinus2:
return "1/nm²";
return u8"1/nm\u00B2";
case Unit::angstrom:
return "\303\205";
return u8"\u00c5";
case Unit::angstromPower2:
return "\303\205²";
return u8"\u00c5\u00B2";
case Unit::angstromPowerMinus2:
return "1/\303\205²";
return u8"1/\u00c5\u00B2";
case Unit::degree:
return "°";
case Unit::radiant:
......
......@@ -58,7 +58,7 @@ LayerOrientedSampleEditor::LayerOrientedSampleEditor(QWidget* parent)
m_asAngstromAction = new QAction(this);
m_asAngstromAction->setIcon(QIcon(":/images/unit_angstrom.svg"));
m_asAngstromAction->setToolTip("Use \303\205ngstrom as unit (where applicable)");
m_asAngstromAction->setToolTip(u8"Use \u00c5ngstrom as unit (where applicable)");
connect(m_asAngstromAction, &QAction::toggled, this,
&LayerOrientedSampleEditor::onUnitActionToggled);
m_asAngstromAction->setCheckable(true);
......
......@@ -264,7 +264,7 @@ void ActionManager::onAboutToShowSettingsMenu()
};
addUnitAction("Use nanometer as default unit", false);
addUnitAction("Use \303\205ngstrom as default unit", true);
addUnitAction(u8"Use \u00c5ngstrom as default unit", true);
m_settingsMenu->addSeparator();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment