예제 #1
0
 /// <summary>
 /// Fills a <see cref="D2DFontPathData"/> to current <see cref="RenderContext"/>.
 /// </summary>
 /// <param name="context">The <see cref="RenderContext"/> to fill to.</param>
 /// <param name="brush">The <see cref="D2DBrushBase"/> to use.</param>
 /// <param name="path">The <see cref="D2DFontPathData"/> to fill.</param>
 /// <param name="offsetX">The X offset on target <see cref="RenderContext"/>.</param>
 /// <param name="offsetY">The Y offset on target <see cref="RenderContext"/>.</param>
 /// <param name="yCorrection">If <see langword="true"/>, apply automatic Y correction: y(real) = offsetY + lineHeight. If <see langword="false"/>, the Y value stays untouched.</param>
 public static void FillPath(this RenderContext context, ID2DBrush brush, D2DFontPathData path, float offsetX, float offsetY, bool yCorrection)
 {
     if (yCorrection)
     {
         offsetY += path.LineHeight;
     }
     path.Fill(context, brush, offsetX, offsetY);
 }
예제 #2
0
 public static void FillPath(this RenderContext context, ID2DBrush brush, D2DFontPathData path)
 {
     path.Fill(context, brush);
 }