Skip to content

Commit b13afd2

Browse files
committed
shortcut constructor of TextFont
1 parent e19b91a commit b13afd2

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

examples/ecs/hierarchy.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,11 +74,7 @@ fn setup_common(
7474
delta.0 = time.elapsed();
7575
commands.spawn((
7676
Text::new(title),
77-
TextFont {
78-
font: Default::default(),
79-
font_size: 36.,
80-
..default()
81-
},
77+
TextFont::from_font_size(36.),
8278
DespawnOnExit(stage),
8379
));
8480
}

0 commit comments

Comments
 (0)