// // Generated by Brutal.Sdl.Generate; do not edit by hand. #nullable enable using System; using Brutal.Interop; namespace Brutal.SdlApi.Ttf; /// /// A strongly-typed interop handle wrapping the opaque SDL TTF_Font pointer. /// [InteropHandle] public readonly unsafe partial struct TtfFont : IDisposable { /// public void Dispose() { // A default/zeroed handle owns nothing; forwarding it to the native destructor is at // best a wasted call and at worst undefined behaviour. Guard so Dispose is a safe no-op // on a null handle (and so a double-dispose after the value was cleared is harmless). if (IsNull()) return; SdlTtf.PInvoke.CloseFont(this); } }