by Tim Anderson
Tim Anderson wonders if Microsoft has done enough with Windows 8.1, and checks out Embarcadero’s approach to the Android platform.
HardCopy Issue: 61 | Published: November 1, 2013
Despite solid internal improvements, the Windows 8 story has so far been decidedly rocky. Microsoft managed to alienate much of its core market with the dramatically different Start menu and the touch-friendly ‘Metro’ (Windows Runtime or WinRT) user interface, while adoption for the new-style apps and Windows Store has been disappointing.
However, while public attention is focused on trivia such as the return of the Start button, the real issue is whether Microsoft can succeed in transforming Windows devices into something fit for the post-PC world. This means appliance-like ease of use and reliability; high mobility with long battery life; a cloud-centric approach that minimises the pain of switching to a new device; and the removal of all those annoyances that plague Windows like slow boot, failed updates, restart requests and irritating third-party apps declaring that “Your PC is not secure.”
The new platform is well designed as a way of fixing these typical PC problems, but only if users adopt it, rather than trying to configure Windows 8 to be like Windows 7 and ignoring Windows Store apps.
The problem these long-suffering users have (aside from a certain conservatism) is that old-style desktop apps are essential if you want to get anything done. I am typing this in Word, a desktop app, and there is no realistic alternative in the WinRT environment. The same goes for hundreds of thousands of other Windows apps out there, and once you’re in the desktop environment, you tend to stay there.
That could change if enough compelling WinRT apps appear that they generate buzz and persuade users to take a look. But what is the proposition for developers? Hal Berenson explains the issue in his August blog post ‘Fixation on Margins’: “So today there are about 100 million PCs actually running Windows 8, and perhaps 98 million of them also run Win32 Desktop apps. So the real market, the one you can’t reach in other ways, for Metro apps is only 2 million systems.”
His point is that the only exclusive market for WinRT apps, a market you cannot reach without them, is the ARM version Windows RT, as found in the Surface RT on which Microsoft took a huge write-down because it made too many. In addition, Win32 apps also run on Windows 7 and, if carefully written, Windows XP, which greatly expands their market.
That is not the whole story. Developers who target WinRT get a ready-made tablet-friendly platform, as well as the easy deployment and security that Windows Store apps offer. However there is massive inertia in the Windows ecosystem which makes it hard for Microsoft to reshape the platform.
Seen in this context, it is obvious that Windows 8.1 cannot by itself fix all these problems. That said, there are some positives. The comforting Start button, together with some changes that make it easier to configure Windows 8 in a way that makes sense for desktop users, will make it more acceptable to those who so far have preferred Windows 7. You can set the Start screen to show desktop apps first, for example. That will mean more users who are able to run WinRT apps, even if they mostly choose not to.
There are also improvements to the WinRT platform in 8.1. The best way to put this is that, if you sat down to write an app for Windows 8.0 with the original SDK, the immaturity of the platform soon hit you. Things that should be simple, like creating a settings flyout, turned out to be fiddly, and the controls on offer were barely adequate. Now there is a Flyout control and a DatePicker control and the platform is not as frustrating for the developer.
Microsoft’s stated goal is to have one API across all devices. Windows Phone 8 is built on the same core as Windows 8 and, if the company has any sense, it will find a way to bring the two platforms together so that developers can easily target them both, in the same way that iOS has unified the iPhone and iPad. If Windows Phone continues to grow its market share following the Nokia acquisition, there is still hope for Microsoft’s device platform. If that sounds weak it is because, with iOS and Android roaring ahead, success is far from assured.
That said, it is also worth noting that what we call the Microsoft platform is changing. ‘Devices and Services’ is the new mantra, and on the services side things look better. Office 365 is growing fast, giving developers a new cloud platform based on SharePoint and Azure Active Directory. Windows Azure is also maturing fast. The ease with which you can create a Web application in Visual Studio 2012 and deploy it to Azure is almost embarrassing, and an easy way to impress clients. Maybe ‘Services and a few devices’ will characterise the new Microsoft.
Embarcadero goes Android
Moving on, Embarcadero (the company behind Delphi and RAD Studio) recently surveyed 1,300 Windows developers and found an 85 per cent consensus that requests are coming in for mobile apps, with 83 per cent of those including Android support. This was followed by 67 per cent iOS, 33 per cent Windows Phone, 17 per cent Windows RT and 14 per cent Blackberry.
Windows RT is the ARM version of Windows 8, as seen in Surface RT, but I cannot help wondering if there is some confusion with WinRT, the tablet-friendly runtime that is in all versions of Windows 8. Either way, it is obvious that Android and iOS dominate, although given its small market share 33 per cent is a decent showing for Windows Phone as well.
So the big news for Delphi developers is that Embarcadero has released the XE5 range, which targets Android. This follows just six months after XE4 which added iOS support, but is a full version upgrade which is annoying and expensive for those who bought the earlier version without a maintenance agreement.
Getting the perfect setup for Rad Studio XE5 is somewhat arduous. You need a Mac for iOS support but the IDE is Windows-only, which makes a VM running on a Mac attractive. However this setup is not ideal for Android as debugging on a USB-connected device will be easier on Windows, so the best setup now is probably a Windows machine with remote access to a Mac for iOS debugging.
Another notable feature of XE5 for Android is that it uses the Native Development Kit (NDK) rather than the Java SDK targeting Dalvik (the Android Java runtime). This fits with the Delphi approach to development, which involves compilation to a native executable, but complicates both the developer setup and also Android development itself. If you need to interoperate with Java code, you need to use JNI (Java Native Interface).
Mobile development in Delphi XE5 means using the FireMonkey framework, which mainly emulates GUI controls with custom drawing. This makes it easy to create a GUI that runs on multiple platforms, but harder to get the right look and feel for each platform.
In a quick test, once Delphi was installed and all the ADB (Android Debug Bridge) ducks were in line, I had no difficulty running up a quick app on my Android phone.
Delphi for Android looks attractive for developers who either like the Delphi language, or have a ton of existing non-visual code to port. I confess to reservations though. Targeting the NDK sounds good for performance, although Google says it should not be necessary and frankly Dalvik performance is already good enough for most apps (and you can write performance-critical code in the NDK and call it from Dalvik if you need to). However it is inconvenient for taking advantage of existing Android code examples or libraries.
Next, there is the issue as to whether FireMonkey is the right approach to a cross-platform GUI, or whether Xamarin’s idea of writing a device-specific GUI for each platform gives better results (Xamarin offer C# compilers form iOS and Android). Third, it does seem expensive to stay on the Delphi bus, although as ever the cost of tools soon pales in comparison to issues such as productivity.
There are even other choices for Delphi language on Android, such as the Delphi-like Oxgene from RemObjects which targets .NET, WinRT, Android and Mac/iOS. The answer is to try out the free XE5 evaluation and see what you think.