MCPcopy Create free account
hub / github.com/ChrisFeldmeier/OpenCodeRust / horizontal_split

Function horizontal_split

crates/opencode-tui/src/ui/layout.rs:3–9  ·  view source on GitHub ↗
(area: Rect, constraints: Vec<Constraint>)

Source from the content-addressed store, hash-verified

1use ratatui::layout::{Constraint, Direction, Layout, Rect};
2
3pub fn horizontal_split(area: Rect, constraints: Vec<Constraint>) -> Vec<Rect> {
4 Layout::default()
5 .direction(Direction::Horizontal)
6 .constraints(constraints)
7 .split(area)
8 .to_vec()
9}
10
11pub fn vertical_split(area: Rect, constraints: Vec<Constraint>) -> Vec<Rect> {
12 Layout::default()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected