aewarnick Posted November 27, 2003 Posted November 27, 2003 How do I convert the Pen.Width property to a pixels unit? Quote C#
*Gurus* divil Posted November 28, 2003 *Gurus* Posted November 28, 2003 It should be in pixels unless you've changed the scaling transform of the graphics you're drawing to. Quote MVP, Visual Developer - .NET Now you see why evil will always triumph - because good is dumb. My free .NET Windows Forms Controls and Articles
aewarnick Posted November 28, 2003 Author Posted November 28, 2003 Yes, I found that it was not the Pen it was how DrawRectangle draws the lines!!!! It is very annoying!!!!!!! Here is the rectangle I have to use to draw a border: this.BorderRect=new Rectangle(this.borderWidth/2, this.borderWidth/2, this.Size.Width-this.borderWidth, this.Size.Height-this.borderWidth); The top and left edges start the line in the middle and move out half and half. The right and bottom edges start on the inside and draw out!! Why? Quote C#
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.