1 /* 2 For general Scribus (>=1.3.2) copyright and licensing information please refer 3 to the COPYING file provided with the program. Following this notice may exist 4 a copyright and/or license notice that predates the release of Scribus 1.3.2 5 for which a new license (GPL+exception) is in place. 6 */ 7 /*************************************************************************** 8 pageitem_symbol.h - description 9 ------------------- 10 copyright : Scribus Team 11 ***************************************************************************/ 12 13 /*************************************************************************** 14 * * 15 * This program is free software; you can redistribute it and/or modify * 16 * it under the terms of the GNU General Public License as published by * 17 * the Free Software Foundation; either version 2 of the License, or * 18 * (at your option) any later version. * 19 * * 20 ***************************************************************************/ 21 22 #ifndef PAGEITEM_GROUP_H 23 #define PAGEITEM_GROUP_H 24 25 #include <QString> 26 #include <QRectF> 27 28 #include "scribusapi.h" 29 #include "pageitem.h" 30 class ScPainter; 31 class ScribusDoc; 32 33 34 class SCRIBUS_API PageItem_Group : public PageItem 35 { 36 Q_OBJECT 37 38 public: 39 PageItem_Group(ScribusDoc *pa, double x, double y, double w, double h, double w2, const QString& fill, const QString& outline); PageItem_Group(const PageItem & p)40 PageItem_Group(const PageItem & p) : PageItem(p) {} 41 ~PageItem_Group(); 42 asGroupFrame()43 PageItem_Group * asGroupFrame() override { return this; } isGroup()44 bool isGroup() const override { return true; } 45 bool isTextContainer() const override; realItemType()46 ItemType realItemType() const override { return PageItem::Group; } 47 48 void adjustXYPosition(); 49 void setLayer(int layerId) override; 50 void setMasterPage(int page, const QString& mpName) override; 51 void setMasterPageName(const QString& mpName) override; 52 void getNamedResources(ResourceCollection& lists) const override; 53 void replaceNamedResources(ResourceCollection& newNames) override; 54 void applicableActions(QStringList& actionList) override; 55 QString infoDescription() const override; 56 57 /// Retrieve child items of this item getChildren()58 QList<PageItem*> getChildren() const override { return groupItemList; } 59 /// Retrieve all children of item, including children of children 60 QList<PageItem*> getAllChildren() const override; 61 62 void layout() override; 63 64 protected: 65 void DrawObj_Item(ScPainter *p, QRectF e) override; 66 67 }; 68 69 #endif 70