GDI+ am CompactFramework
von Daniel Siegl | Abgelegt in Compact Framework, Windows MobileEDIT: see also Silvermoon – englisch post.
Es gibt einen super Post von Alex Feinmann (Opennet.cf) für einen GDI+ Wrapper am CompactFramework.
Unterstützt wird dabei nur Windows Mobile Professional – darum wird vermutlich auch von MS nichts derartiges geliefert.
Leider unterstützt diese Implementierung keine Rechtecke mit abgerundeten Ecken. Dazu habe ich aber etwas auf CodeProject von Arun Reginald gefunden.
Dann habe ich 3 kleine Methoden in die GraphicsPlus Klasse von Alex integriert – und angepasst und schon kann ich abegerundete Rechtecke am Windows Mobile zeichnen.
public GraphicsPath GetRoundedRectanglePath(float x, float y, float width, float height, float radius)
{
GpRectF rectangle = new GpRectF(x, y, width, height);
return GetRoundedRect(rectangle, radius);
}
public void DrawRoundRectangle(PenPlus pen,float x, float y,float width, float height, float radius)
{
GraphicsPath path = GetRoundedRectanglePath(x, y, width, height, radius);
DrawPath(pen, path);
}










15. Dezember 2008 um 16:36
[...] allen Pocket Pc’s mit Windows Mobile 5 und 6 gibt es GDI+ wie schon in einem anderen Post von mir erwähnt. Die Standard Controls im Compact Framework sind ja eher Grau in Grau – Abhilfe [...]
23. September 2009 um 14:49
[...] Just found the Silvermoon project on Codeplex after Frank pointed me there in Facebook. AWESOME!!! I always like fancy Control that I don’t have to handcraft like in the GDI+ Article. [...]
17. November 2009 um 17:22
Great info and good resources, thanks!
Dr.Luiji