Cmdlet
New-ConsoleLayoutGrid
Lays console widgets out in an equal-width grid.
Syntax
New-ConsoleLayoutGrid
[-ColumnGap <Int32>]
[-Columns <Int32>]
[[-Content] <Object>]
[-MinColumnWidth <Int32>]
[-NoFillHeight]
[-RowGap <Int32>]
[<CommonParameters>]#Parameter set:
All Parameter SetsDescription
Children fill the grid row by row. When columns would become narrower than 24 cells the grid uses fewer columns.
Examples
Example 1
New-ConsoleLayoutGrid -Columns 3 -Content { New-ConsoleChart -WidgetId a -Type Sparkline; New-ConsoleChart -WidgetId b -Type Sparkline; New-ConsoleChart -WidgetId c -Type Sparkline }Three charts in a row
Parameters
- -ColumnGap Int32
- Blank columns between cells.
- -Columns Int32
- Number of columns (default 2).
- -Content Object
- Scriptblock that emits the cells.
- -MinColumnWidth Int32
- Minimum column width before reducing the column count.
- -NoFillHeight SwitchParameter
- Fits rows to content instead of the default-on height fill.
- -RowGap Int32
- Blank rows between grid rows.
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.