Docsv3.11.0
Back to API Reference
Class

AlphaModifier

sealed
Inherits:GlyphModifier<byte>

Per-range opacity: a multiplier on the alpha of each glyph and of every layer drawn from it.

Remarks

Parameter: an opacity from 0 to 1 written as a fraction (0.5), a percentage (50%) or a two-digit hex byte (#80); values outside the range clamp. A fully transparent glyph keeps its place in the layout. The opacity multiplies the alpha the glyph carries at GlyphOpacityOrder, which already includes the component's alpha and a ColorModifier colour's, so fills, strokes, shadows, glows, extrusions, decoration lines, colour emoji and inline sprites fade with their glyph. Inline objects placed as scene objects and range backgrounds such as highlights keep their own opacity. Overlapping ranges resolve innermost-wins and never compound, across modifiers as well as across nested tags.
public float Alpha{ get; set }

Opacity the range multiplies its glyphs' alpha by: 1 leaves them unchanged, 0 makes them invisible. A per-range value overrides it.

protected string AttributeKey{ get }
protected int GlyphCallbackOrder{ get }
protected override Action GetOnGlyphCallback()
protected override void DoApply()

See Also