简体   繁体   中英

How to add blank UIImageView with certain bounds as a child of UIStackView?

Can anyone let me know add blank UIImageView with certain height inside the UIStackView?

I cannot add an empty UIImageViews by setting its bounds to the UIStackView. But if we add the UIImage as content for the UIImageView then all the pages are added to the UIStackView which is a child of UIScrollView.

This can be achieved by setting Intrinsic Placeholder size of the UIImageView.

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM