Back to API Reference
Class

BaseLineModifier

abstract
Inherits:BaseModifier

Base class for modifiers that render horizontal lines across text (underline, strikethrough).

Remarks

Subclasses define the vertical offset of the line relative to the baseline. Lines break across wrapped text lines automatically. Decoration quads run through the standard onGlyph pipeline with isVirtualGlyph set, so per-glyph modifiers (color, gradient, outline, shadow) apply uniformly to face glyphs and decoration lines. An overlay range raises that whole stack — the line and every layer applied to it — above the text it crosses, instead of interleaving each layer at its own position in Styles.

Derived Types(2)

Types that inherit from BaseLineModifier.

public int LayerSequence{ get; set }
public bool RendersBehindFill{ get }
public bool ClaimsFill{ get }
public IPaintProvider Provider{ get; set }

Source of named paint swatches resolved by this decoration line.

public PaintRef Paint{ get; set }

Line paint (inline colour or named swatch); the default inherits the text fill. A per-range value overrides it.

public LineStyle Style{ get; set }

Line style (solid, double, dotted, dashed, wavy). A per-range value overrides it.

public UnitValue Thickness{ get; set }

Line thickness; zero = auto (font metric). A per-range value overrides it.

public UnitValue Offset{ get; set }

Vertical offset from the metric line position. A per-range value overrides it.

public bool SkipInk{ get; set }

Break the line where descenders/ascenders cross it. A per-range value overrides it.

public LayerBlend Blend{ get; set }

How the line composites; Inherit uses its paint or the fill inherited by currentColor.

public bool Overlay{ get; set }

Draws the line and every layer applied to it above the whole text, instead of stacking each layer at its own position in Styles. A per-range value overrides it.

protected string AttributeKey{ get }

Stable name of the decoration this subclass draws.

protected abstract float GetLineOffset()
protected override void OnEnable()
protected override void OnDisable()
protected override void BeforeApply()

The previous paint resolution must reset before the re-run OnApply.

protected override void OnDestroy()
protected override void OnApply()
protected PooledArrayAttribute<byte> flagsAttribute
protected PooledList<LineParams> paramsList

See Also