// Copyright (c) Six Labors. // Licensed under the Six Labors Split License. namespace SixLabors.Fonts.Tables.Cff { /// /// Represents an element in an font dictionary array. /// internal readonly struct FDRange { /// /// Initializes a new instance of the struct for FDSelect format 3. /// /// The first glyph index in the range. /// The font dictionary index for glyphs in this range. public FDRange(ushort first, byte fontDictionary) { this.First = first; this.FontDictionary = fontDictionary; } /// /// Initializes a new instance of the struct for FDSelect format 4. /// /// The first glyph index in the range. /// The font dictionary index for glyphs in this range. public FDRange(uint first, ushort fontDictionary) { this.First = first; this.FontDictionary = fontDictionary; } /// /// Gets the first glyph index in range. /// public uint First { get; } /// /// Gets the font dictionary index for all glyphs in range. /// public ushort FontDictionary { get; } /// public override string ToString() => $"First {this.First}, Dictionary {this.FontDictionary}."; } }