[Android-development] QAndroidStyle and qt 5.4.0

Eskil Abrahamsen Blomfeldt eskil.abrahamsen-blomfeldt at theqtcompany.com
Fri Dec 12 09:40:27 CET 2014


On 12/12/2014 08:53 AM, maitai at virtual-winds.org wrote:
> So:
>
> I cleaned up my device from all qt related applications, including 
> ministro (all through android uninstall), and rebooted it.
>
> I create a new QWidget application, and just added a QPushButton and a 
> QSlider (horizontal) in the form. No layout, nothing more. I switched 
> the project to "release", ran qmake and rebuild, then deploy it to my 
> device without even going to the params or to the manisfest.
>
> I still don't get the correct android-style, I join a screen-shot.

Hi,

Could you please create a bug report for this, and we can continue the 
discussion there?

Could you also try the Qt Quick Controls "gallery" example to see if you 
get the Android style there? Otherwise, it might be an issue with 
extracting the style assets. Strange that the android style is not 
returned in the list returned from QStyleFactory::keys() though. That 
seems to indicate that the plugin is not deployed/loaded at all.

In the bug report, please include information about which platform you 
are on, what QStyleFactory::keys() returns, and a list of the files that 
under android-build/lib/<architecture> in your build directory.

While annoying, the exceptions in the console are probably not causing 
this issue, since they seem to refer to classes only available on 
Android 5 and should not cause the problems you are seeing.

By the way, to temporarily make your application look like in Qt 5.3.2 
while this is being addressed, add QApplication::setStyle("fusion") at 
the very beginning of your main() function (before initializing 
QApplication).

-- Eskil



More information about the Android-development mailing list