Changeset 846 for trunk/doc/src/examples/diagramscene.qdoc
- Timestamp:
- May 5, 2011, 5:36:53 AM (14 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:mergeinfo changed
/branches/vendor/nokia/qt/4.7.2 (added) merged: 845 /branches/vendor/nokia/qt/current merged: 844 /branches/vendor/nokia/qt/4.6.3 removed
- Property svn:mergeinfo changed
-
trunk/doc/src/examples/diagramscene.qdoc
r651 r846 1 1 /**************************************************************************** 2 2 ** 3 ** Copyright (C) 201 0Nokia Corporation and/or its subsidiary(-ies).3 ** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). 4 4 ** All rights reserved. 5 5 ** Contact: Nokia Corporation (qt-info@nokia.com) … … 7 7 ** This file is part of the documentation of the Qt Toolkit. 8 8 ** 9 ** $QT_BEGIN_LICENSE: LGPL$9 ** $QT_BEGIN_LICENSE:FDL$ 10 10 ** Commercial Usage 11 11 ** Licensees holding valid Qt Commercial licenses may use this file in 12 12 ** accordance with the Qt Commercial License Agreement provided with the 13 ** Software or, alternatively, in accordance with the terms contained in 14 ** awritten agreement between you and Nokia.13 ** Software or, alternatively, in accordance with the terms contained in a 14 ** written agreement between you and Nokia. 15 15 ** 16 ** GNU Lesser General Public License Usage 17 ** Alternatively, this file may be used under the terms of the GNU Lesser 18 ** General Public License version 2.1 as published by the Free Software 19 ** Foundation and appearing in the file LICENSE.LGPL included in the 20 ** packaging of this file. Please review the following information to 21 ** ensure the GNU Lesser General Public License version 2.1 requirements 22 ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. 23 ** 24 ** In addition, as a special exception, Nokia gives you certain additional 25 ** rights. These rights are described in the Nokia Qt LGPL Exception 26 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. 27 ** 28 ** GNU General Public License Usage 29 ** Alternatively, this file may be used under the terms of the GNU 30 ** General Public License version 3.0 as published by the Free Software 31 ** Foundation and appearing in the file LICENSE.GPL included in the 32 ** packaging of this file. Please review the following information to 33 ** ensure the GNU General Public License version 3.0 requirements will be 34 ** met: http://www.gnu.org/copyleft/gpl.html. 16 ** GNU Free Documentation License 17 ** Alternatively, this file may be used under the terms of the GNU Free 18 ** Documentation License version 1.3 as published by the Free Software 19 ** Foundation and appearing in the file included in the packaging of this 20 ** file. 35 21 ** 36 22 ** If you have questions regarding the use of this file, please contact … … 55 41 underline of the text. 56 42 57 The Qt graphics view framework is designed to manage and 58 display custom 2D graphics items. The main classes of the59 framework are QGraphicsItem, QGraphicsScene and QGraphicsView. The60 graphicsscene manages the items and provides a surface for them.43 The Qt graphics view framework is designed to manage and display 44 custom 2D graphics items. The main classes of the framework are 45 QGraphicsItem, QGraphicsScene and QGraphicsView. The graphics 46 scene manages the items and provides a surface for them. 61 47 QGraphicsView is a widget that is used to render a scene on the 62 screen. See the \l{ The Graphics View Framework}{overview document}63 for a more detailed description of the framework.48 screen. See the \l{Graphics View Framework} for a more detailed 49 description of the framework. 64 50 65 51 In this example we show how to create such custom graphics … … 210 196 an image of one of the \c DiagramItems, i.e., flowchart shapes. 211 197 The image is created by the \c DiagramItem through the \c image() 212 function. The QButtonGroup class lets us attach a QVariantwith198 function. The QButtonGroup class lets us attach an id (int) with 213 199 each button; we store the diagram's type, i.e., the 214 200 DiagramItem::DiagramType enum. We use the stored diagram type when … … 280 266 \snippet examples/graphicsview/diagramscene/mainwindow.cpp 3 281 267 282 This slot deletes the selected item, if any, from the scene. If 268 This slot deletes the selected item, if any, from the scene. It 269 deletes the arrows first in order to avoid to delete them twice. If 283 270 the item to be deleted is a \c DiagramItem, we also need to delete 284 271 arrows connected to it; we don't want arrows in the scene that
Note:
See TracChangeset
for help on using the changeset viewer.