/// <summary> /// Creates a copy of another font with its own state. /// </summary> /// <param name="prototypeFont"></param> public Font(Font prototypeFont) { Require.ArgumentNotNull(prototypeFont, nameof(prototypeFont)); core = prototypeFont.Core; state = prototypeFont.state.Clone(); }
/// <summary> /// Creates a copy of a another font with its own state and style. /// </summary> /// <param name="prototypeFont"></param> /// <param name="style"></param> public Font(Font prototypeFont, FontStyles style) { Require.ArgumentNotNull(prototypeFont, nameof(prototypeFont)); core = prototypeFont.Core; state = prototypeFont.state.Clone(); state.Style = style; }
/// <summary> /// Creates a copy of another font with its own state. /// </summary> /// <param name="prototypeFontCore"></param> public Font(IFontCore prototypeFontCore) { Require.ArgumentNotNull(prototypeFontCore, nameof(prototypeFontCore)); core = prototypeFontCore; }
/// <summary> /// Creates a new, empty font object. /// </summary> /// <param name="name"></param> public Font(string name) { core = new FontCore(name); }