Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Realities of using QT C++ to write a cross platform phone app

I am attempting to continue developing applications for Smart Phones (I have a little experience with Android). I have done some deep research & I have decided to start creating applications in Qt C++.

The reason I am doing this is because from my research it seems that I can write an application once in Qt then all I have to do is compile it on IPhone, Android, Symbian & Windows Mobile and then I will have an application that will work on ALL these platforms.

My question is: Am I correct that if I write an app in Qt C++ then it will work on the following platforms: Android, IPhone, Symbian & Windows Mobile?

I know that this is kindof a naive question ("What API can I use to work on all platforms") but I have researched alot & they all seem to say Qt can work on all these platforms.

PS, Are there any cons to using Qt to write a cross platform Phone App? Is compiling Qt application code difficult to do on each platform?

like image 636
user593747 Avatar asked Feb 19 '11 00:02

user593747


People also ask

Is QT really cross-platform?

Qt (pronounced "cute") is cross-platform software for creating graphical user interfaces as well as cross-platform applications that run on various software and hardware platforms such as Linux, Windows, macOS, Android or embedded systems with little or no change in the underlying codebase while still being a native ...

Can QT be used for mobile apps?

Qt is a cross-platform app development framework for mobile, desktop, and embedded applications. Qt supports such platforms as Android and iOS, BlackBerry, Windows, Linux, OS X, and many others.

What are the advantages of Qt?

Qt is better for GUI design, because is faster than other languages. Is managed directly by the CPU. Use smart Memory management. It's GUI Designer is very useful and easy to handle.

Does Qt work on Android?

Qt for Android enables you to run Qt applications on Android devices. For Qt modules that support android targets see: All Supported Qt Modules.


2 Answers

This question was asked a long time ago and many things have changed since. For those asking themselves the same question today (beginnings of 2014) then my personal answer is that Qt works 99% on iPhone.

Currently I'm developing an application that uses QSensors, QNetworkAccessManager and OpenGL ES and I have not encountered any problems on OSX, iOS, Windows and Linux. Thinking about porting to Android soon.

The only problem I met was the QtPositioning (GPS) module that is not yet supported for iOS but the workaround is very easy and I wouldn't consider this a problem. It will probably work later this year. Also due to some iOS limitations, the QtWebKit is not available. The rest works like a charm! Great job done.

I have not tested myself on Android but from what I read Qt should also work on that.

like image 200
Konstantinos Gaitanis Avatar answered Nov 03 '22 00:11

Konstantinos Gaitanis


You are good to go with Qt C++ (and most recently with QML) for mobile phone development.

My question is: Am I correct that if I write an app in QT C++ then it will work on the following platforms: Android, IPhone, Symbian & Windows Mobile?

Yes it works fine on Android, Symbian, Windows Mobile, Meego, Maemo, Moblin.

I'm a Qt developer and I have used it to develop for Symbian, Meego, Maemo and Android. Since Symbian, Meego, Maemo are officially supported they work 99.99% perfectly on these platforms.

But in Android, it works 95% fine but you require very few workouts.As far as I know, the QtMultimedia Kit is not supported on Android (some pathces are available). But the Android port contributor Bog has said that they will port it too as soon as possible. There is a big community behind Qt as well as Qt for Android. You can also use Mobility APIs as you use in Symbian and Meego. Qt mobile apps are already published in Android market without any problem.

Regarding Windows Mobile, its officially mentioned that even Qt Mobility can be used with that phone and it supports pure Qt C++ code. But I dont think too many users will be using Windows Mobile now, as Windows Phone 7(not supported by Qt)is the latest talk.

Regarding iPhone port, yes there are experimental port by communities. Will be soon available with some examples, I think. I have seen some Youtube videos demonstrating Qt and Qt Mobility working on iPhone.

Recently RIM has said that their BBQ (Blackberry Tablet OS) platform will have an official port for Qt.

Regarding any Linux Mobile(Moblin, Maemo, etc), yes Qt C++ works just perfectly on them.

Regarding Desktop, Qt C++/QML runs almost on all Desktop platforms.

I don't understand that someone like CommonsWare with 145k reps, just came out and said literally like Qt will not work in any of the Mobile platforms. But as he said, if you are going to choose a HTML based API like PhoneGap, then I would recommend Qt 100 times over that. Because Qt can do better than HTML5 in all the ways. It can handle some comlpex problems like 3D, openGL etc much more better and efficiently than HTML5.

After reading all the above answers I'm dissappoint to say that you better not believe these answers and go join this place Qt Labs where you will see and enjoy the real power of Qt.

Recently Qt has gone open governance, where each Qt module will be developed and maintained according to public interest. Further Trolltech, KDE and Nokia are developing it for commercial reasons. So never ever lose Qt because of some bad advide, try it yourself and then decide it by yourself.

like image 28
2 revs, 2 users 98% Avatar answered Nov 02 '22 22:11

2 revs, 2 users 98%