>> An updated viewbox is for example
>> 423463.2 -5470604.7 133015.10000000003 113988.29999999981
> As I suspected the range is vastly different. Another possible
> workaround would be to set 'recenterOnResize' to false on the
> canvas (canvas.setRecenterOnResize(false)). I think this will
> solve the problem if my suspicions are correct.
It solves the problem yes, but it doesn't look pretty. I'll probably go
for the other workaround you suggested.