Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Deploy Quick Controls with just the Material style

Deploy Quick Controls with just the Material style

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
quick controls
3 Posts 1 Posters 720 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    Tom_H
    wrote on last edited by
    #1

    Hello. I'm writing a Quick Controls Android application and I only want to deploy the Material style, but Qt Creator is deploying ALL the styles (Fusion, Imagine, Universal, etc). How can I limit it to just the Material style?

    In main.cpp:
    QQuickStyle::setStyle("Material");

    In qtquickcontrols2.conf:

    [Material]
    Theme=...
    Primary=...
    Background=...
    
    1 Reply Last reply
    0
    • T Offline
      T Offline
      Tom_H
      wrote on last edited by
      #2

      After reading up on Android deployment, I made a custom version of libs.xml that omitted the extra style libs, but they are still getting deployed in the APK.

      1 Reply Last reply
      0
      • T Offline
        T Offline
        Tom_H
        wrote on last edited by
        #3

        After building the project in Qt Creator, I imported it into Android Studio, deleted the unwanted style libs, rebuilt and deployed from there. The size of the app went from 69.91 MB to 61.39 MB. That's good but surely there must be a way to do it from Qt Creator, no? I tried running the androiddeployqt tool but couldn't get it to work.

        BTW, I upgraded from Qt 5.9 to 5.12 this week. The app size was only 39 MB on Qt 5.9 :(

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved