Marble

WidgetGraphicsItem.h
1// SPDX-License-Identifier: LGPL-2.1-or-later
2//
3// SPDX-FileCopyrightText: 2010 Bastian Holst <bastianholst@gmx.de>
4//
5
6#ifndef MARBLE_WIDGETGRAPHICSITEM_H
7#define MARBLE_WIDGETGRAPHICSITEM_H
8
9// Marble
10#include "ScreenGraphicsItem.h"
11#include "marble_export.h"
12
13class QWidget;
14
15namespace Marble
16{
17
18class WidgetGraphicsItemPrivate;
19
20class MARBLE_EXPORT WidgetGraphicsItem : public ScreenGraphicsItem
21{
22 public:
23 explicit WidgetGraphicsItem( MarbleGraphicsItem *parent = nullptr );
24
25 ~WidgetGraphicsItem() override;
26
27 void setWidget( QWidget *widget );
28 QWidget *widget() const;
29
30 protected:
31 /**
32 * Paints the item in item coordinates.
33 */
34 void paint( QPainter *painter ) override;
35
36 bool eventFilter( QObject *, QEvent * ) override;
37
38 private:
39 Q_DISABLE_COPY( WidgetGraphicsItem )
40 Q_DECLARE_PRIVATE(WidgetGraphicsItem)
41};
42
43} // Namespace Marble
44
45#endif
Binds a QML item to a specific geodetic location in screen coordinates.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Jun 21 2024 12:00:07 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.