-1

How do I develop a GUI for my MonoMac applications? I can't find any option in MonoDevelop.

Scott
  • 21,211
  • 8
  • 65
  • 72
LearningAsp
  • 351
  • 1
  • 2
  • 12
  • You'd better revise your question. If you intend to write a GUI application that runs on Mac OS X, then GTK#, MonoMac, and even Windows Forms are all possible approaches. Then only difference is MonoMac app will look native there, while other apps are of alien-look. – Lex Li Oct 05 '12 at 12:36

2 Answers2

1

You can only create a MonoMac application on Mac OS X within MonoDevelop, and then use Interface Builder (or Xcode 4+) to modify the GUI. More information can be found on the developers' blogs, such as

http://mjhutchinson.com/journal/2010/06/09/monomac_in_monodevelop

This is quite similar to MonoTouch development.

Lex Li
  • 60,503
  • 9
  • 116
  • 147
  • Both applications for iOS and OS X use Cocoa as UI framework, so Xcode is used to build Cocoa based GUI (*.xib files). – Lex Li Oct 05 '12 at 12:28
  • What is the difference between MonoMac Project and Gtk@ 2.0 Project? – LearningAsp Oct 05 '12 at 12:31
  • A MonoMac project is a GUI project that utilizes Cocoa. The project template will include necessary references + a sample Cocoa UI. However, a GTK# project does not utilize Cocoa but GTK#. GTK# is a cross platform UI framework (native on Linux, but alien on other OS). – Lex Li Oct 05 '12 at 12:34
  • Real time problem is that ,I have developed an app in c# for windows ,now acc to clients requirement ,he need it to run on mac also ,so I have to reform it for MAC OS ,the main problem is coming that I have used the controls like Tab ,or List in my project ,but I cant find such controls in Widgets option. – LearningAsp Oct 05 '12 at 12:36
  • What does your original project use as UI Framework? If you use Windows Forms, then it can be ported to OS X and Linux with some efforts (such as http://codebetter.com/patricksmacchia/2011/11/07/real-world-feedback-on-a-net-to-mono-migration/), you might not need to completely rewrite GUI using MonoMac. If you intend to rewrite in MonoMac, you will have to learn Cocoa bit by bit, http://developer.apple.com/library/mac/#documentation/Cocoa/Conceptual/CocoaFundamentals/WhatIsCocoa/WhatIsCocoa.html#//apple_ref/doc/uid/TP40002974-CH3-SW16 – Lex Li Oct 05 '12 at 12:53
  • yes it is WinForms ,so in quick recap ,I have to download Xcode ,Open a new project for MonoMac in Monodevelop,Design Forms in Xcode ,Then Code in Monodevelop???...Please reply – LearningAsp Oct 05 '12 at 13:41
  • LexLi ,Do Xcode have alternative for every control in Visual Studio? – LearningAsp Oct 08 '12 at 12:04
  • Apple has a different view of UI design, so though you can find most common controls, such as buttons and so on, you should not expect all. The link I pasted previous contains Apple's guide on Cocoa,which tells you how to understand its philosophy. – Lex Li Oct 08 '12 at 12:26
  • LexLi can I use Wine Bottler for my .net windows applicationapplication in MAC OS – LearningAsp Oct 10 '12 at 14:11
  • Don't know if it is flawless (probably some known bugs, or moderate performance). You might try it out. But generally speaking, fully migration to Mono is the best option. – Lex Li Oct 10 '12 at 22:44
0

Gtk# I guess. Make sure you has that installed

Need4Steed
  • 2,170
  • 3
  • 22
  • 30
  • Ya ,while creating new monomac it gives the option for Gtk# ,but problem is that ,it doesnt have controls like listbox or tab – LearningAsp Oct 05 '12 at 11:35
  • I don't own a Mac, but I assume monodevelop should work the way on all platforms. In your solution tree there is a User interface folder, your ui form resides there. And under the View menu there is a `Visual design` option, select that will bring up the design perspective, then you got all controls(widgets) on the right side of the editor. I believe the `tab` is called notebook in Gtk#, though. – Need4Steed Oct 05 '12 at 12:08
  • real time problem is that ,I have developed an app in c# for windows ,now acc to clients requirement ,he need it to run on mac also ,so I have to reform it for MAC OS ,the main problem is coming that I have used the controls like Tab ,or List in my project ,but I cant find such controls in Widgets option. – LearningAsp Oct 05 '12 at 12:22
  • If you mean the WinForms equivalent, gtk is a very completed GUI tool kit, I think almost every WinForms control has its counterpart in Gtk#, your just need to learn them first. For example the layouts, Gtk employed hbox/vbox which WinForms doesn't have, but imho the Gtk's approach is much better. MonoDoc will be your friend. Or you can keep using WinForms, mono's implementation of WinForms works on OSX as well. I just don't know how good it works. It's kinda sluggish and flickering on linux if your gui isn't too complicated I suggest you reimplement it in Gtk#. – Need4Steed Oct 05 '12 at 12:40
  • yes it is WinForms ,so in quick recap ,I have to download Xcode ,Open a new project for MonoMac in Monodevelop,Design Forms in Xcode ,Then Code in Monodevelop???...Please reply – LearningAsp Oct 05 '12 at 13:42