fix display height and width exception