summaryrefslogtreecommitdiffstats
path: root/kgeography/src/mapparser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kgeography/src/mapparser.cpp')
-rw-r--r--kgeography/src/mapparser.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/kgeography/src/mapparser.cpp b/kgeography/src/mapparser.cpp
index 40a1c59e..f50e1b5d 100644
--- a/kgeography/src/mapparser.cpp
+++ b/kgeography/src/mapparser.cpp
@@ -37,7 +37,7 @@ bool mapReader::parseMap(const TQString &path)
}
else
{
- p_error = i18n("%1 does not exist.").tqarg(path);
+ p_error = i18n("%1 does not exist.").arg(path);
}
return false;
}
@@ -74,19 +74,19 @@ bool mapParser::startElement(const TQString&, const TQString &name, const TQStri
if (prev.isEmpty())
{
b = name == "map";
- if (!b) p_error = i18n("The map description file should begin with the %1 tag").tqarg("map");
+ if (!b) p_error = i18n("The map description file should begin with the %1 tag").arg("map");
}
else if (prev == "map")
{
if (name != "mapFile" && name != "name" && name != "division")
{
b = false;
- p_error = i18n("%1 is not a valid tag inside tag %2. Valid tags are %3, %4 and %5").tqarg(name).tqarg(prev).tqarg("mapFile").tqarg("name").tqarg("division");
+ p_error = i18n("%1 is not a valid tag inside tag %2. Valid tags are %3, %4 and %5").arg(name).arg(prev).arg("mapFile").arg("name").arg("division");
}
else if ((name == "mapFile" && p_mapFileSet) || (name == "name" && p_mapNameSet))
{
b = false;
- p_error = i18n("%1 tag has already been set").tqarg(name);
+ p_error = i18n("%1 tag has already been set").arg(name);
}
p_colorSet = false;
if (name == "division")
@@ -102,21 +102,21 @@ bool mapParser::startElement(const TQString&, const TQString &name, const TQStri
prev == "ignore")
{
b = false;
- p_error = i18n("There can not be a tag inside %1 tag").tqarg(prev);
+ p_error = i18n("There can not be a tag inside %1 tag").arg(prev);
}
else if (prev == "division")
{
if (name != "color" && name != "name" && name != "ignore" && name != "flag" && name != "capital")
{
b = false;
- p_error = i18n("%1 is not a valid tag inside tag %2. Valid tags are %3, %4, %5, %6 and %7").tqarg(name).tqarg(prev).tqarg("color").tqarg("name").tqarg("ignore").tqarg("capital").tqarg("flag");
+ p_error = i18n("%1 is not a valid tag inside tag %2. Valid tags are %3, %4, %5, %6 and %7").arg(name).arg(prev).arg("color").arg("name").arg("ignore").arg("capital").arg("flag");
}
else if ((name == "name" && p_divisionNameSet) || (name == "color" && p_colorSet) ||
(name == "ignore" && p_divisionIgnoreSet) || (name == "flag" && p_flagFileSet) ||
(name == "capital" && p_capitalSet))
{
b = false;
- p_error = i18n("%1 tag has already been set").tqarg(name);
+ p_error = i18n("%1 tag has already been set").arg(name);
}
p_red = -1;
p_green = -1;
@@ -146,7 +146,7 @@ bool mapParser::endElement(const TQString &, const TQString &, const TQString &)
{
b = p_map -> setMapFile(p_path + p_contents);
p_mapFileSet = true;
- if (!b) p_error = i18n("File %1 does not exist").tqarg(p_path + p_contents);
+ if (!b) p_error = i18n("File %1 does not exist").arg(p_path + p_contents);
}
else if (aux == "division")
{
@@ -154,9 +154,9 @@ bool mapParser::endElement(const TQString &, const TQString &, const TQString &)
b = p_divisionNameSet;
if (!b) p_error = i18n("There is a division without name");
b = b && p_map -> addDivision(p_division);
- if (!b) p_error = i18n("There is already either a division called %1 or a division with the same colors as %2").tqarg(p_division -> getName()).tqarg(p_division -> getName());
+ if (!b) p_error = i18n("There is already either a division called %1 or a division with the same colors as %2").arg(p_division -> getName()).arg(p_division -> getName());
b = b && (p_capitalSet || !p_division -> canAsk(false));
- if (!b) p_error = i18n("Division %1 has no capital").tqarg(p_division -> getName());
+ if (!b) p_error = i18n("Division %1 has no capital").arg(p_division -> getName());
}
else if (p_previousTags == ":map:division:name")
{
@@ -173,17 +173,17 @@ bool mapParser::endElement(const TQString &, const TQString &, const TQString &)
if (p_red == -1)
{
b = false;
- p_error = i18n("Tag %1 has not the %2 tag.").tqarg("<color>").tqarg("<red>");
+ p_error = i18n("Tag %1 has not the %2 tag.").arg("<color>").arg("<red>");
}
else if (p_green == -1)
{
b = false;
- p_error = i18n("Tag %1 has not the %2 tag.").tqarg("<color>").tqarg("<green>");
+ p_error = i18n("Tag %1 has not the %2 tag.").arg("<color>").arg("<green>");
}
else if (p_blue == -1)
{
b = false;
- p_error = i18n("Tag %1 has not the %2 tag.").tqarg("<color>").tqarg("<blue>");
+ p_error = i18n("Tag %1 has not the %2 tag.").arg("<color>").arg("<blue>");
}
else p_colorSet = true;
}
@@ -217,14 +217,14 @@ bool mapParser::endElement(const TQString &, const TQString &, const TQString &)
else
{
b = false;
- p_error = i18n("Invalid value in tag %1").tqarg("<ignore>");
+ p_error = i18n("Invalid value in tag %1").arg("<ignore>");
}
}
else if (aux == "flag")
{
b = p_division -> setFlagFile(p_path + "flags/" + p_contents);
p_flagFileSet = true;
- if (!b) p_error = i18n("Could not find flag file %1").tqarg(p_path + "flags/" + p_contents);
+ if (!b) p_error = i18n("Could not find flag file %1").arg(p_path + "flags/" + p_contents);
}
else if (aux == "map")
{
@@ -258,7 +258,7 @@ bool mapParser::endDocument()
}
else if (!p_mapNameSet) aux = "name";
else if (!p_mapFileSet) aux = "mapFile";
- p_error = i18n("Tag %1 is missing.").tqarg(aux);
+ p_error = i18n("Tag %1 is missing.").arg(aux);
return false;
}