Commit acf34791 authored by Karl Ove Hufthammer's avatar Karl Ove Hufthammer Committed by Boudewijn Rempt

Use translation of unnamed (‘Untitled’) colours

All of the colour palettes included in Krita that have unnamed colours,
have actually the colour names set to ‘Untitled’ in the .gpl files,
instead of having empty names (I’m not sure it’s valid to have empty
names, though). So the code that tried to show unnamed colours as the
translation of the string ‘Untitled’, did not succeed. Now, colours with
empty names or the name ‘Untitled’ are treated the same, so that the
i18n() call always succeeds for unnamed colours.
parent 78560e3d
......@@ -837,7 +837,7 @@ bool KoColorSet::Private::loadGpl()
a.pop_front();
}
QString name = a.join(" ");
e.setName(name.isEmpty() ? i18n("Untitled") : name);
e.setName(name.isEmpty() || name == "Untitled" ? i18n("Untitled") : name);
global().addEntry(e);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment