User QML Type | Qt Location 5.15.19 (original) (raw)

The User type identifies a user who contributed a particular Place content item. More...

Import Statement: import QtLocation 5.15
Since: QtLocation 5.5

Properties

Detailed Description

Each Place content item has an associated user who contributed the content. This type provides information about that user.

Example

The following example shows how to display information about the user who submitted an editorial:

import QtQuick 2.0 import QtPositioning 5.5 import QtLocation 5.6

EditorialModel { id: editorialModel batchSize: 3 place: place }

ListView { model: editorialModel delegate: Item { anchors.fill: parent

    [Column](qml-qtquick-column.html) {
        width: parent.width
        clip: true

        [Text](qml-qtquick-text.html) {
            text: title
            width: parent.width
            wrapMode: Text.WordWrap
            font.pixelSize: 24
        }

        [Text](qml-qtquick-text.html) {
            text: text
            width: parent.width
            wrapMode: Text.WordWrap
            font.pixelSize: 20
        }

        [Row](qml-qtquick-row.html) {
            [Image](qml-qtquick-image.html) {
                width: 16
                height: 16

                source: supplier.icon.url(Qt.size(width, height), Icon.List)
            }

            [Text](qml-qtquick-text.html) {
                text: "Provided by " + supplier.name
                font.pixelSize: 16
            }
        }

        [Text](qml-qtquick-text.html) {
            text: "Contributed by " + user.name
            font.pixelSize: 16
        }

        [Text](qml-qtquick-text.html) {
            text: attribution
            font.pixelSize: 8
        }
    }
}

}

See also ImageModel, ReviewModel, and EditorialModel.

Property Documentation

This property holds the name of a user.

This property holds the unique identifier of the user.

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.