Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I'm frustrated trying to choose a language; here are the requirements:

  1. Desktop application. For Windows, it would live in the System Tray (like Skype).
  2. I'm a single programmer so I only will have time to do it once and do it right.
  3. Windows is most important OS and needs to start there, but eventually needs to be cross platform and run on Apple/Linux/mobile so I'd have to use Flex or port it to other OSes.
  4. Needs to be running all the time, like Skype, waiting for incoming messages.

I know there is no right answer... just looking for input.

I can effectivly program in any of those languages.

Need to bet on approach that has highest chance of success and most ROI.

share|improve this question
What languages/platforms are you already familiar with? –  Anna Lear Oct 1 '10 at 19:35
I think the "Next Big Chat" will be an web-application/mashup. Think of Omegle, ChatRoulette and the fact that Google is implementing VoIP telephony for Gmail. See news.cnet.com/8301-17939_109-20014734-2.html –  Jonas Oct 1 '10 at 21:08
add comment

4 Answers

C#/WPF or Java. I'd choose C#.

Why? There's just so much more innovation in C#. The speed of development will be quick, you'll be able to build the application up really nicely with good unittesting/IoC/etc... With Mono/.NET you can port it to *nix/mac. It'll work easily with minimal porting on Windows7 Phone.

Java's nice because it inherently runs on most OS'es, similar level of tooling/practices as C# although not as active. High level of support. But Java's UI & UI Libs (3rd party) suck hardcore.

share|improve this answer
Yes, I've never liked the look of Java UIs... I always wonder: "Why can't they get their UI act together?" My app has to look cool. –  Pete Alvin Oct 1 '10 at 21:22
AWT/Swing are garbage. Partly due to the shortcomings of the language falling behind. There's some 3rd party libraries that do a better job but I found the mostly cumbersome to use at best. –  Aren Oct 1 '10 at 21:42
Azureus (google.com/images?q=azureus+screenshot&biw=1280&bih=775) and Palantir (blog.palantirtech.com/2007/09/11/palantir-screenshots) were developed in Java. How "cool" an app looks has much more to do with the skill of the designer/developer than the language it's implemented in. "Default" mono apps look horrible on OS X too. –  Nate Oct 14 '10 at 19:51
@Nate: Well of course anyone can make things look good in any language, but the complexity is in question. Java's baked in UI Framework + Most 3rd party apps CAN build extremely nice UI's, but when you compare the programatic complexity of doing so to other frameworks you're just left in the dust. –  Aren Oct 14 '10 at 23:24
add comment

For a chat-type application, it seems like a UI that users will think of as nice is a necessity. That pretty much immediately rules out Java. Though maybe not quite as obviously and quickly, it pretty much rules out anything with Silverlight/.NET as well, when you factor in portability. Basically, with .NET you'd want to use WPF on Windows -- but Mono doesn't support that. You could use GTK+, but if you do Windows and Mac users probably won't like it much. If you want a nice, reasonably native-looking UI, you can manage that by using GTK+ on Linxu, MonoMac on the Mac/iPod/iPad, and WPF on Windows -- but by then, you're a long ways from the "do it once and do it right" requirement.

IMO, Adobe Flex isn't much of an option. You can use Adobe AIR to deploy a Flex web app to a desktop, but it's still basically a web app running on a desktop, not a desktop application. Since you're writing to a web-app API, you're pretty much stuck with all the limitations of a web app and can't do much to take advantage of its being a desktop app. Since you're deploying it to a desktop, you can't do much to take advantage of its being a web app either though. You end up with all the limitations of both, and none of the advantages of either.

Unfortunately, the only other choice you've given (using the Win32 API directly) is probably worse than any of the above. Along with relatively slow development, you get code that's quite non-portable and will need almost a complete rewrite to work on any other platform.

That means you pretty much need to consider something else. It seems to me that the obvious possibility would be C++ with Qt. Obvious advantages include:

  • Native look/feel on each platform.
  • Competitive productivity.
  • Excellent performance

