Rename Rect field start->left end->right (#257)
1pub fn compute() {
2 let mut taffy = taffy::Taffy::new();
3 let node0 = taffy
4 .new_with_children(
5 taffy::style::Style {
6 size: taffy::geometry::Size {
7 width: taffy::style::Dimension::Points(100f32),
8 height: taffy::style::Dimension::Points(100f32),
9 ..Default::default()
10 },
11 max_size: taffy::geometry::Size {
12 width: taffy::style::Dimension::Points(100f32),
13 ..Default::default()
14 },
15 margin: taffy::geometry::Rect { left: taffy::style::Dimension::Points(20f32), ..Default::default() },
16 ..Default::default()
17 },
18 &[],
19 )
20 .unwrap();
21 let node = taffy
22 .new_with_children(
23 taffy::style::Style {
24 size: taffy::geometry::Size {
25 width: taffy::style::Dimension::Points(250f32),
26 height: taffy::style::Dimension::Points(250f32),
27 ..Default::default()
28 },
29 ..Default::default()
30 },
31 &[node0],
32 )
33 .unwrap();
34 taffy.compute_layout(node, taffy::geometry::Size::MAX_CONTENT).unwrap();
35}