繁体   English   中英

android textview中是否有任何字符限制?

[英]Is there any character limit in android textview?

我想在Android TextView中输入超过2000 - 3000个字符

它没有显示任何东西。

任何一个指南都有android textview的字符限制或什么?

我在G3中做了一些小测试,我发现:如果在激活布局中有一个TextView,它可以显示超过4096个字符,但是当它由listview项拥有时,它只显示不可见。 所以没有硬限制,只能根据设备显示什么。

发布您的代码可能是您的textview展开并填写屏幕使用Scrollview来处理此问题。

<ScrollView
    android:layout_width="match_parent"
    android:layout_height="match_parent">
    <TextView
        android:id="@+id/textView"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:alpha="0.75"
        android:gravity="center_horizontal"
        android:textAppearance="@android:style/TextAppearance"
        android:textColor="@color/alert_dialog_heading_text_color"
        android:textSize="@dimen/text_size_for_subheading" />
</ScrollView>

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM