Class: QgsInterpolatedLineSymbolLayer¶
- class qgis.core.QgsInterpolatedLineSymbolLayer¶
Bases:
QgsLineSymbolLayer
A symbol layer that represents vector layer line feature as interpolated line The interpolation is done between two values defined at the extremities
New in version 3.20.
QgsInterpolatedLineSymbolLayer() Constructor
Methods
- rtype:
bool
- rtype:
QgsInterpolatedLineSymbolLayer
- 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 the symbol layer
- param context:
Returns the expression related to the end extremity value for width for color
Returns the expression related to the end extremity value for width.
- rtype:
Qgis.SymbolLayerFlags
When rendering, install masks on
context
painter ifrecursive
isTrue
masks are installed recursively for all children symbol layersReturns the interpolated color used to render the colors of lines, see
:py:class:`QgsInterpolatedLineColor`
.Returns the interpolated width used to render the width of lines, see
:py:class:`QgsInterpolatedLineWidth`
.- rtype:
str
- rtype:
Dict[str, Any]
When rendering, remove previously installed masks from
context
painter ifrecursive
isTrue
masks are removed recursively for all children symbol layers- param points:
Restores older data defined properties from string map.
Sets the expressions (as string) that define the extremety values af the line feature for color.
Sets the expressions (as string) that define the extremety values af the line feature for width.
Sets the interpolated color used to render the colors of lines,
see
QgsInterpolatedLineColor
.Sets the interpolated width used to render the width of lines,
see
QgsInterpolatedLineWidth
.Sets the width unit.
Returns
True
if the symbol layer should be rendered using the selection color from the render context.- param feature:
- param context:
Returns the epression related to the start extremity value for width for color
Returns the epression related to the start extremity value for width.
- param feature:
- param context:
Returns the width unit.
- canCauseArtifactsBetweenAdjacentTiles(self) bool ¶
- Return type:
bool
- clone(self) QgsInterpolatedLineSymbolLayer ¶
- 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 the symbol layer
- Parameters:
properties (Dict[str) –
- Return type:
- drawPreviewIcon(self, context: QgsSymbolRenderContext, size: QSize)¶
- Parameters:
context (QgsSymbolRenderContext) –
size (QSize) –
- endValueExpressionForColor(self) str ¶
Returns the expression related to the end extremity value for width for color
Deprecated since version use: dataDefinedProperty(
QgsSymbolLayer
.PropertyLineEndColorValue ) instead.- Return type:
str
- endValueExpressionForWidth(self) str ¶
Returns the expression related to the end extremity value for width.
Deprecated since version use: dataDefinedProperty(
QgsSymbolLayer
.PropertyLineEndWidthValue ) instead.- Return type:
str
- flags(self) Qgis.SymbolLayerFlags ¶
- Return type:
- installMasks(self, context: QgsRenderContext, recursive: bool)¶
When rendering, install masks on
context
painter ifrecursive
isTrue
masks are installed recursively for all children symbol layersSee also
prepareMasks()
See also
New in version 3.30.
- interpolatedColor(self) QgsInterpolatedLineColor ¶
Returns the interpolated color used to render the colors of lines, see
:py:class:`QgsInterpolatedLineColor`
.See also
- Return type:
- interpolatedWidth(self) QgsInterpolatedLineWidth ¶
Returns the interpolated width used to render the width of lines, see
:py:class:`QgsInterpolatedLineWidth`
.See also
- Return type:
- layerType(self) str ¶
- Return type:
str
- properties(self) Dict[str, Any] ¶
- Return type:
Dict[str, Any]
- removeMasks(self, context: QgsRenderContext, recursive: bool)¶
When rendering, remove previously installed masks from
context
painter ifrecursive
isTrue
masks are removed recursively for all children symbol layersSee also
prepareMasks()
See also
New in version 3.30.
- renderPolyline(self, points: QPolygonF, context: QgsSymbolRenderContext)¶
- Parameters:
points (QPolygonF) –
context (QgsSymbolRenderContext) –
- restoreOldDataDefinedProperties(self, stringMap: Dict[str, Any])¶
Restores older data defined properties from string map.
New in version 3.0.
- setExpressionsStringForColor(self, start: str, end: str)¶
Sets the expressions (as string) that define the extremety values af the line feature for color.
Deprecated since version use: setDataDefinedProperty(
QgsSymbolLayer
.PropertyLineStartColorValue ) and setDataDefinedProperty(QgsSymbolLayer
.PropertyLineEndColorValue ) instead- Parameters:
start (str) –
end (str) –
- setExpressionsStringForWidth(self, start: str, end: str)¶
Sets the expressions (as string) that define the extremety values af the line feature for width.
Deprecated since version use: setDataDefinedProperty(
QgsSymbolLayer
.PropertyLineStartWidthValue ) and setDataDefinedProperty(QgsSymbolLayer
.PropertyLineEndWidthValue ) instead- Parameters:
start (str) –
end (str) –
- setInterpolatedColor(self, interpolatedLineColor: QgsInterpolatedLineColor)¶
Sets the interpolated color used to render the colors of lines,
see
QgsInterpolatedLineColor
.See also
- Parameters:
interpolatedLineColor (QgsInterpolatedLineColor) –
- setInterpolatedWidth(self, interpolatedLineWidth: QgsInterpolatedLineWidth)¶
Sets the interpolated width used to render the width of lines,
see
QgsInterpolatedLineWidth
.See also
- Parameters:
interpolatedLineWidth (QgsInterpolatedLineWidth) –
- setWidthUnit(self, strokeWidthUnit: Qgis.RenderUnit)¶
Sets the width unit.
See also
- Parameters:
strokeWidthUnit (Qgis.RenderUnit) –
- shouldRenderUsingSelectionColor(self, context: QgsSymbolRenderContext) bool ¶
Returns
True
if the symbol layer should be rendered using the selection color from the render context.New in version 3.34.
- startFeatureRender(self, feature: QgsFeature, context: QgsRenderContext)¶
- Parameters:
feature (QgsFeature) –
context (QgsRenderContext) –
- startRender(self, context: QgsSymbolRenderContext)¶
- Parameters:
context (QgsSymbolRenderContext) –
- startValueExpressionForColor(self) str ¶
Returns the epression related to the start extremity value for width for color
Deprecated since version use: dataDefinedProperty(
QgsSymbolLayer
.PropertyLineStartColorValue ) instead.- Return type:
str
- startValueExpressionForWidth(self) str ¶
Returns the epression related to the start extremity value for width.
Deprecated since version use: dataDefinedProperty(
QgsSymbolLayer
.PropertyLineStartWidthValue ) instead.- Return type:
str
- stopFeatureRender(self, feature: QgsFeature, context: QgsRenderContext)¶
- Parameters:
feature (QgsFeature) –
context (QgsRenderContext) –
- stopRender(self, context: QgsSymbolRenderContext)¶
- Parameters:
context (QgsSymbolRenderContext) –
- widthUnit(self) Qgis.RenderUnit ¶
Returns the width unit.
See also
- Return type: