[Gtk-sharp-list] DrawingSample : how to run on OSX?

Davide Morelli davide.morelli at parser.it
Thu Jun 16 09:50:17 EDT 2005


Hi,

I am having problems executing the DrawingSample.exe sample from 
gtk-sharp-1.9.3 on  OSX 10.3

I don't know if these problems are due to
. a wrong installations procedure (I followed the wiki page on the mono 
portal as much as i could)
. PATH problems
 . whatever...

I can compile it but when I run it I get exceptions in 
System.Drawing.GDIPlus.

libgdiplus is working fine if I use it without gtk, (e.g: a 
System.Windows.Forms example)

In xterm I type:

export 
DYLD_LIBRARY_PATH=/sw/lib:/Library/Frameworks/Mono.framework/Versions/Current/lib/

then

mono DrawingSample.exe

the form appears and quickly disappears and I get this message:

Unhandled Exception: System.Reflection.TargetInvocationException: Exception 
has been thrown by the target of an invocation. ---> 
System.TypeInitializationException: An exception was thrown by the type 
initializer for System.Drawing.GDIPlus ---> System.DllNotFoundException: 
/Library/Frameworks/Mono.framework/Versions/1.1.7/lib/libgdiplus.dylib
in (wrapper managed-to-native) System.Drawing.GDIPlus:GdiplusStartup 
(ulong&,System.Drawing.GdiplusStartupInput&,System.Drawing.GdiplusStartupOutput&)
in <0x0011c> System.Drawing.GDIPlus:.cctor ()--- End of inner exception 
stack trace ---
in <0x00000> <unknown method>
in <0x00038> System.Drawing.Graphics:FromXDrawable (IntPtr drawable, IntPtr 
display)
in <0x00034> System.Drawing.Graphics:FromXDrawable (IntPtr drawable, IntPtr 
display)
in <0x00000> <unknown method>
in (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke 
(object,object[])
in <0x000c8> System.Reflection.MonoMethod:Invoke (System.Object obj, 
BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] 
parameters, System.Globalization.CultureInfo culture)--- End of inner 
exception stack trace ---
in <0x00168> System.Reflection.MonoMethod:Invoke (System.Object obj, 
BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] 
parameters, System.Globalization.CultureInfo culture)
in <0x00048> System.Reflection.MethodBase:Invoke (System.Object obj, 
System.Object[] parameters)
in <0x001f4> Gtk.DotNet.Graphics:FromDrawable (Gdk.Drawable drawable)
in <0x0005c> PrettyGraphic:OnExposeEvent (Gdk.EventExpose args)
in <0x0009c> Gtk.Widget:exposeevent_cb (IntPtr widget, IntPtr evnt)
in (wrapper native-to-managed) Gtk.Widget:exposeevent_cb (intptr,intptr)
in <0x00000> <unknown method>
in (wrapper managed-to-native) Gtk.Application:gtk_main ()
in <0x0000c> Gtk.Application:Run ()
in <0x00260> X:Main ()

thank you for any hint,
Davide. 



More information about the Gtk-sharp-list mailing list