diff options
| author | Martin <mhaug@live.de> | 2021-03-19 22:36:13 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-03-19 22:36:13 +0100 |
| commit | 6cb9fe9064a037224b6560b69b441b72e787fa94 (patch) | |
| tree | 9a5474758e37199c7a01c6d22383ede225deab4d /src/layout/text.rs | |
| parent | 898dc38ec153709929d2513fb9d040dd2c1ce0fe (diff) | |
Text colors 🦩 (#18)
Diffstat (limited to 'src/layout/text.rs')
| -rw-r--r-- | src/layout/text.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/layout/text.rs b/src/layout/text.rs index 7faefa0d..7f8f97cc 100644 --- a/src/layout/text.rs +++ b/src/layout/text.rs @@ -24,6 +24,8 @@ pub struct TextNode { pub top_edge: VerticalFontMetric, /// The bottom end of the text bounding box. pub bottom_edge: VerticalFontMetric, + /// The glyph fill. + pub color: Fill, } impl Layout for TextNode { @@ -37,6 +39,7 @@ impl Layout for TextNode { self.font_size, self.top_edge, self.bottom_edge, + self.color, &mut ctx.env.fonts, ), self.aligns, |
