[Mono-winforms-list] ControlPaint.DrawReversibleFrame not working?

Jonathan Pobst monkey at jpobst.com
Tue May 22 17:17:09 EDT 2007


It seems to be working for me on Mono on Windows: 
http://img377.imageshack.us/img377/5893/reverserk4.png.

What OS and Mono version are you using?

Jonathan


Jurek Bartuszek wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Hi,
> 
> I've noticed that System.Windows.Forms.ControlPaint.DrawReversibleFrame
> has recently been implemented. I've built and run the following code:
> 
> using System.Windows.Forms;
> using System.Drawing;
> 
> namespace Testing
> {
>         public class MainForm : Form
>         {
>                 public MainForm()
>                 {
>                         this.Text = "test";
>                         this.Width = 500;
>                         this.Height = 500;
>                 }
> 
>                 protected override void OnPaint(PaintEventArgs e)
>                 {
>                         Rectangle r = this.RectangleToScreen(this.Bounds);
> 			r.Offset(50, 50);
>                         ControlPaint.DrawReversibleFrame(r, Color.Black,
> FrameStyle.Thick);
>                 }
>         }
> 
>         public static class Entry
>         {
>                 public static void Main(string[] args)
>                 {
>                         Application.Run(new MainForm());
>                 }
>         }
> }
> 
> I know that OnPaint is not the best place to draw this frame, but that's
> solely for testing purposes and the result is that the frame is not
> being drawn at all. Any ideas what might be wrong?
> 
> Best regards,
> Jurek Bartuszek
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.7 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
> 
> iD8DBQFGUw3e6l8uJkeTVlMRAleHAJ9BNNLZigG0EugStHVJYnYlr66e7wCgwBFx
> o1LToKNdYNHYDKoFBV29e1Q=
> =XXZI
> -----END PGP SIGNATURE-----
> _______________________________________________
> Mono-winforms-list maillist  -  Mono-winforms-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-winforms-list
> 
> 



More information about the Mono-winforms-list mailing list