Cross-Platform Desktop App Development: Choosing The Right Technology

August 06, 2015 24141 Views
← Back
Cross-Platform Development For Desktops: Choosing The Right Technology
Cross-platform development is usually understood as mobile app development (Android, iOS). For example, you may use PhoneGap, Xamarin or Titanium as the platform for your app. Or maybe choose ReactNative or NativeScript, which have been gaining popularity recently. However, operating systems for desktops (Windows, Mac OS, Linux) tend to be unjustly overlooked.

What really matters here is that in many cases businesses require desktop applications. Here we will try to outline advantages and drawbacks of the most common technologies for cross-platform development for desktops. We will consider business needs, functional requirements, and speed of development. We will also illustrate them with examples.

The biggest players on the market are Java, Adobe AIR, Haxe, QT, and such JavaScript-based solutions as NWJS, Electron and CEF. These solutions are popular worldwide, they have the biggest developer communities, but the main thing is, a lot of real, working, successful projects are based on them.

Desktop application development: JavaJava


This is the oldest approach to cross-platform software development. Its slogan says, "write once, run anywhere", and that perfectly applies to cross-platform development as a whole. As opposed to other platforms we are going to discuss today (except Haxe), Java has grown as one of the cross-platform programming languages.


Advantages:
• The oldest platform. It has an enormous community, an enormous amount of tools and third-party libraries that solve a rich variety of tasks, with the vast majority focusing on data processing.
• It is easy to find qualified specialists for support.
• Multithreading.

Drawbacks:
• Java virtual machine must be present on computers that run the application.
• Versioning. Drastically different versions of virtual machines with different functionality.
• Weak support for GUI. Although this issue is fixed in the latest versions with JavaFX, versioning is still a problem.
• Weak code portability. It is impossible to port code to another platform.

Lots of enterprise systems are built on this platform, and even the famous Minecraft. If you need a big enterprise solution, and it's evident that there are libraries for the required data processing algorithms; if the volume of data is so enormous that you will need multithreading, Java desktop application development might be the answer.



Desktop app development: Adobe AIRAdobe AIR


Adobe Integrated Runtime (AIR) is a cross-platform environment created by Adobe. It allows to use HTML/CSS, AJAX, Adobe Flash and Apache Flex for porting Web applications (including Rich Internet Application) to desktops and mobile devices.


Advantages:
• It is possible to wrap your existing Flash or JavaScript app for desktop.
• Since for Flash it is the only way to wrap it as a desktop app, all of its advantages are taken over by Adobe AIR (such as animation and vector editor).

Drawbacks:
• No support for Linux.
• The Adobe AIR bundle has to be installed, unless AIR runtime is embedded in application.
• Limited in-built access to native services (e.g. SQLite and web services).
• This is proprietary software. To correct errors in AIR or add new features it is necessary to make a submission for error correction in Adobe BugBase.

Adobe AIR works best as a platform for desktop development if you already have a Flash application, which is fully or partially intended for desktop use. Another case is when visuals are what matters most in your application, there are Flash-based libraries for your case, and you are planning to use 3D graphics – NWJS or Electron + WebGL might be the best choice.

Take note that the main drawback of both Java and Adobe AIR is the necessity of having an external software suite and its versioning. This in turn makes the end user keep an eye on its availability. The app won't run without it. Add problems with support, since new versions of these suites keep emerging, even the best Adobe AIR apps get obsolete and simply can't launch over time.



Desktop application development: HaxeHaxe


It's not quite a platform for cross-platform development. It's rather a multiplatform language compiled for a required platform. It can be any platform mentioned in this review. The drawback here is the necessity of knowing a specific language, the necessity of having a specialist, difficulties by optimization of the compiled code, and all the drawbacks of the target platform, for which Haxe is compiled.

But if you are intent on a long-lasting product, and it must be compiled for several platforms, Haxe is a good choice. One thing you shouldn't forget is that you will possibly need a team of developers, since Haxe is rather young, and for every platform you will have to modify and re-compile the application.



Desktop app development: QTQT


QT allows to create and launch software on the majority of modern operating systems by simple compilation for each OS without modifying the source code. It includes all major classes that may be needed by development of an application – from GUI elements to classes for work with network, databases, and XML.

The main advantages of QT can be seen from its history:
• It's one UI library for all platforms (whether it's an advantage or a drawback, depends on your project).
• Popularity of C++ as a programming language.
• Multithreading.

