#if MODULE_UITK && UNITY_2023_3_OR_NEWER using System; using Unity.Properties; using UnityEngine; using UnityEngine.Localization; using UnityEngine.Localization.SmartFormat.Core.Extensions; using UnityEngine.Localization.SmartFormat.PersistentVariables; using UnityEngine.UIElements; public class UITKDataBindingExamples : MonoBehaviour { void AddStringBinding() { #region set-string-binding var label = new Label(); label.text = "Default Text"; // Add binding to the text property of the label. var localizedString = new LocalizedString("My table", "My Entry"); label.SetBinding("text", localizedString); #endregion } void AddTextureBinding() { #region set-texture-binding var element = new VisualElement(); // Add binding to the text property of the label. var localizedTexture = new LocalizedTexture { TableReference = "My assets", TableEntryReference = "My texture" }; element.SetBinding("style.backgroundImage", localizedTexture); #endregion } void GetStringBinding() { #region get-string-binding var document = GetComponent(); var label = document.rootVisualElement.Q