What is the interface for a modern application?
HTML 5, QML, XAML, platforms appear, each with its own advantages and disadvantages, and the choice arises when you want to create a web application, RIA (Rich Internet Application) with the same interface and the same capabilities as a local application, as some popular sites do.
The fear of going down the wrong path and spending months developing with an environment that one may not be able to achieve, while the other may prove more appropriate, is reflected in forums where the issue is very present.
The challenge becomes even more complex when we understand that the various solutions on offer continue to evolve and offer features that were previously absent, and we wonder if it is possible in the future that one platform will offer the same capabilities as the other?
JavaScript и HTML 5
The new HTML 5 specification provides a universal interface for online applications and some local applications through offline mode.
This is complemented by Ajax, which is a combination of the techniques that make up dynamic HTML (CSS, JavaScript, DOM) and the XMLHttpRequest object, which enables asynchronous interaction between browser and server. More recently, WebSocket and WebRTC for better interaction with the server or directly with other clients in the case of WebRTC.
The application uses a scripting language on the server like PHP or ASP or JavaScript with Node.js.
Advantages
Full portability: recognized by all recent browsers.
A very wide selection of frames.
Compatibility with web standards: JavaScript, CSS, Document Object Model.
Works locally without connecting to the server.
Facilitate implementation.
Shortcomings
Using CSS for formatting is often laborious.
JavaScript programming is difficult for large programs.
Evolutions
Evolution is taking place in frameworks that are increasingly being developed, as well as in new web standards designed to support web applications. The gradual transition from Node.js to ECMASCript 6 makes it easier to create professional applications.
C # and XAML
XAML, like XUL, is an XML-based interface description language. But Microsoft sees it as a way to build rich internet apps. It provides an interface language for Windows with .NET, Linux with Mono, and Linux-derived systems such as the Android platform.
It has been used for the Windows GUI since Vista, and for Windows 8 and 10 in both the Modern UI/Metro interface and the classic desktop with .NET.
Advantages
A very large library of functions.
Choosing a programming language on the .NET platform
Shortcomings
Compatibility, however, is limited. Requires WPF or WinRT, but not on Windows 10 and Core .NET.
Evolutions
Immersive Modern UI apps on Windows 10 can use XAML. The open source .NET can also give new life to XAML.
See also: What is the future of XAML?
Java и JavaFX
The Java solution is complete because it offers a server framework, and on the browser side, the use of applets, which are small applications running inside a web page. This can also be supplemented by the server scripting language, JSP. Let's add web service servlets to this and provide a portable and comprehensive platform for enterprise web applications. JavaFX helps create graphical user interfaces.
Advantages
An extremely extensive library of functions.
Compatible with all platforms.
Shortcomings
A runtime must be installed on the client computer. For web applications, the server must support Java, which practically implies a dedicated server.
Java programming can be complicated.
Evolutions
XAMJ, a Java implementation of XAML, could combine the advantages of the XAML format with Java portability, but the standard solution for building interfaces is JavaFX.
Qt and QML
Initially, Qt is a Linux front-end framework that has been ported to all operating systems, including Android and iOS. It includes all the widgets needed to create an interface, and also has its own interface language, QML. This has a syntax similar to JSON, making it similar to JavaFX.
Advantages
Desktop and mobile portability.
Integrated Chromium-based document rendering engine and interfaces.
Qt Creator simplifies application creation.
Shortcomings
Qt execution time is long (at least 30 MB). But the same is true for Java.
Programming is done in C++, which allows you to quickly work with applications, but errors are common.
It can be difficult to make JavaScript in the interface and C++ in the backend communicate.
Evolutions
Sailfish's mobile operating system is based solely on Qt. It offers compatibility with Android (which has an SDK for C++), and therefore can replace the Dalvik virtual machine with added portability.
Summary table
You can simplify the selection of the Web application interface by using the following table:
HTML 5 |
XAML |
QT |
JavaFX |
|
Display in browser |
yes I did |
no, it isn't |
yes I did |
no, it isn't |
Operating system portability |
yes I did |
Not indifferent |
yes I did |
yes I did |
Mobile compatibility |
yes I did |
yes I did |
yes I did |
yes I did |
Local use (not connected) |
yes I did |
yes I did |
yes I did |
yes I did |
Performance (performance) |
According to |
yes I did |
yes I did |
yes I did |
Free of charge |
yes I did |
yes I did |
yes I did | According to |
Excessive complexity |
no, it isn't | no, it isn't | C++ |
Java |
Note that it is possible to combine solutions to resolve format flaws. For example, Ajax can be used on the client side in conjunction with Java on the server to avoid the slowness of applets. Frameworks also allow you to work offline.
Other solutions
The SVG vector markup language allows you to create graphical components for the web application interface. The presence of vector widgets allows you to change the screen size at will, making it more suitable for desktop graphics or gaming applications. Web and mobile apps should not use SVG because compatibility between browsers is imperfect.