draw method
- Buffer buffer
override
Draws the widget on the buffer
.
Implementation
@override
void draw(Buffer buffer) {
// Split into two parts.
final footer = buffer.subGrid(
Rect.fromLTWH(
0,
buffer.height - height,
buffer.width,
height,
),
);
final rect = buffer.area().copyWith(height: buffer.height - height);
final main = buffer.subGrid(rect);
// Draw the main content.
this.main.draw(main);
// Draw the footer content.
this.footer.draw(footer);
}