using System.Text.Json.Serialization;

namespace Engine.Asset.Font.Metadata;

[JsonSerializable(typeof(Glyph))]
[Serializable]
public record Glyph
{
  [JsonPropertyName("unicode")]
  [JsonInclude]
  public int Unicode { get; private set; }

  [JsonPropertyName("advance")]
  [JsonInclude]
  public float Advance { get; private set; }

  [JsonPropertyName("planeBounds")]
  [JsonInclude]
  public Bounds? PlaneBounds { get; private set; }

  [JsonPropertyName("atlasBounds")]
  [JsonInclude]
  public Bounds? AtlasBounds { get; private set; }
}