• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

marble

  • sources
  • kde-4.14
  • kdeedu
  • marble
  • examples
  • qml
  • position-tracking
Toggle.qml
Go to the documentation of this file.
1 // This file is part of the Marble Virtual Globe.
2 //
3 // This program is free software licensed under the GNU LGPL. You can
4 // find a copy of this license in LICENSE.txt in the top directory of
5 // the source code.
6 //
7 // Copyright 2011 Dennis Nienhüser <earthwings@gentoo.org>
8 
9 // A (gps) tracking example. Shows the current (gps) position on the map
10 // using a small ghost image. The visibility of the track can be toggled.
11 
12 import Qt 4.7
13 
14 Rectangle {
15  id: toggle
16 
17  property bool active: false
18  property alias text: message.text
19 
20  signal toggled
21 
22  width: 100; height: 20
23  radius: 5
24  color: active ? "steelblue" : "gray"
25  x: 30; y: 30
26 
27  Text {
28  id: message
29  anchors.horizontalCenter: parent.horizontalCenter
30  anchors.verticalCenter: parent.verticalCenter
31  anchors.margins: 10
32  color: "white"
33  text: ""
34  }
35 
36  MouseArea {
37  id: mouseArea
38  anchors.fill: parent
39  onClicked: {
40  active = !active
41  toggle.toggled()
42  }
43  }
44 }
Marble::radius
static qreal radius(qreal zoom)
Definition: thumbnailer.cpp:99
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:13:42 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

marble

Skip menu "marble"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal