212 void setShapeType(QgsLayoutItemShape::Shape type)
Sets the type of shape (e.g.
QMap< int, QString > itemTypes() const
Returns a map of available item types to translated name.
static QgsLayoutItemHtml * create(QgsLayout *layout)
Returns a new QgsLayoutItemHtml for the specified parent layout.
Base class for graphical items within a QgsLayout.
QgsLayoutMultiFrameAbstractMetadata * multiFrameMetadata(int type) const
Returns the metadata for the specified multiframe type.
static QgsLayoutItemTextTable * create(QgsLayout *layout)
Returns a new QgsLayoutItemTextTable for the specified parent layout.
static QgsLayoutItemGroup * create(QgsLayout *layout)
Returns a new group item for the specified layout.
bool addLayoutMultiFrameType(QgsLayoutMultiFrameAbstractMetadata *metadata)
Registers a new layout multiframe type.
static QgsLayoutItemPolygon * create(QgsLayout *layout)
Returns a new polygon item for the specified layout.
double convertToPainterUnits(double size, QgsUnitTypes::RenderUnit unit, const QgsMapUnitScale &scale=QgsMapUnitScale()) const
Converts a size from the specified units to painter units (pixels).
static QgsFillSymbol * createSimple(const QgsStringMap &properties)
Create a fill symbol with one symbol layer: SimpleFill with specified properties. ...
QgsLayoutItem * createItem(int type, QgsLayout *layout) const
Creates a new instance of a layout item given the item type, and target layout.
static QgsLayoutItemMap * create(QgsLayout *layout)
Returns a new map item for the specified layout.
static QgsLayoutItemLabel * create(QgsLayout *layout)
Returns a new label item for the specified layout.
void resolvePaths(int type, QVariantMap &properties, const QgsPathResolver &pathResolver, bool saving) const
Resolve paths in properties of a particular symbol layer.
void multiFrameTypeAdded(int type, const QString &name)
Emitted whenever a new multiframe type is added to the registry, with the specified type and visible ...
static QgsLayoutItemPicture * create(QgsLayout *layout)
Returns a new picture item for the specified layout.
bool populate()
Populates the registry with standard item types.
QgsLayoutItemRegistry(QObject *parent=nullptr)
Creates a new empty item registry.
QMap< QString, QString > QgsStringMap
Abstract base class for layout items with the ability to distribute the content to several frames (Qg...
~QgsLayoutItemRegistry() override
QgsLayoutItemAbstractMetadata * itemMetadata(int type) const
Returns the metadata for the specified item type.
Layout item for basic filled shapes (e.g.
QgsLayoutMultiFrame * createMultiFrame(int type, QgsLayout *layout) const
Creates a new instance of a layout multiframe given the multiframe type, and target layout...
A paint effect which consists of a stack of other chained paint effects.
Base class for layouts, which can contain items such as maps, labels, scalebars, etc.
void appendEffect(QgsPaintEffect *effect)
Appends an effect to the end of the stack.
Frame item, part of a QgsLayoutMultiFrame object.
static QgsLayoutItemAttributeTable * create(QgsLayout *layout)
Returns a new QgsLayoutItemAttributeTable for the specified parent layout.
static QgsLayoutItemPolyline * create(QgsLayout *layout)
Returns a new polyline item for the specified layout.
static QgsLayoutItemLegend * create(QgsLayout *layout)
Returns a new legend item for the specified layout.
Contains information about the context of a rendering operation.
QPainter * painter()
Returns the destination QPainter for the render operation.
static QgsLayoutItemPage * create(QgsLayout *layout)
Returns a new page item for the specified layout.
bool addLayoutItemType(QgsLayoutItemAbstractMetadata *metadata)
Registers a new layout item type.
A paint effect which draws a glow within a picture.
A paint effect which draws the source picture with minor or no alterations.
Resolves relative paths into absolute paths and vice versa.
virtual void end(QgsRenderContext &context)
Ends interception of paint operations to a render context, and draws the result to the render context...
virtual void begin(QgsRenderContext &context)
Begins intercepting paint operations to a render context.
static QgsLayoutFrame * create(QgsLayout *layout)
Creates a new QgsLayoutFrame belonging to the specified layout.
void typeAdded(int type, const QString &name)
Emitted whenever a new item type is added to the registry, with the specified type and visible name...
static QgsLayoutItemScaleBar * create(QgsLayout *layout)
Returns a new scale bar item for the specified layout.