Warning, /education/marble/examples/qml/data-layers/StaticLayer.qml is written in an unsupported language. File is not indexed.

0001 // SPDX-License-Identifier: LGPL-2.1-or-later
0002 //
0003 // SPDX-FileCopyrightText: 2012 Dennis Nienhüser <nienhueser@kde.org>
0004 
0005 import QtQuick 1.1
0006 import org.kde.marble 0.20
0007 
0008 MarbleWidget {
0009     width: 800;
0010     height: 600
0011 
0012     center: Coordinate { longitude: 30; latitude: 33 }
0013 
0014     dataLayers: [
0015         DataLayer{
0016             // The model defines the data that will appear. The lon and lat
0017             // property of its items define their position
0018             // See SevenWondersOfTheAncientWorld.qml for details
0019             model: SevenWondersOfTheAncientWorldModel {}
0020 
0021             // The delegate is the component that shows the items from the
0022             // model on top of the map. Their position and visibility is managed
0023             // automatically by Marble
0024             delegate: Rectangle {
0025                 width: 100;
0026                 height: image.height + label.height + 12
0027                 border.color: "darkgray"; border.width: 2
0028                 radius: 4; smooth: true
0029                 Column {
0030                     id: column; x: 4; y: 4; spacing: 4
0031                     Image {
0032                         id: image
0033                         width: 92; smooth: true
0034                         fillMode: Image.PreserveAspectFit
0035                         // "picture" is a property defined by items in the model
0036                         source: picture
0037                     }
0038                     Text {
0039                         id: label
0040                         // "name" is a property defined by items in the model
0041                         text: name
0042                         width: 92
0043                         wrapMode: Text.Wrap
0044                         font.bold: true
0045                     }
0046                 }
0047             }
0048         }
0049     ]
0050 }