1/*
2 * SPDX-FileCopyrightText: 2010 Petri Damstén <damu@iki.fi>
3 * SPDX-FileCopyrightText: 2014 John Layt <jlayt@kde.org>
4 *
5 * SPDX-License-Identifier: LGPL-2.0-or-later
6 */
7
8#include "thermal_generation_p.h"
9#include "unit_p.h"
10
11#include <KLocalizedString>
12
13namespace KUnitConversion
14{
15UnitCategory ThermalGeneration::makeCategory()
16{
17 auto c = UnitCategoryPrivate::makeCategory(dd: ThermalGenerationCategory, i18n("Thermal Generation"), i18n("Thermal Generation"));
18 auto d = UnitCategoryPrivate::get(category: c);
19 KLocalizedString symbolString = ki18nc("%1 value, %2 unit symbol (thermal generation)", "%1 %2");
20
21 d->addDefaultUnit(UnitPrivate::makeUnit(dd: ThermalGenerationCategory,
22 WattPerCubicMeter,
23 1,
24 i18nc("thermal generation unit symbol", "W/m³"),
25 i18nc("unit description in lists", "watt per cubic meter"),
26 i18nc("unit synonyms for matching user input", "watt per cubic meter;W/m3;W/m^3"),
27 symbolString,
28 ki18nc("amount in units (real)", "%1 watts per cubic meter"),
29 ki18ncp("amount in units (integer)", "%1 watt per cubic meter", "%1 watts per cubic meter")));
30
31 d->addCommonUnit(UnitPrivate::makeUnit(dd: ThermalGenerationCategory,
32 BtuPerHourPerCubicFoot,
33 0.09662,
34 i18nc("thermal generation unit symbol", "Btu/hr/ft³"),
35 i18nc("unit description in lists", "btu per hour per cubic foot"),
36 i18nc("unit synonyms for matching user input", "btu per hour per cubic foot;Btu/hr/ft3;Btu/hr/ft^3;Btu/ft^3/hr;Btu/ft3/hr"),
37 symbolString,
38 ki18nc("amount in units (real)", "%1 btu per hour per cubic foot"),
39 ki18ncp("amount in units (integer)", "%1 btu per hour per cubic foot", "%1 btu per hour per cubic foot")));
40
41 return c;
42}
43
44} // KUnitConversion namespace
45

source code of kunitconversion/src/thermal_generation.cpp