UITextView的标题视图? [英] Header View for a UITextView?

查看:53
本文介绍了UITextView的标题视图?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在UITextView的顶部有一个自定义视图,该视图将随文本视图一起滚动,因此仅当文本视图滚动到最顶部时才可见.能做到吗?我当时在想,因为它是UIScrollView的子类,所以可能可以做些事情.

I want to have a custom view at the top of my UITextView that will scroll with the text view, so it is only visible when the text view is scrolled to the very top. Can this be done? I was thinking that because it is a subclass of UIScrollView there may be something that can be done.

谢谢!

推荐答案

您是否尝试过更改contentInset/contentOffset/contentSize属性,这些属性继承自

Have you tried changing the contentInset / contentOffset / contentSize properties, inherited from UIScrollView?

这篇关于UITextView的标题视图?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