RecycleView
ホルダーにセットwrap_content
:なぜwrap_contentは効果がありませんか?
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_height="match_parent"
android:background="@android:color/black">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/textView3"
android:textColor="@android:color/white"
android:textSize="17dp"
android:background="@drawable/bubbleblue170x140_2" />
</RelativeLayout>
しかしTextView
内のテキストが折り返されていない、バブル内の空きスペースの多くはTextViewの内側に、そこにあります。 background
として9-patch
画像を使用してアンドロイドで
:私はiOSのバージョンでは、このような何かを見るために強制することができますどのように
。
カフを外すと、9パッチPNGが高すぎます。 9パッチのPNGは拡張しますが、縮小しません。テキストの幅は 'match_parent'に設定されていますので、' wrap_content'の高さに余分な垂直空白があると思います。 – CommonsWare
TextView android:layout_width = "wrap_content" 9パッチを使用PNG – zombie
TextView *は9パッチよりも小さくすることはできません。それは*最小サイズ*です。 –