Skip to main content

join_h

Function join_h 

Source
pub fn join_h(grids: &[Grid]) -> Grid
Expand description

Concatenate grids left-to-right into one Grid (layer 0 only).

The result’s width is the sum of the input widths; its height is the tallest input. Each grid is placed top-aligned; cells below a shorter grid are left untouched (empty, per Grid::new’s default tiles). For an empty slice, returns a 1-wide, 0-tall grid: Grid::new panics on a width of zero (it divides by width internally), so a 1×0 grid is as close to “empty” as an actual Grid can represent.