NGraphics icon indicating copy to clipboard operation
NGraphics copied to clipboard

DrawText draws text above specified Rect

Open Henkoglobin opened this issue 10 years ago • 0 comments

Since ICanvas.DrawText accepts a Rect as its second parameter, I would expect it to draw the text INTO the specified Rect. However, both Android and iOS draw the text directly ABOVE it. This can be reproduced by drawing both the Rect and the Text:

    canvas.DrawRectangle(textRect, brush: Brushes.Green);
    canvas.DrawText(value.ToString(), textRect, _font, TextAlignment.Center, pen, brush);

NControl's implementation for Windows Phone, however, behaves exactly how I would expect it to.

Henkoglobin avatar May 28 '15 14:05 Henkoglobin