ui::TextEffect¶
Header: winui/render/Text.hpp.
A multi-pass text effect carried by TextStyle::effect; the classic themes use it for the engraved disabled-button label. The run's own color is ignored while an effect is active: the renderer draws highlight at (offset_x, offset_y) first, then shadow on the origin. Measuring is unaffected.
Example:
ui::TextStyle style;
style.effect = ui::TextEffect{ui::TextEffectKind::Emboss, ui::colors::White,
ui::Color::from_argb(0xFF808080), 1.0f, 1.0f};
| Field | Type | Default | |
|---|---|---|---|
kind |
TextEffectKind |
TextEffectKind::None |
Which effect to apply; None disables the extra pass entirely. |
highlight |
Color |
colors::White |
Color of the offset raised pass, the classic 3D highlight color. |
shadow |
Color |
colors::Black |
Color of the base pass on the origin, the classic 3D shadow color. |
offset_x |
float |
1.0f |
Horizontal offset of the highlight pass, in DIPs. |
offset_y |
float |
1.0f |
Vertical offset of the highlight pass, in DIPs. |