Class: QgsPointPatternFillSymbolLayer

class qgis.core.QgsPointPatternFillSymbolLayer

Bases: QgsImageFillSymbolLayer

Methods

applyBrushTransformFromContext

Returns True if the image brush should be transformed using the render context's texture origin.

applyDataDefinedSettings

param context

clone

rtype

QgsPointPatternFillSymbolLayer

color

rtype

QColor

copyDataDefinedProperties

Copies all data defined properties of this layer to another symbol layer.

copyPaintEffect

Copies paint effect of this layer to another symbol layer

create

Creates a new QgsPointPatternFillSymbolLayer using the specified properties map containing symbol properties (see properties()).

createFromSld

param element

displacementX

rtype

float

displacementXMapUnitScale

rtype

QgsMapUnitScale

displacementXUnit

Returns the units for the horizontal displacement between rows in the pattern.

displacementY

rtype

float

displacementYMapUnitScale

rtype

QgsMapUnitScale

displacementYUnit

Returns the units for the vertical displacement between rows in the pattern.

distanceX

rtype

float

distanceXMapUnitScale

rtype

QgsMapUnitScale

distanceXUnit

Returns the units for the horizontal distance between points in the pattern.

distanceY

rtype

float

distanceYMapUnitScale

rtype

QgsMapUnitScale

distanceYUnit

Returns the units for the vertical distance between points in the pattern.

estimateMaxBleed

param context

hasDataDefinedProperties

rtype

bool

layerType

rtype

str

mapUnitScale

rtype

QgsMapUnitScale

offsetX

Returns the horizontal offset values for points in the pattern.

offsetXMapUnitScale

Returns the unit scale for the horizontal offset for rows in the pattern.

offsetXUnit

Returns the units for the horizontal offset for rows in the pattern.

offsetY

Returns the vertical offset values for points in the pattern.

offsetYMapUnitScale

Returns the unit scale for the vertical offset between rows in the pattern.

offsetYUnit

Returns the units for the vertical offset for rows in the pattern.

outputUnit

rtype

QgsUnitTypes.RenderUnit

properties

rtype

Dict[str, str]

renderPolygon

param points

restoreOldDataDefinedProperties

Restores older data defined properties from string map.

setColor

param c

setDisplacementX

param d

setDisplacementXMapUnitScale

param scale

setDisplacementXUnit

Sets the units for the horizontal displacement between rows in the pattern.

setDisplacementY

param d

setDisplacementYMapUnitScale

param scale

setDisplacementYUnit

Sets the units for the vertical displacement between rows in the pattern.

setDistanceX

param d

setDistanceXMapUnitScale

param scale

setDistanceXUnit

Sets the units for the horizontal distance between points in the pattern.

setDistanceY

param d

setDistanceYMapUnitScale

param scale

setDistanceYUnit

Sets the units for the vertical distance between points in the pattern.

setMapUnitScale

param scale

setOffsetX

Sets the horizontal offset values for points in the pattern.

setOffsetXMapUnitScale

Sets the unit scale for the horizontal offset for rows in the pattern.

setOffsetXUnit

Sets the units for the horizontal offset between rows in the pattern.

setOffsetY

Sets the vertical offset values for points in the pattern.

setOffsetYMapUnitScale

Sets the unit scale for the vertical offset for rows in the pattern.

setOffsetYUnit

Sets the units for the vertical offset for rows in the pattern.

setOutputUnit

param unit

setSubSymbol

param symbol

startRender

param context

stopRender

param context

subSymbol

rtype

QgsSymbol

toSld

param doc

usedAttributes

param context

usesMapUnits

rtype

bool

applyBrushTransformFromContext(self) bool

Returns True if the image brush should be transformed using the render context’s texture origin.

New in version 3.16.

applyDataDefinedSettings(self, context: QgsSymbolRenderContext)
Parameters

context (QgsSymbolRenderContext) –

clone(self) QgsPointPatternFillSymbolLayer
Return type

QgsPointPatternFillSymbolLayer

color(self) QColor
Return type

QColor

copyDataDefinedProperties(self, destLayer: QgsSymbolLayer)

Copies all data defined properties of this layer to another symbol layer.

Parameters

destLayer – destination layer

copyPaintEffect(self, destLayer: QgsSymbolLayer)

Copies paint effect of this layer to another symbol layer

Parameters

destLayer – destination layer

New in version 2.9.

create(properties: Dict[str, str] = {}) QgsSymbolLayer

Creates a new QgsPointPatternFillSymbolLayer using the specified properties map containing symbol properties (see properties()).

Caller takes ownership of the returned symbol layer.

Parameters

properties (Dict[str) –

Return type

QgsSymbolLayer

createFromSld(element: QDomElement) QgsSymbolLayer
Parameters

element (QDomElement) –

Return type

QgsSymbolLayer

displacementX(self) float
Return type

float

displacementXMapUnitScale(self) QgsMapUnitScale
Return type

QgsMapUnitScale

displacementXUnit(self) QgsUnitTypes.RenderUnit

Returns the units for the horizontal displacement between rows in the pattern.

Return type

QgsUnitTypes.RenderUnit

displacementY(self) float
Return type

float

displacementYMapUnitScale(self) QgsMapUnitScale
Return type

QgsMapUnitScale

displacementYUnit(self) QgsUnitTypes.RenderUnit

Returns the units for the vertical displacement between rows in the pattern.

Return type

QgsUnitTypes.RenderUnit

distanceX(self) float
Return type

float

distanceXMapUnitScale(self) QgsMapUnitScale
Return type

QgsMapUnitScale

distanceXUnit(self) QgsUnitTypes.RenderUnit

Returns the units for the horizontal distance between points in the pattern.

See also

distanceYUnit()

Return type

QgsUnitTypes.RenderUnit

distanceY(self) float
Return type

float

distanceYMapUnitScale(self) QgsMapUnitScale
Return type

QgsMapUnitScale

distanceYUnit(self) QgsUnitTypes.RenderUnit

Returns the units for the vertical distance between points in the pattern.

See also

distanceXUnit()

Return type

QgsUnitTypes.RenderUnit

estimateMaxBleed(self, context: QgsRenderContext) float
Parameters

context (QgsRenderContext) –

Return type

float

hasDataDefinedProperties(self) bool
Return type

bool

layerType(self) str
Return type

str

mapUnitScale(self) QgsMapUnitScale
Return type

QgsMapUnitScale

offsetX(self) float

Returns the horizontal offset values for points in the pattern.

See also

setOffsetX()

See also

offsetY()

New in version 3.8.

Return type

float

offsetXMapUnitScale(self) QgsMapUnitScale

Returns the unit scale for the horizontal offset for rows in the pattern.

New in version 3.8.

Return type

QgsMapUnitScale

offsetXUnit(self) QgsUnitTypes.RenderUnit

Returns the units for the horizontal offset for rows in the pattern.

See also

setOffsetXUnit()

See also

offsetYUnit()

New in version 3.8.

Return type

QgsUnitTypes.RenderUnit

offsetY(self) float

Returns the vertical offset values for points in the pattern.

See also

setOffsetY()

See also

offsetX()

New in version 3.8.

Return type

float

offsetYMapUnitScale(self) QgsMapUnitScale

Returns the unit scale for the vertical offset between rows in the pattern.

New in version 3.8.

Return type

QgsMapUnitScale

offsetYUnit(self) QgsUnitTypes.RenderUnit

Returns the units for the vertical offset for rows in the pattern.

See also

setOffsetYUnit()

See also

offsetXUnit()

New in version 3.8.

Return type

QgsUnitTypes.RenderUnit

outputUnit(self) QgsUnitTypes.RenderUnit
Return type

QgsUnitTypes.RenderUnit

properties(self) Dict[str, str]
Return type

Dict[str, str]

renderPolygon(self, points: QPolygonF, rings: Iterable[QPolygonF], context: QgsSymbolRenderContext)
Parameters
restoreOldDataDefinedProperties(self, stringMap: Dict[str, str])

Restores older data defined properties from string map.

New in version 3.0.

setColor(self, c: Union[QColor, Qt.GlobalColor])
Parameters

c (Union[QColor) –

setDisplacementX(self, d: float)
Parameters

d (float) –

setDisplacementXMapUnitScale(self, scale: QgsMapUnitScale)
Parameters

scale (QgsMapUnitScale) –

setDisplacementXUnit(self, unit: QgsUnitTypes.RenderUnit)

Sets the units for the horizontal displacement between rows in the pattern.

Parameters

unit (QgsUnitTypes.RenderUnit) – displacement units

setDisplacementY(self, d: float)
Parameters

d (float) –

setDisplacementYMapUnitScale(self, scale: QgsMapUnitScale)
Parameters

scale (QgsMapUnitScale) –

setDisplacementYUnit(self, unit: QgsUnitTypes.RenderUnit)

Sets the units for the vertical displacement between rows in the pattern.

Parameters

unit (QgsUnitTypes.RenderUnit) – displacement units

setDistanceX(self, d: float)
Parameters

d (float) –

setDistanceXMapUnitScale(self, scale: QgsMapUnitScale)
Parameters

scale (QgsMapUnitScale) –

setDistanceXUnit(self, unit: QgsUnitTypes.RenderUnit)

Sets the units for the horizontal distance between points in the pattern.

Parameters

unit (QgsUnitTypes.RenderUnit) – distance units

See also

distanceXUnit()

setDistanceY(self, d: float)
Parameters

d (float) –

setDistanceYMapUnitScale(self, scale: QgsMapUnitScale)
Parameters

scale (QgsMapUnitScale) –

setDistanceYUnit(self, unit: QgsUnitTypes.RenderUnit)

Sets the units for the vertical distance between points in the pattern.

Parameters

unit (QgsUnitTypes.RenderUnit) – distance units

See also

distanceYUnit()

setMapUnitScale(self, scale: QgsMapUnitScale)
Parameters

scale (QgsMapUnitScale) –

setOffsetX(self, offset: float)

Sets the horizontal offset values for points in the pattern.

Parameters

offset (float) – offset value

See also

offsetX()

See also

setOffsetY()

New in version 3.8.

setOffsetXMapUnitScale(self, scale: QgsMapUnitScale)

Sets the unit scale for the horizontal offset for rows in the pattern.

Parameters

scale (QgsMapUnitScale) – offset unit scale

New in version 3.8.

setOffsetXUnit(self, unit: QgsUnitTypes.RenderUnit)

Sets the units for the horizontal offset between rows in the pattern.

Parameters

unit (QgsUnitTypes.RenderUnit) – offset units

See also

offsetXUnit()

See also

setOffsetYUnit()

New in version 3.8.

setOffsetY(self, offset: float)

Sets the vertical offset values for points in the pattern.

Parameters

offset (float) – offset value

See also

offsetY()

See also

setOffsetX()

New in version 3.8.

setOffsetYMapUnitScale(self, scale: QgsMapUnitScale)

Sets the unit scale for the vertical offset for rows in the pattern.

Parameters

scale (QgsMapUnitScale) – offset unit scale

New in version 3.8.

setOffsetYUnit(self, unit: QgsUnitTypes.RenderUnit)

Sets the units for the vertical offset for rows in the pattern.

Parameters

unit (QgsUnitTypes.RenderUnit) – offset units

See also

offsetYUnit()

See also

setOffsetXUnit()

New in version 3.8.

setOutputUnit(self, unit: QgsUnitTypes.RenderUnit)
Parameters

unit (QgsUnitTypes.RenderUnit) –

setSubSymbol(self, symbol: QgsSymbol) bool
Parameters

symbol (QgsSymbol) –

Return type

bool

startRender(self, context: QgsSymbolRenderContext)
Parameters

context (QgsSymbolRenderContext) –

stopRender(self, context: QgsSymbolRenderContext)
Parameters

context (QgsSymbolRenderContext) –

subSymbol(self) QgsSymbol
Return type

QgsSymbol

toSld(self, doc: QDomDocument, element: QDomElement, props: Dict[str, str])
Parameters
  • doc (QDomDocument) –

  • element (QDomElement) –

  • props (Dict[str) –

usedAttributes(self, context: QgsRenderContext) Set[str]
Parameters

context (QgsRenderContext) –

Return type

Set[str]

usesMapUnits(self) bool
Return type

bool