Renderer.create constructor
Opens guarded bindings and allocates a native renderer.
Set testing to true to use OpenTUI's non-terminal testing sink. This is
useful in harnesses that capture render state through direct buffer access
instead of terminal output.
Throws ArgumentError when width or height is non-positive.
Implementation
factory Renderer.create(int width, int height, {bool testing = false}) {
validateRendererDimensions(width, height);
final bindings = OpenTuiBindings();
final handle = bindings.createRenderer(width, height, testing: testing);
return Renderer._(bindings, handle, testing: testing);
}