FillPaint¶
Namespace: ThinkGeo.Core.Styling
public struct FillPaint
Inheritance object → ValueType → FillPaint
Properties¶
Color¶
public GeoColor Color { get; }
Property Value¶
Opacity¶
public float Opacity { get; }
Property Value¶
OutlineColor¶
The fill-outline-color, or null when the style did not set one.
public GeoColor OutlineColor { get; }
Property Value¶
Antialias¶
The fill-antialias, which belongs to the whole layer. MapStyle.AddFillLayer(string, string, string, FillPaint, string, JsonNode, Nullable<double>, Nullable<double>, StyleLayerSlot) writes it into the document; in a StyleLayer.CreateFill(string, string, Func<Feature, double, FillPaint>, Func<Feature, double, bool>, Nullable<double>, Nullable<double>, bool, string) paint callback it is not read, and the layer's antialias argument decides.
public bool Antialias { get; }
Property Value¶
TranslateX¶
public float TranslateX { get; }
Property Value¶
TranslateY¶
public float TranslateY { get; }
Property Value¶
TranslateAnchor¶
fill-translate-anchor: what the translate is measured against - the map (the default), turning with it, or the screen, staying put as the map rotates (mapbox/streets-v12's water-shadow is the canonical case).
public StyleAnchor TranslateAnchor { get; }
Property Value¶
Constructors¶
FillPaint(GeoColor, float, GeoColor, bool, float, float, StyleAnchor)¶
FillPaint(GeoColor color, float opacity, GeoColor outlineColor, bool antialias, float translateX, float translateY, StyleAnchor translateAnchor)
Parameters¶
color GeoColor
opacity float
outlineColor GeoColor
antialias bool
translateX float
translateY float
translateAnchor StyleAnchor
Methods¶
FromAreaStyle(AreaStyle)¶
The fill of a classic AreaStyle. A solid brush is the colour, alpha and all - fill-color carries alpha, so opacity stays 1. A hatch brush contributes its background colour here; its pattern is an image, registered from the style with MapStyle.Images.Add(name, areaStyle) and named on the layer as its fill-pattern - MapStyle.AddFeatureLayer does both. The outline pen becomes fill-outline-color when it is one solid pixel wide, which is all that property can draw; a wider or dashed pen is a line layer of its own, see LinePaint.FromGeoPen(GeoPen). Gradient and texture brushes have no fill-color, and throw.
FillPaint FromAreaStyle(AreaStyle style)
Parameters¶
style AreaStyle