Block layout now playing #14

Open
opened 2023-06-10 09:56:15 +02:00 by chris · 0 comments
Owner
      let chunks = Layout::default()
        .direction(Direction::Horizontal)
        .constraints([Constraint::Percentage(50), Constraint::Percentage(50)])
        .split(outer_rect);
      let inner_rect1 = chunks[0].inner(&Margin {vertical: 1, horizontal: 1});
      let inner_rect2 = chunks[1].inner(&Margin {vertical: 1, horizontal: 1});
      f.render_widget(Block::default(), outer_rect);
      f.render_widget(Block::default(), inner_rect1);
      f.render_widget(Block::default(), inner_rect2);
```rust let chunks = Layout::default() .direction(Direction::Horizontal) .constraints([Constraint::Percentage(50), Constraint::Percentage(50)]) .split(outer_rect); let inner_rect1 = chunks[0].inner(&Margin {vertical: 1, horizontal: 1}); let inner_rect2 = chunks[1].inner(&Margin {vertical: 1, horizontal: 1}); f.render_widget(Block::default(), outer_rect); f.render_widget(Block::default(), inner_rect1); f.render_widget(Block::default(), inner_rect2); ```
chris added this to the crabidy v1 project 2023-06-12 22:24:08 +02:00
Sign in to join this conversation.
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: clusterfuck/crabidy#14
No description provided.