ItemEditorStyle

Provides custom styling for the ItemEditor More...

Import Statement: import VPlay 2.0
Inherits:

QtObject

Properties

Detailed Description

You can create a custom ItemEditor by replacing the according delegate of the ItemEditorStyle with a custom design. If you want to restyle all ItemEditors in your app it is advised to use StyleVPlay to restyle the elements.

Example Usage

Following example adjusts the background of the item editor.

 ItemEditor {
   id: itemEditor
   itemEditorStyle: ItemEditorStyle {
     contentDelegateBackground: Rectangle {
         anchors.fill: parent
         border.width: 2
         border.color: "#ff0000"
         radius: 4
         gradient: Gradient {
             GradientStop { position: 0 ; color: "#ccc" }
             GradientStop { position: 1 ; color: "#aaa"  }
         }
     }
     contentDelegateTypeList: Rectangle {
         anchors.fill: parent
         border.width: 2
         border.color: "#ff0000"
         radius: 4
         gradient: Gradient {
             GradientStop { position: 0 ; color: "#eee" }
             GradientStop { position: 1 ; color: "#ccc" }
         }
     }
   }
 }

If you need a custom label, you can replace the label item properties.

See also ItemEditor and StyleVPlay.

Property Documentation

contentDelegateBackground : Component

This Component is used to change the style of the ContentDelegate background used by the ItemEditor.


contentDelegateTypeList : Component

This Component is used to change the style of the TypeList background in the ContentDelegate used by the ItemEditor.


label : Text

This Component is used to change the style of the Text items used in all delegates of the ItemEditor.


Videos

Voted #1 for:

  • Easiest to learn
  • Most time saving
  • Best support

Develop Cross-Platform Apps and Games 50% Faster!

  • Voted the best supported, most time-saving and easiest to learn cross-platform development tool
  • Based on the Qt framework, with native performance and appearance on all platforms including iOS and Android
  • Offers a variety of plugins to monetize, analyze and engage users
FREE!
create apps
create games
cross platform
native performance
3rd party services
game network
multiplayer
level editor
easiest to learn
biggest time saving
best support