I’m doing a project over the summer that involves entirely re-writing a large application to be more modern and cross platform compatible. It needs to run on Windows, OS X, and iPad. An iPad build is a priority. It is preferred that it is fairly easy to convert into a web app in the future as well.
My current plan is to do all the GUI in HTML/CSS/JS, using Chrome Embedded Framework to render the pages and handle interactivity. This way all of the UI is cross platform on everything, and I just have to write platform specific code to display it. It also means that if/when I port it to the web, most of the UI is already in web compatible format. The rest of the application code itself should be mostly cross platform as well, just pure C++. There is no CEF for iPad so I’m considering using the UIWebView class to do the same thing. I’m curious what your take is on using HTML as a GUI on the iPad.
My main concerns are:
-
Performance – I don’t know what the performance characteristics of UIWebView are as far as using it for a GUI goes. There will be a lot of interactive dialogs and even some animation required. I did some research into how you communicate to Objective-C from Javascript, and the most popular method (setting the document location to some custom URL like MyApp://, and extracting a message from the string) seems like it would be really slow.
-
Usability – iOS users are used to a certain standard of interactivity (e.g. really smooth transitions, draggable sidebars, everything is fast and polished). I’m confident I can pull this off on Windows/OS X using CEF, but not sure about iPad.
Thanks for your time!
You can certainly use HTML5/CSS/JS GUIs on the iPad. There are even GUI frameworks that help you with this. The one I know is Enyo. You will find many more.
The nice thing about GUIs built on these technologies is that in many cases you can develop on your desktop using your web browser.
For deployment to iOS devices you can just put the GUI inside a
UIWebViewby hand, or you can use phonegap, which takes care of the dirty job for you, while also giving you the option to publish on Android and a few other mobile platforms besides iOS from the same sources.For the desktop versions you may want to evaluate if the same GUIs can work inside an embedded browser window. Enyo apps that don’t depend on phone/tablet hardware run pretty well inside a desktop web browser, but I suspect users may find the GUI weird for desktop use. If you need to build something more traditional then I recommend Qt if you want power and the best native look & feel or FLTK if you want simplicity. Both frameworks run on Windows, OS X and Linux.