Quantum GIS API Documentation  1.7.4
src/core/composer/qgscomposeritemgroup.h
Go to the documentation of this file.
00001 /***************************************************************************
00002                          qgscomposeritemgroup.h
00003                          ----------------------
00004     begin                : 2nd June 2008
00005     copyright            : (C) 2008 by Marco Hugentobler
00006     email                : marco dot hugentobler at karto dot baug dot ethz dot ch
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018 #include "qgscomposeritem.h"
00019 #include <QSet>
00020 
00024 class CORE_EXPORT QgsComposerItemGroup: public QgsComposerItem
00025 {
00026     Q_OBJECT
00027   public:
00028     QgsComposerItemGroup( QgsComposition* c );
00029     ~QgsComposerItemGroup();
00030 
00032     virtual int type() const { return ComposerItemGroup; }
00033 
00036     void addItem( QgsComposerItem* item );
00038     void removeItems();
00040     void paint( QPainter * painter, const QStyleOptionGraphicsItem * option, QWidget * widget = 0 );
00043     void setSceneRect( const QRectF& rectangle );
00045     void resize( double dx, double dy );
00046 
00051     bool writeXML( QDomElement& elem, QDomDocument & doc ) const { return true; }
00052 
00057     bool readXML( const QDomElement& itemElem, const QDomDocument& doc ) { return true; }
00058 
00059     QSet<QgsComposerItem*> items() { return mItems; }
00060 
00061   signals:
00062     void childItemDeleted( QgsComposerItem* item );
00063 
00064   protected:
00065     void drawFrame( QPainter* p );
00066 
00067   private:
00068     QSet<QgsComposerItem*> mItems;
00069     QRectF mSceneBoundingRectangle;
00070 };
00071 
00072 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines