Fix a bug when draw three-part resizable image vertically