Class LocalizeStringEvent | Localization | 0.7.1-preview
docs.unity3d.com
    Show / Hide Table of Contents

    Class LocalizeStringEvent

    Component that can be used to Localize a string. Allows for configuring optional string arguments and provides an update event that can be used to update the string.

    Inheritance
    Object
    LocalizeStringEvent
    Namespace: UnityEngine.Localization.Components
    Syntax
    public class LocalizeStringEvent : MonoBehaviour

    Properties

    OnUpdateString

    Event that will be sent when the localized string is ready.

    Declaration
    public LocalizeStringEvent.StringUnityEvent OnUpdateString { get; set; }
    Property Value
    Type Description
    LocalizeStringEvent.StringUnityEvent

    StringReference

    References the StringTable and StringTableEntry of the localized string.

    Declaration
    public LocalizedString StringReference { get; set; }
    Property Value
    Type Description
    LocalizedString

    Methods

    OnDisable()

    Stops listening for changes to StringReference.

    Declaration
    protected virtual void OnDisable()

    OnEnable()

    Starts listening for changes to StringReference.

    Declaration
    protected virtual void OnEnable()

    UpdateString(String)

    Invokes the OnUpdateString event.

    Declaration
    protected virtual void UpdateString(string value)
    Parameters
    Type Name Description
    String value
    In This Article
    • Properties
      • OnUpdateString
      • StringReference
    • Methods
      • OnDisable()
      • OnEnable()
      • UpdateString(String)
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023