The obvious shortcoming (that I can see) is lack of portability to two specific portable platforms: Windows 7 and Android phones. For better or worse, there is no one choice that supports both of these. Windows 7 phone is .NET only, and Android is Java only.

share|improve this answer
Silverlight is implemented entirely in mono (moonlight) - so don't rule it out so quickly. You won't be able to have all the features of WPF - but there's enough in silverlight to get a chat application working. –  Mark H Oct 1 '10 at 23:53
@sparkie: working, yes. "The next big [whatever]", not so much. Yes, if you have something that's new, different, and basically has huge intrinsic value, using Silverlight/Moonlight won't necessarily kill it -- but when you're entering an area that already has as many competitors as chat applications, you need something that's really good. In that situation, I'd consider using Silverlight/Moonlight risky at best. –  Jerry Coffin Oct 2 '10 at 0:12
add comment

Personal experience/expertise:

I'd dual-develop on OSX and Win32 using C++, with an abstraction layer on the native widgets. I'm willing to bet that's how Skype does it, and Skype looks pretty stinking good, unlike most cross-platform apps.

I wouldn't touch Silverlight or Flash/Flex with a 10ft pole from a boat across a moat. Silverlight may be antiquated in the next MS Big Refresh Thing, and Adobe seems to be the latest vector for malware.

.NET is okay if you're doing Windows-only, but I havn't heard that Mono is "that" good yet. Certainly last time I used Mono for developmenty things on OSX, it ran like a -1 - legged dog. Plus you have to consider the MS penchant for refreshing APIs and breaking last years hotness.


Your best bet for full cross-platform operation including mobiles is Java. Apple (Jobs?) doesn't like Flash, so if Flex/Flash is used, then you're out of luck on the iP(a|o)d. Java runs reasonably well with a hotspot optimizer, once you start it up, which is ideal for your situation. It also runs on OSX, iOS, and most mobiles I've heard of. Done right, it would look decent and be a single binary JAR. It also could be embedded in a web page without much grief if you wanted to bring that interface in.

share|improve this answer
What abstraction layer do you use? Is it commercially available? My app has to look reasonably cool, at least as good as Skype. Thanks for your real-world experience. I didn't really consider Java (I've never done any client work with it). –  Pete Alvin Oct 1 '10 at 21:24
My understanding is that Skype on Windows is written in Delphi. –  GrandmasterB Oct 1 '10 at 21:24
@Pete: I would roll my own. :P –  Paul Nathan Oct 3 '10 at 11:19
@GrandmasterB: Interesting! I guess they must just write against a protocol then. –  Paul Nathan Oct 3 '10 at 11:21
add comment

I would first consider the protocol you're going to use for the chatting - I would probably prefer to adopt an existing protocol like XMPP rather than writing one from scratch. This will improve the interoperability with existing apps and libraries, and perhaps save you an awful lot of time writing your own - it's also an extensible protocol, so you can add features that aren't there yet.

If you check out the available libraries for XMPP, there's plenty available for a number of languages. There's a few with Silverlight support with a price tag on them - and several Java libraries are completely free. You might perhaps want to take a look at them and compare whether these have the features you need, and whether they're written suitable for your app.

As for looking for ROI, you only need to look at the sheer quantity of chat clients (using XMPP or otherwise) to see that very few become mainstream. You really need to stand out to become popular - so I would perhaps initially target a market where there's a shortage or need for such client - perhaps something like the new Windows Phone 7 platform where there's a limited number of apps out there. If you wrote an app for the iPhone, you're really going to struggle to stand out above the hundreds of others doing the same thing. If this sounds reasonable, C# is probably the language of choice for that platform, and has the potential to run on any other platform (including iphone and android with mono). But if you're aiming more at those mobiles to begin with, they generally have better support for Java.

share|improve this answer
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.