Improve/automatic width and height for subtitles

Can you add a couple of tests for this?