Friday, September 2, 2011

Mono Touch and Mono for Android

I am supposed to write something on Linguistics now, but my plans fail every time when I come to a topic which love somehow. Mono is a one of the topics I always love to explore and talk about. It is the only thing which links me to programming on Linux because I can use my limited C# programming skills in MonoDevelop using Mono. It is a great application, and despite criticism from certain open source 'lovers', the merger of original company to Novell and now separation as Xamarin, this project kept on going. I am in love of this project and C#.

Once upon a time Mono was considered a rival of Java and other Virtual Machine based programming languages in the open source world. It was debated, re-debated and criticized. I remember the time when Ubuntu was even criticized on including mono packages in default installation CD. But those were simpler times. There were no 'intruders' in Adam's Heaven, there were no Tablets and so called touch devices. There was no Android. There was no hype to buy iPads, ThinkPads, TouchPads and like. So, all that people talked about was how much C# has been implemented by Mono, how much is there chance of Microsoft suing Novell over its patents regarding C#, how MoonLight is gonna fail, what kind of new applications are built on Mono lately, and whether Linux distros should adopt F-Spot, Banshee etc etc. The life was simpler at that time.

And now, when market is flooded by touch devices and people are mad to have one. There are new platforms and new software development kits. iOS is providing and promoting Objective C on its own SDK, Android is promoting its own SDK. Although Windows Phone is out there, but its only on 1% devices still in US (as I was reading somewhere today). Its true as far as Windows Phone is alive C# is alive (somehow). The libraries may change, names may vary whether it is Windows Presentation Foundation or SilverLight but the underlying language syntax would remain same. But this is about Windows world. What about Mono and Linux? As far as I know, Mono could never be a main stream application development framework in Linux world. It was appreciated by many, it was used by many, it produced very good and popular applications e.g. Banshee (I really liked this elegant media player), but the fact is that (for desktop users at least) applications written in Python or other such languages keep on appearing more often as compared to Mono and C# based applications. So it was natural to move towards touch devices for Mono to create its existence in a wider space.

There were other reasons as well. Mono always tried to target those developers who had C# skills and now wanted to create enterprise or other applications on other platforms e.g. Mac, Linux. Mono promised to provide support for porting existing .Net applications, to develop new ones, and to provide commercial support for Suse Linux Enterprise. The same theme was carried forward when Mono moved to Mono Touch. The idea is fairly simple, as the website also states that "use existing skills to create native iOS applications". They had good experience in joining C code of GTK with C# code of Mono to create GTK#, and joining other Gnome APIs to C# Mono framework. They've used the expertise to link Objective-C to existing Mono framework. You write in C# but the code generation would be in Objective-C. That's very cool idea, you do not have to re-learn Objective-C and a hell lot of APIs specific to iOS platform. Simply use Monodevelop to create an App and deploy it on the App Store.

Same is the case with Mono for Android. A few years back there were efforts to convert Java code to C#, and vice versa using IKVM and this was used on Mono also. Developers might be still using this technology to call Java APIs through Mono on a C# application. But the point here to mention was that Mono is trying to do something similar regarding Mono for Android. Most of the code for Android is in Java, so the Apps require Java and Google's platform specific APIs for Android. Mono for Android provides same thing here as well, as it does for iOS. It translates the code written in C# to one that is acceptable by Android.

This way, Mono is being alive and going forward. I have my best wishes that this platform should keep going on this way on new platforms. Thus the original i.e. Mono for PCs can be guaranteed, because no one will develop Mono if there is no money. So best of luck Mono. I love you ;-)

No comments:

Post a Comment