Pictures are very small when added to UIimageview in Interface Builder

♀尐吖头ヾ 提交于 2019-12-13 06:09:22

问题


I have 6 images, all the same size (65x65). When I create an imageview and add this image through the "image view attributes" in the interface builder, the picture is very small. Maybe 5x5. The pictures also show up small when viewing them in the resource folder however, when running the program, they are the right size. Is there some setting I need to change to get the images to show the full size/full resolution within the interface builder?

Thanks.


回答1:


Make sure your UIImageView is active, then go to Layout -> Size to Fit (Command + '=' should also do the trick). This way the UIImageView will resize to fit the image and it'll look nice when looking at your stuff in IB.




回答2:


Adjust the resolution of your image files to 72 dpi.



来源:https://stackoverflow.com/questions/955849/pictures-are-very-small-when-added-to-uiimageview-in-interface-builder

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!