Fix bug when changing minSize while the scalebar is not displayed