19#include <fmt/format.h>
73template <
typename... Args>
74std::string
getStr(std::string stringName, Args&&... args)
80 return fmt::format(fmt::runtime(rawStr), args...);
82 catch (
const std::exception& e)
84 Logger::error(
"Invalid format \"{}\" from string \"{}\": {}", rawStr, stringName, e.what());
102inline namespace literals
109 std::string
operator""_i18n(
const char* str,
size_t len);
static void error(fmt::format_string< Args... > format, Args &&... args)
Definition logger.hpp:152
std::string getRawStr(std::string stringName)
Definition actions.hpp:25
const std::string LOCALE_PT
Definition i18n.hpp:41
const std::string LOCALE_ES_419
Definition i18n.hpp:44
const std::string LOCALE_JA
Definition i18n.hpp:27
const std::string LOCALE_ZH_HANS
Definition i18n.hpp:36
const std::string LOCALE_ZH_CN
Definition i18n.hpp:35
const std::string LOCALE_FR_CA
Definition i18n.hpp:31
const std::string LOCALE_RYU
custom locale
Definition i18n.hpp:51
const std::string LOCALE_EN_US
Definition i18n.hpp:28
const std::string LOCALE_EN_GB
Definition i18n.hpp:29
const std::string LOCALE_FR
Definition i18n.hpp:30
const std::string LOCALE_ZH_TW
Definition i18n.hpp:38
const std::string LOCALE_PT_BR
Definition i18n.hpp:42
const std::string LOCALE_Ko
Definition i18n.hpp:39
std::string getStr(std::string stringName, Args &&... args)
Definition i18n.hpp:74
const std::string LOCALE_NL
Definition i18n.hpp:40
const std::string LOCALE_DE
Definition i18n.hpp:32
const std::string LOCALE_ES
Definition i18n.hpp:34
const std::string LOCALE_ZH_HANT
Definition i18n.hpp:37
std::string localeFromSystem(std::string system)
const std::string LOCALE_AUTO
Definition i18n.hpp:53
const std::string LOCALE_RU
Definition i18n.hpp:43
const std::string LOCALE_IT
Definition i18n.hpp:33
const std::string LOCALE_DEFAULT
Definition i18n.hpp:55