TMP Font Asset Create Font Asset#
Text Mesh Pro / TMP Font Asset / TMP Font Asset Create Font Asset FamilyName, StyleName, PointSize
Description#
Compares the Create Font Asset static method of TMP Font Asset class to another value
Parameters#
| Name | Description |
|---|---|
| Family Name | |
| Style Name | |
| Point Size | |
| Value |
Code#
// <auto-generated>
// This script was automatically generated using the Visual Script Transpiler.
// Do not modify. Changes to this file will be lost when updating the package.
// </auto-generated>
using System;
using UnityEngine;
using VisualScript.Icons;
using UnityEngine.TextCore.LowLevel;
using UnityEngine.UI;
using TMPro;
namespace VisualScript.Runtime
{
[Title("TMP Font Asset Create Font Asset")]
[Category("Text Mesh Pro/TMP Font Asset/Create Font Asset", "FamilyName, StyleName, PointSize")]
[Description("Compares the Create Font Asset static method of TMP Font Asset class to another value")]
[Image(typeof(IconUIText), ColorTheme.Type.Blue)]
[Keywords("TMP, Text, Mesh, Pro")]
[Parameter("Family Name")]
[Parameter("Style Name")]
[Parameter("Point Size")]
[Parameter("Value")]
[Serializable]
public class GenConditionScriptableObject_TMP_FontAsset_CheckCreateFontAsset_3_StringFamilyName_StringStyleName_IntPointSize : Condition
{
[SerializeField] private GetScriptableObject m_Value = new GetScriptableObject();
[SerializeField] private GetString m_FamilyName = new GetString();
[SerializeField] private GetString m_StyleName = new GetString();
[SerializeField] private GetInteger m_PointSize = new GetInteger();
protected override string GetTitle(GameObject source)
{
string className = TextUtils.ThemeAsKeyword("TMP Font Asset");
string method = TextUtils.ThemeAsKeyword("Create Font Asset");
return $"{className} {method} ({this.m_FamilyName}, {this.m_StyleName}, {this.m_PointSize}) = {this.m_Value}";
}
protected override bool Run(Args args)
{
TMP_FontAsset value = TMP_FontAsset.CreateFontAsset(
(string) this.m_FamilyName.Get(args),
(string) this.m_StyleName.Get(args),
(int) this.m_PointSize.Get(args)
);
return value == this.m_Value.Get(args) as TMP_FontAsset;
}
}
}