Good idea @artfwo - I’ll can see how a custom GridWrapper might be a bit nicer. Just trying to think of how to make this as maintainable as possible - always hate doing big cut and pastes of code.
BTW - I did notice one odd thing. I call grid.connect() on the physical grids after I’ve created them, but they don’t seem to pick up their width. I only noticed because in the VirtualGridWrapper I was intending to set the width by adding the two physical grid widths together. I was getting a type error because the width values were None. Maybe this is a timing thing? In any case I’ve worked around it by hard coding the dimensions. I’ll probably make a small config file so that the physical grid ids and things are not hard coded - like the original griddle config - so I can set the dimensions there.
Along the way, I noticed that in the Grid, the connect() method (on line 60) sets the state to CONNECTING, but in the GridWrapper, the connect() method checks (one line 172) to see if the underlying grid object has a state of CONNECTED. CONNECTED is not declared, so it should trigger an error - this is how I discovered the issue - but I guess in “normal” operation, that branch of the code never fires, so the undeclared state value is never checked. Not sure if that is an actual bug, but thought I’d let you know.
@FigrHed - I’d be happy to have a go at adding arc support, but I don’t have an arc handy… I’m sure there would be someone here in Melbourne that has one, but I’d be surprised if anyone who has one would want to let it out of their sight!