Drawbacks:
• Your developers have to know platform-specific UI libraries. Use of third-party libraries is rather limited.
• The size of the application will be considerable, since all the libraries used in your application are included.
• Relative complexity of distribution of applications for Windows (for free license).
• There may be issues with plugins.
• It is hard to find examples for non-standard cases.

Examples of different apps may be found here.

You should consider that QT is much less popular than Java, thus QT should be selected if you have a specific library that is already implemented on C++, and there are no similar tools for other platforms or languages; or if you have C++ developers who can easily switch to this platform.

Let's proceed to platforms which utilize JavaScript as the programming language.



Desktop application development: CEFCEF


Chromium Embedded Framework is probably the oldest platform for cross-platform software development on JavaScript. It's even not quite a platform, but rather an in-built extension bundle, which basically is a browser based on Chromium, and JavaScript code is executed inside it.

The main drawback is that CEF gets built in a native application; that is, you need a native developer who will write the native part of your application. This approach is hybrid, rather than cross-platform.

On the other hand it may be called an advantage, because it allows to implement every single needed feature, with maximum flexibility of the resulting software product. We can name a lot of examples based on this technology:

• Adobe Brackets - code editor for the Web
• Adobe Edge - multimedia authoring tool
• AppJS - build desktop applications using Node.js
• AOL Instant Messenger - Windows client that uses CEF
• Cubiez - integrates your favorite content into the desktop
• Desura - online game platform
• Dish World IPTV - streaming video platform
• Evernote - notetaking software
• ExeOutput - allows you to deploy HTML5/PHP applications as desktop applications
• GitHub for Windows - GitHub client software for Windows
• Janetter - Twitter client software
• mChef - mIRC browser plugin
• MediaMan - organizer software
• MetaVR - geographic simulation software
• MTG Studio - game organizer software
• OpenSpace3D - 3D development platform
• Rdio - streaming music platform
• Spotify - streaming music platform
• Steam Client - online game platform
• Tencent QQ - instant messaging program and web browser
• Trend Micro - internet security software
• WBEA Desktop - allows you to deploy HTML5 applications as desktop applications



Desktop app development: NWJSNWJS


This is a more sophisticated solution and an advancement over the previous platform. It is a full-fledged platform for creating cross-platform software for desktops. CEF and Node.js server are used as its basis. This is why a release package contains additional 30 MB, which is probably the only drawback. However, the size of the release package is not that critical.



Desktop application development: ElectronElectron


This is one of the latest platforms for desktop cross-platform software development. However, it has already served as the basis for several products, including those of such famous companies as Facebook and Microsoft.

As opposed to NWJS, Electron does not contain the Node.js server. It's closer to CEF, but is already a full-fledged platform, so there is no need for native development.

We should also mention Desktop PhoneGap, which is under development by Adobe, but it's still in its alpha version.



Desktop app development: JavaScriptWhy JavaScript can be a great choice for desktop development? There are several reasons.


• JavaScript is currently the most popular and widespread programming language;
• Currently it is extremely hard to find more powerful and convenient layouting & stylization tools than HTML and CSS;
• An enormous amount of various JavaScript libraries in Web for different cases, which can be used in desktop software development;
• A big chunk of the application code can be used on other platforms: on Web as a site (SPA), on mobile platforms (PhoneGap). And if NWJS is used, it may be used as a part of the server logic.

As for drawbacks: you should consider that desktop cross-platform development with JavaScript is a rather young concept, and it should be selected if your app doesn't utilize complex algorithms of data processing (which, again, is rather new to JavaScript). Otherwise you might be forced to create existing libraries from scratch (even if they already exist for other platforms).

Conclusion: so what is the best platform to build cross-platform desktop apps?


The answer is rather obvious: the one that matches your particular product requirements, the one that helps achieve your business goals in the most cost-effective way. Consequently, the best programming language for desktop applications is the one that supports your optimal platform. Otherwise, there is no such notion as universally "best" platform to build your product with.

However, as we can see from this review, solutions for cross-platform development of desktop apps based on JavaScript grow their popularity. A huge number of companies (including such giants as Microsoft, Adobe, Facebook) already use such products in their activities. But the final decision can be made only when expert developers study your product requirements and goals. Feel free to contact us with any further questions.
Read more:
scroll top