Mono on the Mac

As great as Mono can be allowing you to run .net application under Win, Linux, Mac and more.  There is a gotcha, if you intend to run on the Mac you can not use the Win forms.  As the Win forms have limited functionality on the Mac or just don’t run,  you are also required to install X11 on the Mac for starters.  What you will have to do is to use the Gtk# UI libraries instead as they are by far more mature in Mono on the Mac.  The strange part is that the Win forms work fine on the linux desktop under Mono.

This doesn’t make any sense, does it ?    If you want cross platform UI application that you intend to run under Mono including on the Mac you need to write it that way from the start, use Mono and Gtk# to develop.  That means for you MS VS .net developers you can’t use your favorite VS editor, at least not out of the box.  You have to get something else like MonoDevelop.   You also have to think about it if you have an old application that you want running under Mono on the Mac, you will have to go in and rip out the Win forms and replace them with the Gtk# forms.

As they put it on the Mono website,

There were two previous attempts to implement System.Windows.Forms in Mono. These initial attempts were done on top of other toolkits: first Gtk, then Wine. Each one had its share of problems, causing it to be abandoned.

Read more…

I’m not bashing Mono by any means, I think it’s a great effort and well worth investing some time using Mono.  Even getting involved if your so inclined.  There is just that gotcha about using Win Forms that I wanted to point out to the unaware Win C# developers.

Leave a Reply