如何制作如图所示的 UItextView 或 TTTextView 动画
App Shopper工具 如图所示:
有一个表格项或按钮“阅读更多...” 当单击此按钮时,按钮会动画到该单词的末尾以显示所有单词。如图2
- 是UITextView吗?
- “按钮”是 UIButton 还是表项?
- 如何实现这个动画呢?
an App Shopper implement
As shown in picture:
there is a table item or a button "Read More..."
when click this button, the button animates to this piece of words' end to show all words up. As shown in picture 2
- Is it a UITextView?
- The "Button" is a UIButton or a Table Item?
- How to implement this animation?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我做了类似的事情,只需将
UILabel
和UITextView
垂直排列即可。对于按钮,我使用UIButtonTypeCustom
类型的透明UIButton
。然后我改变框架&动画块中标签/文本视图(带有文本的文本及其下方的文本)的文本。还有一种方法可以在表视图中执行此操作。有一个 Apple 示例代码项目,其中包含您可以单击以展开的部分标题。但该部分仍然可见,因此这可能不适合您。
I did something similar by simply having
UILabel
s andUITextView
s lined up vertically. For the button I use a transparentUIButton
of typeUIButtonTypeCustom
. Then I change the frame & text of the labels / textviews (the one with the text, and the ones below it) in an animation block.There is also a way to do this in a table view. There is an Apple sample code project with section headings that you can click to expand. But the section is still visible, so perhaps this is not the right approach for you.