public override FontMetrics GetFontMetrics(Font font) { return font.GetFontMetrics(); }
public override void DrawText(Image i, BoundingBox clip, AffineTransform trans, string s, Font f, Vec2 Loc, Pixel p) { f.Render(i, clip, trans, s, Loc, p); }
public abstract bool IsSupportedType(Font f);
protected FontMetrics(Font font) { this.font = font; }
/// <summary> /// Draw the specified Text, using the specified Font, /// in the specified Color, within the specified Bounds, /// at the specified Location, and on the specified image, /// making sure to take the transform into account. /// </summary> /// <param name="i">The Image to draw on.</param> /// <param name="clip">The BoundingBox to clip to.</param> /// <param name="trans">The Transform to apply.</param> /// <param name="s">The String to draw.</param> /// <param name="f">The Font to draw in.</param> /// <param name="Loc">The Location to draw at.</param> /// <param name="p">The Color to draw in.</param> public abstract void DrawText(Image i, BoundingBox clip, AffineTransform trans, String s, Font f, Vec2 Loc, Pixel p);
/// <summary> /// Get the FontMetrics for the specified font. /// </summary> /// <param name="font">Font to get the metrics for.</param> /// <returns>The FontMetrics for the specified font.</returns> public abstract FontMetrics GetFontMetrics(Font font);
public void DrawString(Vec2 loc, String s, FontSupport.Font f, int stringHeight, FontSupport.FontStyle flags, Pixel color) { FontSupport.FontManager.Instance.DrawText(this, null, null, s, f, loc, color); }