#android #textview
#Android #просмотр текста
Вопрос:
У меня такой макет
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:ads="http://schemas.android.com/apk/res-auto"
android:id="@ id/RelativeLayout1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#fff" >
<TabHost
android:id="@ id/tabhost"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@ id/adView" >
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<TabWidget
android:id="@android:id/tabs"
android:layout_width="match_parent"
android:layout_height="wrap_content" >
</TabWidget>
<TextView
android:id="@ id/title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:text="@string/app_name"
android:textAppearance="?android:attr/textAppearanceLarge" />
<FrameLayout
android:id="@android:id/tabcontent"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="20dp" >
<LinearLayout
android:id="@ id/order_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<ImageView
android:id="@ id/logoImage"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:src="@drawable/logo" />
<TextView
android:id="@ id/order_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:autoLink="phone"
android:clickable="true"
android:gravity="center_horizontal"
android:text="@string/order"
android:textSize="18sp" />
</LinearLayout>
<LinearLayout
android:id="@ id/about_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<TextView
android:id="@ id/about_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center"
android:autoLink="all"
android:scrollbars="vertical"
android:text="@string/about" />
</LinearLayout>
<LinearLayout
android:id="@ id/tarrifs_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<TextView
android:id="@ id/tarrifs_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center"
android:autoLink="all"
android:scrollbars="vertical"
android:text="@string/tarrifs" />
</LinearLayout>
</FrameLayout>
</LinearLayout>
</TabHost>
<com.google.android.gms.ads.AdView
android:id="@ id/adView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_alignParentBottom="true"
ads:adSize="SMART_BANNER"
ads:adUnitId="@string/admob_id" >
</com.google.android.gms.ads.AdView>
</RelativeLayout>
в textview order_content я помещаю строку:
»
r n
11-22-33
8 999 333 11 22 r n
8 888 444 22 33 r n
»
два телефонных номера, кроме первого, окрашены (синий цвет и подчеркивание), но я не могу щелкнуть по ним и позвонить, может кто-нибудь мне помочь?
p.s. извините за мой английский
РЕШИТЕ — для строки комментариев: tv_order.setMovementMethod(новый метод прокрутки ());
Ответ №1:
Проблемная строка: tv_order.setMovementMethod(новый метод прокрутки ());