diff options
| author | Laurenz <laurmaedje@gmail.com> | 2020-10-13 13:51:58 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2020-10-13 13:51:58 +0200 |
| commit | 91e512069396f1de616ec2b0fe0cd31a76e7f2e9 (patch) | |
| tree | 204ef6032dd4d22b38236d4d85fc95c97e7a9f37 /src/layout/text.rs | |
| parent | 8680fcd4903b451909a5932e8b948a68c9aacb16 (diff) | |
BoxAlign and Flow aliases ✏
Diffstat (limited to 'src/layout/text.rs')
| -rw-r--r-- | src/layout/text.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/layout/text.rs b/src/layout/text.rs index 0ded4f9d..fc319fa5 100644 --- a/src/layout/text.rs +++ b/src/layout/text.rs @@ -11,16 +11,16 @@ use crate::shaping; pub struct Text { /// The text. pub text: String, - /// The font size. - pub font_size: Length, + /// How to align this text node in its parent. + pub align: BoxAlign, /// The text direction. pub dir: Dir, + /// The font size. + pub font_size: Length, /// The families used for font fallback. pub families: Rc<FallbackTree>, /// The font variant, pub variant: FontVariant, - /// How to align this text node in its parent. - pub aligns: Gen<Align>, } impl Layout for Text { @@ -30,12 +30,12 @@ impl Layout for Text { shaping::shape( &mut loader, &self.text, - self.font_size, self.dir, + self.font_size, &self.families, self.variant, ), - self.aligns, + self.align, ) } } |
