Sailfish OS
  • Info
  • User Experience
  • Cases
  • Community
  • Developers
  • Contact
  • Get Sailfish OS
Select Page
  • Info
  • User Experience
  • Cases
  • Community
  • Developers
  • Contact
  • Get Sailfish OS

API Documentation

Documentation for developing SailfishOS applications
  • API Documentation
  • Libsailfishapp
  • Sailfish Silica
    • Documentation
    • Icon Reference
  • Sailfish Components
    • Sailfish Accounts
    • Sailfish Bluetooth
    • Sailfish Contacts
    • Sailfish Crypto
    • Sailfish Gallery
    • Sailfish Media
    • Sailfish Pickers
    • Sailfish Secrets
    • Sailfish Share
    • Sailfish Telephony
    • Sailfish Webview
    • Amber Web Authorization
    • Amber MPRIS
  • Nemo QML Plugins
    • Configuration
    • Contacts
    • D-Bus
    • Keepalive
    • Notifications
    • Thumbnailer
  • Sailfish Middleware
    • MDM Framework
    • MDM Policy Framework
    • User Manager Daemon
  • API Documentation
  • Libsailfishapp
  • Sailfish Silica
    • Documentation
    • Icon Reference
  • Sailfish Components
    • Sailfish Accounts
    • Sailfish Bluetooth
    • Sailfish Contacts
    • Sailfish Crypto
    • Sailfish Gallery
    • Sailfish Media
    • Sailfish Pickers
    • Sailfish Secrets
    • Sailfish Share
    • Sailfish Telephony
    • Sailfish Webview
    • Amber Web Authorization
    • Amber MPRIS
  • Nemo QML Plugins
    • Configuration
    • Contacts
    • D-Bus
    • Keepalive
    • Notifications
    • Thumbnailer
  • Sailfish Middleware
    • MDM Framework
    • MDM Policy Framework
    • User Manager Daemon

Contents

  • Properties
  • Detailed Description

ColorPickerDialog QML Type

A dialog for selecting a color from a ColorPicker More...

Import Statement: import Sailfish.Silica 1.0
Inherits:

Dialog

  • List of all members, including inherited members

Properties

  • color : color
  • colors : var

Detailed Description

The ColorPickerDialog type presents a ColorPicker within a Dialog to allow a color to be selected. Tapping on a color in the picker will accept the dialog.

Here is a simple color picker dialog, opened with PageStack::push():

 import QtQuick 2.2
 import Sailfish.Silica 1.0

 Page {
     Rectangle {
         id: colorIndicator
         color: "transparent"
         width: theme.itemSizeSmall
         height: theme.itemSizeSmall
     }
     Button {
         id: button
         text: "Choose a color"

         onClicked: {
             var dialog = pageStack.push("Sailfish.Silica.ColorPickerDialog")
             dialog.accepted.connect(function() {
                 colorIndicator.color = dialog.color
             })
         }
     }
 }

See also ColorPicker.

Property Documentation

color : color

The color value picked by the user. The default value is null.

See also colors.


colors : var

An array of color values displayed to the user. By default the array follows a harmonic set of platform-style colors.

See also color.


  • Legal
  • Contact Us
  • Jolla Mobile Ltd © 2025

  • Facebook
  • Twitter
  • Mastodon
  • YouTube
  • LinkedIn