Improve resizing some more

It should be pretty alright now. There is a bug in that the scrollback
doesn't do line breaks, so it doesn't care about resizing the width all
that much, and there is also some text segments in the wrong position
sometimes.