more fixes, AtomFont still requires more work

Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
This commit is contained in:
Esteban Papp
2021-07-28 11:06:14 -07:00
parent 9c72510a4f
commit 63d2f34ad6
9 changed files with 47 additions and 49 deletions
+15 -15
View File
@@ -34,14 +34,14 @@ struct SLocalizedInfoGame
}
const char* szCharacterName;
string sUtf8TranslatedText;
AZStd::string sUtf8TranslatedText;
bool bUseSubtitle;
};
struct SLocalizedAdvancesSoundEntry
{
string sName;
AZStd::string sName;
float fValue;
void GetMemoryUsage(ICrySizer* pSizer) const
{
@@ -178,12 +178,12 @@ struct ILocalizationManager
// bEnglish - if true, translates the string into the always present English language.
// Returns:
// true if localization was successful, false otherwise
virtual bool LocalizeString_ch([[maybe_unused]] const char* sString, [[maybe_unused]] string& outLocalizedString, [[maybe_unused]] bool bEnglish = false) override { return false; }
virtual bool LocalizeString_ch([[maybe_unused]] const char* sString, [[maybe_unused]] AZStd::string& outLocalizedString, [[maybe_unused]] bool bEnglish = false) override { return false; }
// Summary:
// Same as LocalizeString( const char* sString, string& outLocalizedString, bool bEnglish=false )
// Same as LocalizeString( const char* sString, AZStd::string& outLocalizedString, bool bEnglish=false )
// but at the moment this is faster.
virtual bool LocalizeString_s([[maybe_unused]] const string& sString, [[maybe_unused]] string& outLocalizedString, [[maybe_unused]] bool bEnglish = false) override { return false; }
virtual bool LocalizeString_s([[maybe_unused]] const AZStd::string& sString, [[maybe_unused]] AZStd::string& outLocalizedString, [[maybe_unused]] bool bEnglish = false) override { return false; }
// Summary:
virtual void LocalizeAndSubstituteInternal([[maybe_unused]] AZStd::string& locString, [[maybe_unused]] const AZStd::vector<AZStd::string>& keys, [[maybe_unused]] const AZStd::vector<AZStd::string>& values) override {}
@@ -196,7 +196,7 @@ struct ILocalizationManager
// bEnglish - if true, returns the always present English version of the label.
// Returns:
// True if localization was successful, false otherwise.
virtual bool LocalizeLabel([[maybe_unused]] const char* sLabel, [[maybe_unused]] string& outLocalizedString, [[maybe_unused]] bool bEnglish = false) override { return false; }
virtual bool LocalizeLabel([[maybe_unused]] const char* sLabel, [[maybe_unused]] AZStd::string& outLocalizedString, [[maybe_unused]] bool bEnglish = false) override { return false; }
virtual bool IsLocalizedInfoFound([[maybe_unused]] const char* sKey) { return false; }
// Summary:
@@ -251,7 +251,7 @@ struct ILocalizationManager
// sLocalizedString - Corresponding english language string.
// Returns:
// True if successful, false otherwise (key not found).
virtual bool GetEnglishString([[maybe_unused]] const char* sKey, [[maybe_unused]] string& sLocalizedString) override { return false; }
virtual bool GetEnglishString([[maybe_unused]] const char* sKey, [[maybe_unused]] AZStd::string& sLocalizedString) override { return false; }
// Summary:
// Get Subtitle for Key or Label .
@@ -261,21 +261,21 @@ struct ILocalizationManager
// bForceSubtitle - If true, get subtitle (sLocalized or sEnglish) even if not specified in Data file.
// Returns:
// True if subtitle found (and outSubtitle filled in), false otherwise.
virtual bool GetSubtitle([[maybe_unused]] const char* sKeyOrLabel, [[maybe_unused]] string& outSubtitle, [[maybe_unused]] bool bForceSubtitle = false) override { return false; }
virtual bool GetSubtitle([[maybe_unused]] const char* sKeyOrLabel, [[maybe_unused]] AZStd::string& outSubtitle, [[maybe_unused]] bool bForceSubtitle = false) override { return false; }
// Description:
// These methods format outString depending on sString with ordered arguments
// FormatStringMessage(outString, "This is %2 and this is %1", "second", "first");
// Arguments:
// outString - This is first and this is second.
virtual void FormatStringMessage_List([[maybe_unused]] string& outString, [[maybe_unused]] const string& sString, [[maybe_unused]] const char** sParams, [[maybe_unused]] int nParams) override {}
virtual void FormatStringMessage([[maybe_unused]] string& outString, [[maybe_unused]] const string& sString, [[maybe_unused]] const char* param1, [[maybe_unused]] const char* param2 = 0, [[maybe_unused]] const char* param3 = 0, [[maybe_unused]] const char* param4 = 0) override {}
virtual void FormatStringMessage_List([[maybe_unused]] AZStd::string& outString, [[maybe_unused]] const AZStd::string& sString, [[maybe_unused]] const char** sParams, [[maybe_unused]] int nParams) override {}
virtual void FormatStringMessage([[maybe_unused]] AZStd::string& outString, [[maybe_unused]] const AZStd::string& sString, [[maybe_unused]] const char* param1, [[maybe_unused]] const char* param2 = 0, [[maybe_unused]] const char* param3 = 0, [[maybe_unused]] const char* param4 = 0) override {}
virtual void LocalizeTime([[maybe_unused]] time_t t, [[maybe_unused]] bool bMakeLocalTime, [[maybe_unused]] bool bShowSeconds, [[maybe_unused]] string& outTimeString) override {}
virtual void LocalizeDate([[maybe_unused]] time_t t, [[maybe_unused]] bool bMakeLocalTime, [[maybe_unused]] bool bShort, [[maybe_unused]] bool bIncludeWeekday, [[maybe_unused]] string& outDateString) override {}
virtual void LocalizeDuration([[maybe_unused]] int seconds, [[maybe_unused]] string& outDurationString) override {}
virtual void LocalizeNumber([[maybe_unused]] int number, [[maybe_unused]] string& outNumberString) override {}
virtual void LocalizeNumber_Decimal([[maybe_unused]] float number, [[maybe_unused]] int decimals, [[maybe_unused]] string& outNumberString) override {}
virtual void LocalizeTime([[maybe_unused]] time_t t, [[maybe_unused]] bool bMakeLocalTime, [[maybe_unused]] bool bShowSeconds, [[maybe_unused]] AZStd::string& outTimeString) override {}
virtual void LocalizeDate([[maybe_unused]] time_t t, [[maybe_unused]] bool bMakeLocalTime, [[maybe_unused]] bool bShort, [[maybe_unused]] bool bIncludeWeekday, [[maybe_unused]] AZStd::string& outDateString) override {}
virtual void LocalizeDuration([[maybe_unused]] int seconds, [[maybe_unused]] AZStd::string& outDurationString) override {}
virtual void LocalizeNumber([[maybe_unused]] int number, [[maybe_unused]] AZStd::string& outNumberString) override {}
virtual void LocalizeNumber_Decimal([[maybe_unused]] float number, [[maybe_unused]] int decimals, [[maybe_unused]] AZStd::string& outNumberString) override {}
// Summary:
// Returns true if the project has localization configured for use, false otherwise.
+12 -12
View File
@@ -99,12 +99,12 @@ public:
// bEnglish - if true, translates the string into the always present English language.
// Returns:
// true if localization was successful, false otherwise
virtual bool LocalizeString_ch(const char* sString, string& outLocalizedString, bool bEnglish = false) = 0;
virtual bool LocalizeString_ch(const char* sString, AZStd::string& outLocalizedString, bool bEnglish = false) = 0;
// Summary:
// Same as LocalizeString( const char* sString, string& outLocalizedString, bool bEnglish=false )
// but at the moment this is faster.
virtual bool LocalizeString_s(const string& sString, string& outLocalizedString, bool bEnglish = false) = 0;
virtual bool LocalizeString_s(const AZStd::string& sString, AZStd::string& outLocalizedString, bool bEnglish = false) = 0;
// Set up system for passing in placeholder data for localized strings
// Summary:
@@ -138,7 +138,7 @@ public:
// bEnglish - if true, returns the always present English version of the label.
// Returns:
// True if localization was successful, false otherwise.
virtual bool LocalizeLabel(const char* sLabel, string& outLocalizedString, bool bEnglish = false) = 0;
virtual bool LocalizeLabel(const char* sLabel, AZStd::string& outLocalizedString, bool bEnglish = false) = 0;
// Summary:
// Return number of localization entries.
@@ -151,7 +151,7 @@ public:
// sLocalizedString - Corresponding english language string.
// Returns:
// True if successful, false otherwise (key not found).
virtual bool GetEnglishString(const char* sKey, string& sLocalizedString) = 0;
virtual bool GetEnglishString(const char* sKey, AZStd::string& sLocalizedString) = 0;
// Summary:
// Get Subtitle for Key or Label .
@@ -161,21 +161,21 @@ public:
// bForceSubtitle - If true, get subtitle (sLocalized or sEnglish) even if not specified in Data file.
// Returns:
// True if subtitle found (and outSubtitle filled in), false otherwise.
virtual bool GetSubtitle(const char* sKeyOrLabel, string& outSubtitle, bool bForceSubtitle = false) = 0;
virtual bool GetSubtitle(const char* sKeyOrLabel, AZStd::string& outSubtitle, bool bForceSubtitle = false) = 0;
// Description:
// These methods format outString depending on sString with ordered arguments
// FormatStringMessage(outString, "This is %2 and this is %1", "second", "first");
// Arguments:
// outString - This is first and this is second.
virtual void FormatStringMessage_List(string& outString, const string& sString, const char** sParams, int nParams) = 0;
virtual void FormatStringMessage(string& outString, const string& sString, const char* param1, const char* param2 = 0, const char* param3 = 0, const char* param4 = 0) = 0;
virtual void FormatStringMessage_List(AZStd::string& outString, const AZStd::string& sString, const char** sParams, int nParams) = 0;
virtual void FormatStringMessage(AZStd::string& outString, const AZStd::string& sString, const char* param1, const char* param2 = 0, const char* param3 = 0, const char* param4 = 0) = 0;
virtual void LocalizeTime(time_t t, bool bMakeLocalTime, bool bShowSeconds, string& outTimeString) = 0;
virtual void LocalizeDate(time_t t, bool bMakeLocalTime, bool bShort, bool bIncludeWeekday, string& outDateString) = 0;
virtual void LocalizeDuration(int seconds, string& outDurationString) = 0;
virtual void LocalizeNumber(int number, string& outNumberString) = 0;
virtual void LocalizeNumber_Decimal(float number, int decimals, string& outNumberString) = 0;
virtual void LocalizeTime(time_t t, bool bMakeLocalTime, bool bShowSeconds, AZStd::string& outTimeString) = 0;
virtual void LocalizeDate(time_t t, bool bMakeLocalTime, bool bShort, bool bIncludeWeekday, AZStd::string& outDateString) = 0;
virtual void LocalizeDuration(int seconds, AZStd::string& outDurationString) = 0;
virtual void LocalizeNumber(int number, AZStd::string& outNumberString) = 0;
virtual void LocalizeNumber_Decimal(float number, int decimals, AZStd::string& outNumberString) = 0;
// Summary:
// Returns true if the project has localization configured for use, false otherwise.