Because of the move to hardware rendering in commit
afd6baa7cf1685610c72305f5c9f989078462dff, some relevant info
was lost that was previously used to limit bar height in
particular.
This patch re-adds a dimension check and additionally ensures
that the bar width doesn't exceed the tile size either.
Fixes#7171.