News for hackers. Stuff that matters.
Re:Ask HN:I want to build desktop application but dont know ... by pornel on Friday September 24, 2010 @06:53AM (#1723282)
Just a note: from Mac user perspective cross-platform often means second-rate.

Portable toolkits just copy superficial look of Cocoa controls, but don't mimic "feel" part correctly. Not all mouse interactions and keyboard shortcuts work "right".

And even if your toolkit uses real Cocoa controls, there's still problem of window layout and UI design patterns, which aren't portable to Mac OS X (e.g. non-destructive preferences don't have OK/Apply buttons, drag'n'drop is expected almost everywhere, OK/Cancel are in reverse order than on Windows, etc.)

e.g. do you know OS X has separate clipboard for search fields? Cmd+E/Cmd+G. I like it and use it, but it doesn't work in "fake" Mac apps.

If you want to make good portable app that supports Mac well, then separate UI from the rest of the application and on Mac add Cocoa GUI (you don't need ObjC, you can use PyObjC or MacRuby).

Re:Ask HN:I want to build desktop application but dont know ... by cjg on Friday September 24, 2010 @07:21AM (#1723322)
The OP didn't say he wanted to make a cross-platform app or a portable one.
Re:Ask HN:I want to build desktop application but dont know ... by VBprogrammer on Friday September 24, 2010 @07:57AM (#1723369)
He also didn't specify which platform he was targeting. A lot of the points pornel mention apply equally to GUI toolkits running on Windows or Linux. You sacrifice some control in order to get cross-platform compatibility (as you have to do with certain CSS / Javascript elements). Java is probably the worst of all worlds in terms of the look and feel of its de-facto standard GUI library.
Re:Ask HN:I want to build desktop application but dont know ... by umenline on Friday September 24, 2010 @10:09AM (#1723654)
well cross platform is a dream , but i do know its so hard when you working with desktop app. my toolkit is Qt. i guess first i will go with windows.
Re:Ask HN:I want to build desktop application but dont know ... by davidw on Friday September 24, 2010 @04:26AM (#1723082)
As someone with a fair amount of Tcl and Tk experience, I think the web is the way to go. It's simply faster and cheaper to develop and deploy with. Fix a bug? All you have to do is upload a new version to the server.

Here's patio11 on desktop vs web: http://www.kalzumeus.com/2009/09/05/desktop-aps-versus-web-a...

That said, Tcl and Tk are a fun, fast way to hack up little applications if you need something local.

Re:Ask HN:I want to build desktop application but dont know ... by LeBlanc on Friday September 24, 2010 @01:23PM (#1724450)
Or you could do something like the Notch, the developer of Minecraft did. The MineCraft desktop app checks with the server to update itself every time it loads. This is very common for multiplayer games. Giving your desktop app the ability to store data on the server is also a great idea.

I really like the idea of desktop/web hybrid apps like Dropbox. You can get the best of both platforms.

Re:Ask HN:I want to build desktop application but dont know ... by SandB0x on Friday September 24, 2010 @04:51AM (#1723119)
Most definitely. Eg I'm not happy to rely on having a constant internet connection for editing photos or doing some writing while on holiday, and even with a connection in both these cases the desktop options are much better.

I recommend learning the QT framework. It's cross-platform, unlike .NET, has very well designed libraries, and bindings for a bunch of languages if you don't want to write in C++.

It's nice if a desktop program syncs to an online service though (eg Picasa).

Re:Ask HN:I want to build desktop application but dont know ... by maguay on Friday September 24, 2010 @05:43AM (#1723187)
1+ for online sync. Keeping your data available everywhere is one of the biggest things most of us like about webapps. Evernote is a great example of desktop + mobile + web syncing synergy.

Of course, this depends on what your app is doing. Every useful app doesn't have to sync, or even create data that you'd want to sync. That said, most apps could greatly benefit from syncing, no matter what platform they're on.

Re:Ask HN:I want to build desktop application but dont know ... by dazzawazza on Friday September 24, 2010 @05:07AM (#1723139)
+1 for QT. I picked it up for the first time a few weeks ago and built a basic spotify clone[1] in one week for fun. Very nice API and as close to native look as I have ever seen from a XP framework.

I think there is a place for native applications, as long as you've got a niche that needs filling. The web isn't the answer to everything.

[1] - http://www.executionunit.com/blog/2010/metalify_spotify_clon...

Re:Ask HN:I want to build desktop application but dont know ... by umenline on Friday September 24, 2010 @10:06AM (#1723643)
I did something similar , You-tube player for private use i hate the you-tube personal channel , and all its music editing features very useful to me...using Qt.
Re:Ask HN:I want to build desktop application but dont know ... by maushu on Friday September 24, 2010 @05:44AM (#1723188)
As Tichy mentioned, there are the offline web apps, basically the application works offline and only uses the internet connection if it is available. It is even possible to have an application almost indistinguishable from a desktop application depending on the browser (Chrome, iPhone/iPod, etc)

The advantages of using this platform is that it is cross-platform, the application will have a really long longevity and "everyone" knows javascript (which might be a good or bad thing).

Re:Ask HN:I want to build desktop application but dont know ... by Tichy on Friday September 24, 2010 @05:15AM (#1723149)
What about offline webapps?
Re:Ask HN:I want to build desktop application but dont know ... by umenline on Friday September 24, 2010 @05:22PM (#1725486)
like? can you give example?
Re:Ask HN:I want to build desktop application but dont know ... by Tichy on Saturday September 25, 2010 @04:24AM (#1726595)
I don't use any, but I expect to see more of them in the future. I think GMail is an offline web app? I am not a GMail user.

It hasn't been so long that browsers come with the necessary APIs. GMail used their own plugin in the beginning (Google Gears).

Re:Ask HN:I want to build desktop application but dont know ... by umenline on Friday September 24, 2010 @09:59AM (#1723626)
I know C++ Qt , i just love it ! 4.7 is out now...
Re:Ask HN:I want to build desktop application but dont know ... by gregschlom on Friday September 24, 2010 @06:02AM (#1723218)
I definitely recommend learning C++ and Qt. At first, I was quite afraid of learning C++, it's supposed to be a difficult language, without all the niceties of python, javascript, php and the like.

But actually Qt really adds a great abstraction layer that makes coding in C++ as enjoyable as Java, for example. Easy string manipulation, easy iterators, the signal/slot stuff is awesome, and the community is great.

Yes, HTML5 is here, but there is still a lot of stuff that you can't do with HTML/CSS/javascript. So my advice is: go for it. You won't regret.

Re:Ask HN:I want to build desktop application but dont know ... by arethuza on Friday September 24, 2010 @04:54AM (#1723124)
Unfortunately the answer is "it depends":

- What kind of application do you want to build?

- What OS platforms will the users have?

- What experience do you have or is there a platform you particularly want to learn?

If you can narrow it down to one platform then most of these have pretty decent tools - if you want to support multiple platforms then things get interesting.

Re:Ask HN:I want to build desktop application but dont know ... by djhworld on Friday September 24, 2010 @04:37AM (#1723101)
What operating system do you want to develop for? I've found desktop application development quite enjoyable on OSX when using things like InterfaceBuilder and Objective-C, and those skills can be transferable for iPhone development too!
Re:Ask HN:I want to build desktop application but dont know ... by umenline on Friday September 24, 2010 @10:16AM (#1723691)
i guess windows maybe mac latter
Re:Ask HN:I want to build desktop application but dont know ... by sown on Friday September 24, 2010 @05:03AM (#1723134)
You can Visual Studio Express for Windows for free now days. XCode for Mac is free, as is the GNOME environment for Gnome/Linux systems. I would suggest you look for tutorials surrounding those environments.
Re:Ask HN:I want to build desktop application but dont know ... by statictype on Friday September 24, 2010 @05:54AM (#1723207)
There are many toolkits to use. It depends on the type of app you're writing and who's going to use it and what platform its for.

Is it mainly for Windows users? Might want to go with .NET. There are free versions of Visual Studio available for this purpose.

Is it for Linux systems? GTK with C/Python or Qt with C++/Python maybe a better option. All the libraries and compilers are free. Mono (an open source .NET implementation) also works well on Linux.

If its for the Mac then Objective-C + Cocoa is the de facto method. The IDE, Xcode is a free download from Apple. You can also get python bindings for Objective-C.

If it has to run on many platforms then you might want to think of a cross-platform toolkit.

If the program has a very simple UI, then you can probably get away with using wxWidgets or QT with Python.

If UI is more involved, then you will probably want to write the front-end for each in it's own native framework.

Re:Ask HN:I want to build desktop application but dont know ... by catch404 on Friday September 24, 2010 @05:37AM (#1723176)
I've been using wpf and xaml for making nice quick applications for windows. I need a dsl for the xaml or a ruby wrapper for the API - Which I'm currently investigating. Too bad mono doesn't support wpf.

I've been looking at shoes by _why with some interest but think a dsl/swing (jvm) comboo would be the quickest and easiest cross platform option.

Re:Ask HN:I want to build desktop application but dont know ... by ericz on Friday September 24, 2010 @04:35AM (#1723099)
.NET and C# make developing Windows desktop apps ridiculously easy. There is a .NET API for just about everything and you can get started for free with Visual Studio Express.

As a bonus Visual Studio has awesome auto-completion features and is a great WYSIWYG GUI editor.

MS really ought to pay me =p

Re:Ask HN:I want to build desktop application but dont know ... by mahmud on Friday September 24, 2010 @05:32AM (#1723170)
What if he wants to run his app on Unix and Mac?

Qt via Python or Ruby bindings might be the best way to go.

Re:Ask HN:I want to build desktop application but dont know ... by poloniculmov on Friday September 24, 2010 @06:49AM (#1723276)
Qt via Mono on Unix/Mac and WPF on Windows. As long he uses MVP or some other pattern to decouple the presentation layer from the business layer. Sure it will be harder to maintain 3 apps, but having apps that follow the platforms guidelines is worth it.
Re:Ask HN:I want to build desktop application but dont know ... by andrewf on Friday September 24, 2010 @06:55AM (#1723286)
I think doing more than one UI upfront is an optimistic mistake.

Pick a primary platform and optimise it. Maybe do a less-than-awesome port, if you're eager. If, down the road, your experience with the primary platform leads you to believe there is a large market for the taking, then you can weigh up improved sales versus development effort for a truly excellent implementation on another platform.

Regarding Qt on the Mac: I've done it before. It would be my less-than-awesome port. If you're not using Cocoa on the Mac, making a UI on par with a "native" app is a sisyphean task: you're fighting uphill and you never quite get there.

Re:Ask HN:I want to build desktop application but dont know ... by cammil on Friday September 24, 2010 @04:46AM (#1723114)
What do you guys think of java as a language for desktop applications? I have a web app that I already use java for, and it could use a tiny desktop app to leverage it. I say tiny because all it will do is receive web requests which inform the user that they should visit the main web app.
Re:Ask HN:I want to build desktop application but dont know ... by cjg on Friday September 24, 2010 @07:28AM (#1723338)
The biggest problem is deployment. It's fine if you are happy with web start, but if not then creating an .exe isn't trivial. One of the biggest issues relates the the JVM. Are you going to assume that your users have a particular JVM installed? If so, which one? What if they don't have it? Or you can package the JVM into the exe - although this will make creating that exe more difficult and make it significantly larger.

I would love a Java tool that could analyse your app and create an exe that contained a cut-down JVM. Cut-down in that any classes that aren't used (directly or indirectly) are omitted. This is not an easy thing to do given runtime control of class loading.

Re:Ask HN:I want to build desktop application but dont know ... by mahmud on Friday September 24, 2010 @05:35AM (#1723175)
Java is excellent for cross-platform desktop GUI. Eclipse's SWT looks perfect, but careful not to get dragged into their elaborate "Rich Client Platform" crap. If you can manage to use just SWT, you will win.

Having said that, Swing, the offical GUI toolkit can be themed to look quite native. And Java Webstart is an absolute win: one-click deployment on every platform.

Re:Ask HN:I want to build desktop application but dont know ... by Sandman on Friday September 24, 2010 @06:02AM (#1723217)
Eclipse RCP can be challenging, and, quite frankly, overwhelming when you first start using it, but after a while, you begin to see the benefits that you get from developing your application on the RCP instead of doing it as a raw SWT app. That being said, there are situations where the RCP's provided solution to a problem you're having may be overly complex, and you're better off rolling your own solution.
Re:Ask HN:I want to build desktop application but dont know ... by lelele on Friday September 24, 2010 @05:00AM (#1723132)
It is a fine language. Java Web Start will help you distributing your desktop app.

Only drawback is the non-native GUI. However, I've heard the Eclipse team has made a framework with a native look-and-feel available.

EDIT: Well, if your app is tiny, I guess the different look-and-feel would not be an issue.

Re:Ask HN:I want to build desktop application but dont know ... by petervandijck on Friday September 24, 2010 @08:11AM (#1723391)
Java desktop apps almost always feel a little kludgy (in the UI), imo. Might be ok for tiny apps like yours.
Re:Ask HN:I want to build desktop application but dont know ... by borisk on Friday September 24, 2010 @04:42AM (#1723110)
IMHO there are a lot of opportunities in the desktop market. Most competent developers moved to Web apps and Linux long ago and left the Windows desktops lacking in many areas.

If your looking to low level system stuff or prioritize app speed have a look at Visual C++. Even Google used if for Chrome.

The most advanced UI framework I've seen is WPF. It has GPU acceleration; compatible, but separate tools for developers and designers; lots of 3rd party controls; can run in browsers through Silverlight.

Both these unfortunately come from Microsoft. You can get the dev tools for free or at low cost through programs like BizSpark.

Re:Ask HN:I want to build desktop application but dont know ... by lelele on Friday September 24, 2010 @04:53AM (#1723121)
> If your looking to low level system stuff or prioritize app speed have a look at Visual C++. Even Google used if for Chrome.

As an experienced C++ developer I recommend you avoid C++ at all costs, even if you are an experienced C++ developer. A blend of C and another high-level language is a better choice.

Re:Ask HN:I want to build desktop application but dont know ... by umenline on Friday September 24, 2010 @10:15AM (#1723676)
Im using at my day job Qt with Visual studio express 2008 and its a great combination for developing. im doing small tools. its very fast with Qt
Re:Ask HN:I want to build desktop application but dont know ... by jbarham on Friday September 24, 2010 @11:46AM (#1724004)
Adobe's Lightroom is a good example of a successful hybrid language app as a big chunk of it is written in Lua. Here's a presentation on its architecture: http://www.troygaul.com/LrExposedC4.html
Re:Ask HN:I want to build desktop application but dont know ... by maguay on Friday September 24, 2010 @05:39AM (#1723181)
You can actually get Visual C++ tools for free from Microsoft, since there's a C++ Visual Studio Express available. Check http://www.microsoft.com/express/Windows/ ... there's quite a bit out there for free nowadays from Microsoft. Though it would be great to see more WPF apps, and you'd need to look into Expression Studio for that. Can't wait to see what you build; the desktop market has definitely been neglected on all platforms for too long.
Re:Ask HN:I want to build desktop application but dont know ... by Tichy on Friday September 24, 2010 @05:19AM (#1723152)
Personally, since I come from a web dev background, I would probably look into Adobe Air or some of the frameworks that allow you to wrap up web applications into desktop apps (don't recall any names atm, but I think Mozilla has one?).
Re:Ask HN:I want to build desktop application but dont know ... by superted on Friday September 24, 2010 @05:39AM (#1723182)
You might be thinking about Mozilla Prism (http://prism.mozillalabs.com/)
Re:Ask HN:I want to build desktop application but dont know ... by jon914 on Friday September 24, 2010 @04:24AM (#1723074)
There's still a place for desktop applications. It depends upon what you're building and whether that's a fit for the medium.

For example, I've built game creation tools. These are better suited for the desktop because of the complex interactions and user data involved.

There are plenty of startups that have built their software partially or wholly on the desktop such as Dropbox and Unity3D. For small developers, building desktop clients to popular web services like Twitter is another relevant path to take.

Re:Ask HN:I want to build desktop application but dont know ... by umenline on Friday September 24, 2010 @10:38AM (#1723760)
Hi this is exactly what i was thinking and your application looks great! i once was thinking about the same idea . even using the Scratch method for conditions and loops wish you best lock ! what framework/tools do you use?
Re:Ask HN:I want to build desktop application but dont know ... by jon914 on Friday September 24, 2010 @12:12PM (#1724123)
Thanks! The application is actually written in Java and uses Swing.

Not the sexiest thing to use, but Swing is very customizable, and I wanted to ensure that it was cross-platform from the get go. In addition to that, we also have an ActionScript-based player/engine and invoke the Flex SDK to compile auto-generated AS3 source into a SWF.

The app also communicates with a server-side webapp to provide the resource sharing, so we've got a little bit of everything in our technology stack. ;)

Re:Ask HN:I want to build desktop application but dont know ... by umenline on Thursday September 30, 2010 @09:14AM (#1743123)
hey , i just want to say the gui of your application is looking great and it is fast! how did you do that ?
Re:Ask HN:I want to build desktop application but dont know ... by umenline on Monday September 27, 2010 @08:07AM (#1731399)
can i join the beta?
Re:Ask HN:I want to build desktop application but dont know ... by tjansen on Friday September 24, 2010 @04:40AM (#1723105)
Depends a bit on what you mean with "a place". There's certainly a market, at least when you write a Windows application. I guess most people don't care much where their application runs, at long as it help them to do their work (or have fun, depending on the app) and the app does not cause any trouble. The latter is the reason why traditional desktop apps are slowly disappearing, being replaced by web apps or at least controlled environments such as iOS's app store.
Re:Ask HN:I want to build desktop application but dont know ... by dasil003 on Friday September 24, 2010 @04:43AM (#1723111)
The latter is the reason why traditional desktop apps are slowly disappearing

Is it? I thought the main reasons were: no install, cross-platform, data available everywhere.

Re:Ask HN:I want to build desktop application but dont know ... by tjansen on Friday September 24, 2010 @07:46AM (#1723357)
Installing and data availablity are a huge part of what I meant with 'trouble'.
Re:Ask HN:I want to build desktop application but dont know ... by hcho on Friday September 24, 2010 @04:49AM (#1723118)
No, there is not. Unless of course, the application has a very good reason to be a desktop app.

Downloading and installing adds extra friction to your distribution, which you can live without for most of the cases.

Re:Ask HN:I want to build desktop application but dont know ... by herval on Friday September 24, 2010 @06:57PM (#1725712)
Looks like no o e mentioned Adobe Air. Quite easy to pick up and allows you to go cross platform with much less hassle than java, for instance (the runtime is smaller/easier to autoinstall, etc)
Re:Ask HN:I want to build desktop application but dont know ... by astrofinch on Friday September 24, 2010 @08:01AM (#1723373)
If you're sympathetic to claims that you should build for the web, you might want to try Pyjamas. It advertises being able to simultaneously target both the browser and the desktop.
Re:Ask HN:I want to build desktop application but dont know ... by 16s on Friday September 24, 2010 @12:41PM (#1724262)
I suggest trying wxwidgets or FLTK. And yes, desktop is not dead, far from it.
Re:Ask HN:I want to build desktop application but dont know ... by umenline on Saturday September 25, 2010 @01:49AM (#1726419)
i really like the FLTK framework , but its looks not so pretty as a gui