17 #ifndef QGSCOMPOSERMAPITEM_H 18 #define QGSCOMPOSERMAPITEM_H 45 virtual void draw(
QPainter* painter ) = 0;
94 virtual void setEnabled(
const bool enabled ) { mEnabled = enabled; }
100 virtual bool enabled()
const {
return mEnabled; }
147 int size()
const {
return mItems.size(); }
168 void drawItems(
QPainter* painter );
174 bool containsAdvancedEffects()
const;
194 void removeItem(
const QString& itemId );
202 void moveItemUp(
const QString& itemId );
210 void moveItemDown(
const QString& itemId );
259 #endif //QGSCOMPOSERMAPITEM_H
A base class for objects which belong to a map composition.
virtual const QgsComposerMap * composerMap() const
Get composer map for the item.
QString mName
Friendly display name.
virtual bool writeXML(QDomElement &elem, QDomDocument &doc) const
Stores item state in DOM element.
An item which is drawn inside a QgsComposerMap, eg a grid or map overview.
virtual bool enabled() const
Returns whether the item will be drawn.
virtual bool usesAdvancedEffects() const
Returns true if the item is drawn using advanced effects, such as blend modes.
const char * name() const
virtual QString name() const
Get friendly display name for the item.
bool mEnabled
True if item is to be displayed on map.
virtual void setEnabled(const bool enabled)
Controls whether the item will be drawn.
QgsComposerMap * mComposerMap
Associated composer map.
Object representing map window.
QList< QgsComposerMapItem *> mItems
virtual bool readXML(const QDomElement &itemElem, const QDomDocument &doc)
Sets item state from DOM element.
QString id() const
Get the unique id for the map item.
A collection of map items which are drawn above the map content in a QgsComposerMap.
virtual void setName(const QString &name)
Sets the friendly display name for the item.
int size() const
Returns the number of items in the stack.
QgsComposerMap * mComposerMap