rows property
int
get
rows
Returns the current terminal height in rows.
Falls back to defaultRows if:
- No terminal is attached
- An error occurs querying the terminal
Implementation
static int get rows {
try {
final output = TerminalContext.output;
if (output.hasTerminal) return output.terminalLines;
} catch (_) {}
return defaultRows;
}