Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

里面的图片是GIF的支持动画吗 #15

Closed
simpleLiYu opened this issue Aug 25, 2020 · 18 comments
Closed

里面的图片是GIF的支持动画吗 #15

simpleLiYu opened this issue Aug 25, 2020 · 18 comments

Comments

@simpleLiYu
Copy link

No description provided.

@lixiang1994
Copy link
Owner

UITextView支持添加自定义视图 你可以加一个UIImageView

@simpleLiYu
Copy link
Author

我尝试用UITextView加一个UIImageView,但是我设置的size并没有用

@lixiang1994
Copy link
Owner

发一下你的代码我看看

@simpleLiYu
Copy link
Author

iShot2020-08-26下午02 01 08
iShot2020-08-26下午02 00 10
iShot2020-08-26下午01 59 55

@simpleLiYu
Copy link
Author

DiamondImageView是继承UIImageView的子类

@simpleLiYu
Copy link
Author

好像图片和文字放在同一行设置大小就有问题

@lixiang1994
Copy link
Owner

咦, 我这边测试好像没发现什么问题
image
image

@simpleLiYu
Copy link
Author

你这个不是宽高设置的40吗,图示是一个长方形的。初始化时设置的宽高没有生效吧

@lixiang1994
Copy link
Owner

我不是用的custom(size:)嘛, 会以custom(size:)为主, 你也可以不设置 不设置默认为原始大小 也就是view的frame

@simpleLiYu
Copy link
Author

你下面用的custom(size:)是吧,不好意思没细看。。。你尝试一下把字体设置大点,然后图片的高度比文字的高度小,就不正确了

@lixiang1994
Copy link
Owner

一共三种样式类型, proposed是建议的大小 相当于当前行高 和旁边文字一样大, original是原始大小 很好理解, custom是自定义大小

@simpleLiYu
Copy link
Author

当文字高度比图片高度高,这时候设置custom样式就没有效果了,那这样是不是就没办法设置文字大,后面跟的图片小些了

@lixiang1994
Copy link
Owner

咦 那可能是BUG 我看看啊

@simpleLiYu
Copy link
Author

image
就是这样的,文字字体设置的大之后设置图片的高度就无效了,会和文字一样高

@lixiang1994
Copy link
Owner

嗯嗯 我已经复现了, 这两天应该可以解决 有点小麻烦

@simpleLiYu
Copy link
Author

大佬辛苦,爱你哟❤️

@lixiang1994
Copy link
Owner

@simpleLiYu 1.6.7

@simpleLiYu
Copy link
Author

欧卡

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants