Class: QgsLinePatternFillSymbolLayer¶
- class qgis.core.QgsLinePatternFillSymbolLayer¶
Bases:
QgsImageFillSymbolLayer
A symbol fill consisting of repeated parallel lines.
Methods
Returns
True
if the image brush should be transformed using the render context's texture origin.- param context
Returns the line clipping mode, which defines how lines are clipped at the edges of shapes.
- rtype
QgsLinePatternFillSymbolLayer
- rtype
QColor
Copies all data defined properties of this layer to another symbol layer.
Copies paint effect of this layer to another symbol layer
Creates a new
QgsLinePatternFillSymbolLayer
from aproperties
map.Creates a new
QgsLinePatternFillSymbolLayer
from a SLDelement
.Returns the distance between lines in the fill pattern.
Returns the map unit scale for the pattern's line distance.
Returns the units for the distance between lines in the fill pattern.
- param context
- rtype
bool
- rtype
str
Returns the angle for the parallel lines used to fill the symbol.
Returns the width of the line subsymbol used to render the parallel lines in the fill.
Returns the map unit scale for the pattern's line width.
Returns the units for the line's width.
- rtype
QgsMapUnitScale
Returns the offset distance for lines within the fill, which is the distance to offset the parallel lines from their normal position.
Returns the map unit scale for the pattern's line offset.
Returns the units for the line pattern's offset.
- param widthScaleFactor
- rtype
QgsUnitTypes.RenderUnit
- rtype
Dict[str, Any]
- param points
Restores older data defined properties from string map.
Sets the line clipping
mode
, which defines how lines are clipped at the edges of shapes.- param c
Sets the distance between lines in the fill pattern.
Sets the map unit
scale
for the pattern's line distance.Sets the
unit
for the distance between lines in the fill pattern.Sets the angle for the parallel lines used to fill the symbol.
Sets the width of the line subsymbol used to render the parallel lines in the fill.
Sets the map unit
scale
for the pattern's line width.Sets the
unit
for the line's width.- param scale
Sets the
offset
distance for lines within the fill, which is the distance to offset the parallel lines from their normal position.Sets the map unit
scale
for the pattern's line offset.Sets the
unit
for the line pattern's offset.- param unit
- param symbol
- param feature
- param context
- param feature
- param context
- rtype
QgsSymbol
- param doc
- param context
- rtype
bool
- applyBrushTransformFromContext(self, context: QgsSymbolRenderContext = None) 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) –
- clipMode(self) Qgis.LineClipMode ¶
Returns the line clipping mode, which defines how lines are clipped at the edges of shapes.
See also
New in version 3.24.
- Return type
- clone(self) QgsLinePatternFillSymbolLayer ¶
- Return type
- 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, Any] = {}) QgsSymbolLayer ¶
Creates a new
QgsLinePatternFillSymbolLayer
from aproperties
map. The caller takes ownership of the returned object.- Parameters
properties (Dict[str) –
- Return type
- createFromSld(element: QDomElement) QgsSymbolLayer ¶
Creates a new
QgsLinePatternFillSymbolLayer
from a SLDelement
. The caller takes ownership of the returned object.- Parameters
element (QDomElement) –
- Return type
- distance(self) float ¶
Returns the distance between lines in the fill pattern. Units are retrieved by
distanceUnit()
.See also
See also
- Return type
float
- distanceMapUnitScale(self) QgsMapUnitScale ¶
Returns the map unit scale for the pattern’s line distance.
See also
See also
See also
- Return type
- distanceUnit(self) QgsUnitTypes.RenderUnit ¶
Returns the units for the distance between lines in the fill pattern.
See also
See also
- Return type
- estimateMaxBleed(self, context: QgsRenderContext) float ¶
- Parameters
context (QgsRenderContext) –
- Return type
float
- hasDataDefinedProperties(self) bool ¶
- Return type
bool
- layerType(self) str ¶
- Return type
str
- lineAngle(self) float ¶
Returns the angle for the parallel lines used to fill the symbol.
Angles are in degrees, clockwise from North.
See also
- Return type
float
- lineWidth(self) float ¶
Returns the width of the line subsymbol used to render the parallel lines in the fill.
See also
- Return type
float
- lineWidthMapUnitScale(self) QgsMapUnitScale ¶
Returns the map unit scale for the pattern’s line width.
See also
See also
See also
- Return type
- lineWidthUnit(self) QgsUnitTypes.RenderUnit ¶
Returns the units for the line’s width.
See also
- Return type
- mapUnitScale(self) QgsMapUnitScale ¶
- Return type
- offset(self) float ¶
Returns the offset distance for lines within the fill, which is the distance to offset the parallel lines from their normal position.
Units are retrieved via
offsetUnit()
.See also
See also
See also
- Return type
float
- offsetMapUnitScale(self) QgsMapUnitScale ¶
Returns the map unit scale for the pattern’s line offset.
See also
See also
See also
- Return type
- offsetUnit(self) QgsUnitTypes.RenderUnit ¶
Returns the units for the line pattern’s offset.
See also
- Return type
- ogrFeatureStyleWidth(self, widthScaleFactor: float) str ¶
- Parameters
widthScaleFactor (float) –
- Return type
str
- outputUnit(self) QgsUnitTypes.RenderUnit ¶
- Return type
- properties(self) Dict[str, Any] ¶
- Return type
Dict[str, Any]
- renderPolygon(self, points: QPolygonF, rings: Iterable[QPolygonF], context: QgsSymbolRenderContext)¶
- Parameters
points (QPolygonF) –
rings (Iterable[QPolygonF]) –
context (QgsSymbolRenderContext) –
- restoreOldDataDefinedProperties(self, stringMap: Dict[str, Any])¶
Restores older data defined properties from string map.
New in version 3.0.
- setClipMode(self, mode: Qgis.LineClipMode)¶
Sets the line clipping
mode
, which defines how lines are clipped at the edges of shapes.See also
New in version 3.24.
- Parameters
mode (Qgis.LineClipMode) –
- setColor(self, c: Union[QColor, Qt.GlobalColor, QGradient])¶
- Parameters
c (Union[QColor) –
- setDistance(self, d: float)¶
Sets the distance between lines in the fill pattern.
- Parameters
d (float) – distance. Units are specified by
setDistanceUnit()
See also
See also
- setDistanceMapUnitScale(self, scale: QgsMapUnitScale)¶
Sets the map unit
scale
for the pattern’s line distance.See also
See also
See also
- Parameters
scale (QgsMapUnitScale) –
- setDistanceUnit(self, unit: QgsUnitTypes.RenderUnit)¶
Sets the
unit
for the distance between lines in the fill pattern.See also
See also
- Parameters
unit (QgsUnitTypes.RenderUnit) –
- setLineAngle(self, a: float)¶
Sets the angle for the parallel lines used to fill the symbol.
Angles are in degrees, clockwise from North.
See also
- Parameters
a (float) –
- setLineWidth(self, w: float)¶
Sets the width of the line subsymbol used to render the parallel lines in the fill.
See also
- Parameters
w (float) –
- setLineWidthMapUnitScale(self, scale: QgsMapUnitScale)¶
Sets the map unit
scale
for the pattern’s line width.See also
See also
See also
- Parameters
scale (QgsMapUnitScale) –
- setLineWidthUnit(self, unit: QgsUnitTypes.RenderUnit)¶
Sets the
unit
for the line’s width.See also
- Parameters
unit (QgsUnitTypes.RenderUnit) –
- setMapUnitScale(self, scale: QgsMapUnitScale)¶
- Parameters
scale (QgsMapUnitScale) –
- setOffset(self, offset: float)¶
Sets the
offset
distance for lines within the fill, which is the distance to offset the parallel lines from their normal position.Units are specified via
setOffsetUnit()
.See also
See also
See also
- Parameters
offset (float) –
- setOffsetMapUnitScale(self, scale: QgsMapUnitScale)¶
Sets the map unit
scale
for the pattern’s line offset.See also
See also
See also
- Parameters
scale (QgsMapUnitScale) –
- setOffsetUnit(self, unit: QgsUnitTypes.RenderUnit)¶
Sets the
unit
for the line pattern’s offset.See also
- Parameters
unit (QgsUnitTypes.RenderUnit) –
- setOutputUnit(self, unit: QgsUnitTypes.RenderUnit)¶
- Parameters
unit (QgsUnitTypes.RenderUnit) –
- startFeatureRender(self, feature: QgsFeature, context: QgsRenderContext)¶
- Parameters
feature (QgsFeature) –
context (QgsRenderContext) –
- startRender(self, context: QgsSymbolRenderContext)¶
- Parameters
context (QgsSymbolRenderContext) –
- stopFeatureRender(self, feature: QgsFeature, context: QgsRenderContext)¶
- Parameters
feature (QgsFeature) –
context (QgsRenderContext) –
- stopRender(self, context: QgsSymbolRenderContext)¶
- Parameters
context (QgsSymbolRenderContext) –
- toSld(self, doc: QDomDocument, element: QDomElement, props: Dict[str, Any])¶
- 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