more flexible resizing for the GL canvas