
TextPrinter layout when width, height are zero.
Posted Saturday, 9 May, 2009 - 00:05 by kanato| Project: | The Open Toolkit library |
| Version: | 0.9.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | minor |
| Assigned: | Unassigned |
| Status: | closed |
Jump to:
Description
On Windows, calling
printer.Begin(); printer.Print("My text", font, Color.Yellow, new RectangleF(0, 30, 0, 0)); printer.End();
works as I would expect, the width, height properties are ignored and the text is drawn at (0, 30). On OpenSuse 11.1 the text is drawn at (0,0).
Also on Windows I notice that if the rectangle is smaller than the text, the stuff outside the rectangle gets drawn at 0,0 when it should just be clipped.


Comments
#1
The first issue is a Mono GDI+ bug. This is likely to be fixed around the Mono 2.8 timeframe.
The only way to fix this on our side is to add a Mono.Pango-based IGlyphRasterizer to OpenTK.Utilities. If someone wishes to help with this, please make a post here.
I haven't been able to reproduce the second issue.
#2
Revision 1807 contains a workaround for the first issue. Working on the second.
#3
Second issue fixed in rev. 1809.
#4
Closing issues resolved in 0.9.8.