Tri-Inspector/Editor.Samples/Styling/Styling_TitleSample.cs

25 lines
500 B
C#
Raw Normal View History

using System;
using TriInspector;
using UnityEngine;
public class Styling_TitleSample : ScriptableObject
{
[Title("My Title")]
public string val;
[Title("$" + nameof(_myTitleField))]
public Rect rect;
[Title("$" + nameof(MyTitleProperty))]
public Vector3 vec;
[Title("Button Title")]
[Button]
public void MyButton()
{
}
private string _myTitleField = "Serialized Title";
private string MyTitleProperty => DateTime.Now.ToLongTimeString();
}