[Mono-winforms-list] Howto mix WinForms and Cairo?

Peter Dennis Bartok peter at novonyx.com
Fri Sep 2 12:30:40 EDT 2005


I'm not sure I understand what you mean with 'mix'. The cairo contexts we 
use are not accessible to your app (they are kept internal to libgdiplus). 
You should be able to use Mono.Cairo without any problems, assuming you're 
not trying to draw on Winforms' windows. That's a no-no, since you don't 
have access to the X drawables you'd need to setup a cairo context.
The proper way to do that is to use System.Drawing, which is compatible with 
Winforms. Whenever you want to draw on a window, you override OnPaint, and 
as part of the events, you get a System.Drawing graphics context With that 
context you can use any System.Drawing method to draw whatever you need.

Maybe a description of what exactly it is you are trying to do would help.

Cheers,
  Peter

-----Original Message-----
From: "Clemens Eisserer" <linuxhippy at gmail.com>
To: <mono-winforms-list at lists.ximian.com>
Date: 02 September, 2005 10:08
Subject: [Mono-winforms-list] Howto mix WinForms and Cairo?


Hi there,

I am trying to mix Cairo and WinForms, however I don't get it ;-)
Is this possible at all? A very basic example would be enough.

Thank you in advance, lg Clemens
_______________________________________________
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