المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : Buttons look different with DirectX



C# Programming
07-23-2009, 06:40 PM
I've downloaded the source code available at http://www.codersource.net/published/view/328/directx_programming_in.aspx[^ (http://www.codersource.net/published/view/328/directx_programming_in.aspx)]

I've added this code to the end of the constructor:

Button b = new Button();
b.Name = "Foo";
b.Text = "Foo";
b.Size = new Size(74, 23);
b.******** = new Point(12, 12);

this.Controls.Add(b);

But the button looks boring: http://img196.imageshack.us/i/blahulg.jpg/[^ (http://img196.imageshack.us/i/blahulg.jpg/)]

With the regular graphics it looks nice: http://img196.imageshack.us/i/prettyf.jpg/[^ (http://img196.imageshack.us/i/prettyf.jpg/)]

How do I get the DirectX rendered buttons to look like the regularly rendered buttons?