Skip to content

Releases: Clpsplug/I18nTools

1.4.0

26 Oct 04:16
f5ae93d
Compare
Choose a tag to compare

What's Changed

Added

  • #6 Reference text asset within the resource folder.
    • To use files from resource folder, use <lang>_fileref key and specify file name within the Resource folder.
  • #6 In editor, you can now click "Copy text for primary language to TMP component" to quickly apply the text you're referring to with the static I18n label component.

Full Changelog: 1.3.1...1.4.0

1.3.1

29 Sep 04:07
1458f7d
Compare
Choose a tag to compare

Changed

  • #5 Use of type alias StringHash, mostly for internal purposes.
  • #5 Generated key class's member value will always be 8 digits. No functionality changes.

Full Changelog: 1.3.0...1.3.1

1.3.0

31 Aug 15:11
f4a1182
Compare
Choose a tag to compare

Added

  • Integer-hash-based string search! The plugin now prefers finding the strings using an integer hash generated from a string. This is added to hopefully minimize the computational and allocation cost by operating on the key string.
    • The hashing function is FNV-1a, which is provided as an extension method string.Fnv1aHash().
    • If the hashes collide, you can return to the previous string key notation.
    • The I18n Static Labels still make use of the string key notation - the keys are converted into hashes when they are instantiated.
  • Option to generate the I18nKeys class whose members are all hash integers.
    • The option to generate the class with string keys remains, but it's deprecated.

Changed

  • Referring to the localized string using the string key notation (example.string) from the code is now discouraged.
    • The author strongly recommends using the I18n String Tools to generate the I18nKeys class with its members being hash integers.

Note

This change does NOT fully deprecate the usage of the string key notation, as it is still used for the static labels
and use cases where you want to show a random text from children of a localized string data of a specific key.
Only the usage of the string key notation from the code (i.e., I18nString.For) is deprecated.

Full Changelog: 1.2.1...1.3.0

1.2.1

17 Jun 15:11
Compare
Choose a tag to compare

Fixed an unnecessary 'using' line breaking builds...

Full Changelog: 1.2.0...1.2.1

1.2.0

17 Jun 14:59
Compare
Choose a tag to compare

This release lets you use different asset paths for the string resource file!

Added

  • I18nStringConfig scriptable object
    • Can be created by `Assets > Create > ClpsPLUG > I18n > I18n String Configuration
    • MUST exist in Assets/Resources/I18n/I18nStringConfig.asset to work
    • Lets you pick a different asset path for the string resource file (NOTE: The resource file must still be in the Resources folder).
  • Custom inspector view for I18n Static Label (Both TMP UGUI and regular TMP)
    • The component now previews the text this plugin will display, given the key in the textbox.

Full Changelog: 1.1.5...1.2.0

1.1.5

16 Jun 15:23
Compare
Choose a tag to compare

This update fixes the issue of missing characters when including numbers and symbols and adds the ability to force-include all alphabets (upper and lowercase).

Added

  • A new option to the I18n String Tools
    • "Include all alphabets"
      This option adds A-Z and a-z no matter what. If you expect that users will input any alphabet, tick this option.

Fixed

  • Made the option in the I18n String Tools "Include numeric (and related) chars" include the same characters TextMeshPro would include when you select the "Numbers + Symbols" option.

Full Changelog: 1.1.4...1.1.5

1.1.4

18 Apr 22:49
Compare
Choose a tag to compare

Fixed code not compiling because of wrong imports used.

Full Changelog: 1.1.3...1.1.4

1.1.3

25 Mar 05:10
Compare
Choose a tag to compare

This update adds the ability to detect string resource modification and prompts the user to regenerate the i18n key file.

Added

  • Warning when the hash of the current string resource and the hash recorded on the i18n key file do not match.

Full Changelog: 1.1.2...1.1.3

1.1.2

25 Mar 02:55
f2008c7
Compare
Choose a tag to compare

Fixed inconsistency in the README. No changes in the plugin itself.

1.1.1

23 Mar 10:51
Compare
Choose a tag to compare

Quick fixes

This release fixes bugs present in the previous version and optimises some stuff.

Added

  • XML docs for newly added classes and their members.

Fixed

  • String Tools failing to get the characters used in the string resource
  • BREAKING SupportedLanguageLoader is now singleton because it had been reading a TextAsset whenever required. Now, it only loads once.

Full Changelog: 1.1.0...1.1.1