android 滚动固定,Android:固定大小ScrollView不滚动/滚动奇怪

我有一个固定大小scrollview,我试图使问题。我已经阅读了许多类似(但不等于)在StackOverflow和其他网站中的问题,但没有任何答案对我有所帮助,所以我决定问自己的问题。Android:固定大小ScrollView不滚动/滚动奇怪

基本上,我想要一个固定大小scrollview与不同的控制里面。基本的将是一个textview其中的动态变化的大小。当我更改textview的文本并且它大于scrollview时,滚动条会很快闪烁,表示我可以滚动,但无论我滑动手指多少次,它都不会滚动。然后,我尝试用两个或三个手指滑动,有时(仅计数)滚动。

我已经尝试了很多不同的方法,比如将textview更改为edittext,焦点= false,所以它不给用户编辑文本的机会;或者将textview单独放在scrollview中,或者将其包含在linearlayouts,相对布局等中,并且它仍然不滚动。

下面是代码,因为它是今天。这个滚动视图是在一个垂直线性布局和其他控件之间的,我不会把这个长度放在原因上,但如果有人需要它,我会把它放在里面。如果有人能指出我的问题或帮助我解决这个问题,我将非常感激。

XML:

android:id="@+id/scrollFifthHorizontalLineDetails"

android:layout_width="304dp"

android:layout_height="133dp"

android:layout_gravity="center"

android:layout_marginTop="5dp" >

android:id="@+id/rrrr"

android:layout_width="wrap_content"

android:layout_height="wrap_content"

android:orientation="vertical" >

android:id="@+id/txtlblPlaceDetails"

android:layout_width="302dp"

android:layout_height="wrap_content"

android:background="@drawable/placedescriptionbg"

android:text="@string/null_text"

android:textAppearance="?android:attr/textAppearanceSmall" />

android:id="@+id/button1"

android:layout_width="wrap_content"

android:layout_height="wrap_content"

android:text="Button" />

我在其中填充的TextView行:

((TextView) findViewById(R.id.txtlblPlaceDetails)).setText(mJsonOb.getString("placeDescription"));

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值