Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
src_gui_graphicsview_qgraphicsproxywidget.cpp
Go to the documentation of this file.
1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
3
5int main(int argc, char **argv)
6{
7 QApplication app(argc, argv);
8
9 QTabWidget *tabWidget = new QTabWidget;
10
13
15 view.show();
16
17 return app.exec();
18}
20
22QGroupBox *groupBox = new QGroupBox("Contact Details");
23QLabel *numberLabel = new QLabel("Telephone number");
25
28
31
35
38
41
42edit->isVisible(); // returns true
43proxy->isVisible(); // also returns true
44
46
47edit->isVisible(); // returns false
48proxy->isVisible(); // also returns false
The QApplication class manages the GUI application's control flow and main settings.
static int exec()
Enters the main event loop and waits until exit() is called, then returns the value that was set to e...
The QFormLayout class manages forms of input widgets and their associated labels.
Definition qformlayout.h:18
void addRow(QWidget *label, QWidget *field)
Adds a new row to the bottom of this form layout, with the given label and field.
bool isVisible() const
Returns true if the item is visible; otherwise, false is returned.
The QGraphicsProxyWidget class provides a proxy layer for embedding a QWidget in a QGraphicsScene.
The QGraphicsScene class provides a surface for managing a large number of 2D graphical items.
QGraphicsProxyWidget * addWidget(QWidget *widget, Qt::WindowFlags wFlags=Qt::WindowFlags())
Creates a new QGraphicsProxyWidget for widget, adds it to the scene, and returns a pointer to the pro...
The QGraphicsView class provides a widget for displaying the contents of a QGraphicsScene.
The QGroupBox widget provides a group box frame with a title.
Definition qgroupbox.h:17
The QLabel widget provides a text or image display.
Definition qlabel.h:20
The QLineEdit widget is a one-line text editor.
Definition qlineedit.h:28
The QTabWidget class provides a stack of tabbed widgets.
Definition qtabwidget.h:20
void hide()
Hides the widget.
Definition qwidget.cpp:8135
bool isVisible() const
Definition qwidget.h:874
void show()
Shows the window.
Definition qwindow.cpp:2254
int main()
[0]
QGraphicsProxyWidget * proxy
QApplication app(argc, argv)
[0]
QQuickView * view
[0]