fix image ratio problem