NameListAttribute
namespace Griff.Scenes;
public sealed class NameListAttribute : FieldEditorAttributeMarks a property as a list of names in order: a string separated by commas (a turn order’s “Player, Enemy”) or a list of strings, one a line (a choice’s options). The Inspector lists them a row each, to rename, add, take out and move up; a name given twice is flagged.
Properties
Section titled “Properties”FitsText
Section titled “FitsText”public override string FitsText { get; }public int Least { get; init; }The fewest there can be: taking one out stops there.
public string Noun { get; init; }What each name is, e.g. “side” or “option”, for the Inspector’s buttons and the descriptions.
Methods
Section titled “Methods”Describe
Section titled “Describe”public override string Describe()public override bool Fits(Type type)Problem
Section titled “Problem”public override string? Problem(Component component, object? value)public static IReadOnlyList<string> Read(object? value)The names a value holds, in order, blank ones left out.