Class: QgsDiagramSettings

class qgis.core.QgsDiagramSettings

Bases: sip.wrapper

Constructor for QgsDiagramSettings

QgsDiagramSettings(QgsDiagramSettings)

Stores the settings for rendering a single diagram.

QgsDiagramSettings stores the settings related to rendering the individual diagrams themselves, while QgsDiagramLayerSettings stores settings which control how ALL diagrams within a layer are rendered.

Enums

Methods

legendItems Returns list of legend nodes for the diagram
readXml Reads diagram settings from XML
writeXml Writes diagram settings to XML

Signals

Attributes

Down
Height
Left
Right
Up
XHeight
qgis.core.QgsDiagramSettings.backgroundColor
qgis.core.QgsDiagramSettings.barWidth
qgis.core.QgsDiagramSettings.categoryAttributes
qgis.core.QgsDiagramSettings.categoryColors
qgis.core.QgsDiagramSettings.categoryLabels
qgis.core.QgsDiagramSettings.diagramOrientation
qgis.core.QgsDiagramSettings.enabled
qgis.core.QgsDiagramSettings.font
qgis.core.QgsDiagramSettings.labelPlacementMethod
qgis.core.QgsDiagramSettings.lineSizeScale
qgis.core.QgsDiagramSettings.lineSizeUnit
qgis.core.QgsDiagramSettings.maximumScale
qgis.core.QgsDiagramSettings.minimumScale
qgis.core.QgsDiagramSettings.minimumSize
qgis.core.QgsDiagramSettings.opacity
qgis.core.QgsDiagramSettings.penColor
qgis.core.QgsDiagramSettings.penWidth
qgis.core.QgsDiagramSettings.rotationOffset
qgis.core.QgsDiagramSettings.scaleBasedVisibility
qgis.core.QgsDiagramSettings.scaleByArea
qgis.core.QgsDiagramSettings.size
qgis.core.QgsDiagramSettings.sizeScale
qgis.core.QgsDiagramSettings.sizeType
class DiagramOrientation

Bases: int

Down = 1
Height = 0
class LabelPlacementMethod

Bases: int

Left = 2
Right = 3
Up = 0
XHeight = 1
backgroundColor
barWidth
categoryAttributes
categoryColors
categoryLabels
diagramOrientation
enabled
font
labelPlacementMethod
legendItems(self, nodeLayer: QgsLayerTreeLayer) → object

Returns list of legend nodes for the diagram

Note

caller is responsible for deletion of QgsLayerTreeModelLegendNodes

New in version 2.10.

lineSizeScale
lineSizeUnit
maximumScale
minimumScale
minimumSize
opacity
penColor
penWidth
readXml(self, elem: QDomElement)

Reads diagram settings from XML

rotationOffset
scaleBasedVisibility
scaleByArea
size
sizeScale
sizeType
writeXml(self, rendererElem: QDomElement, doc: QDomDocument)

Writes diagram settings to XML