IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)

Qt Quick Controls 1 Platform Notes

Platform specific notes for Qt Quick Controls.

Article lu   fois.

L'auteur

Liens sociaux

Viadeo Twitter Facebook Share on Google+   

Qt Quick Controls 1 Platform Notes

This page contains platform specific notes for creating applications that use Qt Quick Controls 1.

Android Style

Qt 5.4 introduced a native Android style for Qt Quick Controls.

Image non disponible

The Android style requires Android 3.0 (API level 11) or later.

The style is automatically selected and deployed on Android. See Getting Started with Qt for Android and Deploying an Application on Android for more details on the Android essentials.

Android Themes

Applications may choose a specific Android theme by specifying it in AndroidManifest.xml.

Image non disponible

The following example sets a dark Holo theme, and the result can be seen in the screenshot above.

 
Sélectionnez
<manifest ...>
  <application ... android:theme="@android:style/Theme.Holo">
    ...
  </application>
  ...
</manifest>

Action Bar

The Action Bar is a special Android control that provides many key features including various navigation modes, actions, an options menu, a back button, and also displays the application icon and title.

Unlike Qt Widgets, Qt Quick Controls 1 do not use the native action bar on Android. ToolBar and MenuBar are offered as a cross-platform replacement. They are unified to a single "action bar" when assigned to the appropriate ApplicationWindow properties.

The advantage of a non-native ToolBar is that it can contain any child items declared in QML. Just to name a few possibilities:

Vous avez aimé ce tutoriel ? Alors partagez-le en cliquant sur les boutons suivants : Viadeo Twitter Facebook Share on Google+