Update translation and strings for gas usage in stats

Giving the string " and " to transiflex seems to fail and/or
it's highly possible that the translators make a mistake by
translating it into "and" or " and" or "and ".
Change the string to "and" and hard code the whitespaces before and after.

Change O2 to O₂ in statistics.

Translate "He" and "O2" in statistics.

Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
This commit is contained in:
Stefan Fuchs 2017-04-27 21:47:51 +02:00 committed by Dirk Hohndel
parent 257f7c082d
commit a784b15cb8

View file

@ -120,12 +120,16 @@ void TabDiveStatistics::updateData()
*/
if (he_tot.mliter || o2_tot.mliter) {
gasUsedString.append(tr("These gases could be\nmixed from Air and using:\n"));
if (he_tot.mliter)
gasUsedString.append(QString("He: %1").arg(get_volume_string(he_tot, true)));
if (he_tot.mliter) {
gasUsedString.append(tr("He"));
gasUsedString.append(QString(": %1").arg(get_volume_string(he_tot, true)));
}
if (he_tot.mliter && o2_tot.mliter)
gasUsedString.append(tr(" and "));
if (o2_tot.mliter)
gasUsedString.append(QString("O2: %2\n").arg(get_volume_string(o2_tot, true)));
gasUsedString.append(" ").append(tr("and")).append(" ");
if (o2_tot.mliter) {
gasUsedString.append(tr("O₂"));
gasUsedString.append(QString(": %2\n").arg(get_volume_string(o2_tot, true)));
}
}
ui->gasConsumption->setText(gasUsedString);
}