5#ifndef BITCOIN_UTIL_TRANSLATION_H
6#define BITCOIN_UTIL_TRANSLATION_H
37 return {original, original};
44template <
typename... Args>
46 const auto translate_arg{
47 [](
const auto &arg, [[maybe_unused]]
bool translated) ->
const auto & {
48 if constexpr (std::is_same_v<
decltype(arg),
const bilingual_str &>) {
49 return translated ? arg.translated : arg.original;
bilingual_str & operator+=(const bilingual_str &rhs)
const std::function< std::string(const char *)> G_TRANSLATION_FUN
Translate a message to the native language of the user.
bilingual_str _(const char *psz)
Translation function.
bilingual_str operator+(bilingual_str lhs, const bilingual_str &rhs)
bilingual_str Untranslated(std::string original)
Mark a bilingual_str as untranslated.