Comment puis-je rendre le texte dans un TextView unclickable dans la mise en page XML?

J'ai différentes lignes de la table, chacune d'elle contient quelques informations de texte qui ne doit pas être cliquable et pas sélectionnable. Mais lorsque je l'exécute dans l'émulateur, le texte est toujours cliquable.

Cela signifie que, lorsque je clique sur n'importe quel bloc de texte, ses changements de couleur d'un gris foncé. Je ne veux pas qu'il change. Je le veux de ne rien faire.

Sûrement, je pourrais définir le gris foncé pour la couleur du texte de sorte que l'utilisateur ne voit pas qu'il clique sur quoi que ce soit, mais ce n'est pas ce que je veux.

J'ai déjà essayé différents attributs comme vous pouvez le voir dans l'exemple, mais rien ne l'aide. En outre, de quoi ai-je réellement pas cliquable, le TableRow ou le TextView à l'intérieur de la TableRow?

Voici un exemple:

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:layout_gravity="center_vertical|center_horizontal"
    >
    <ScrollView 
            android:id="@+id/scrollView"
            android:layout_width="fill_parent" 
            android:layout_height="wrap_content"
            android:layout_gravity="center_vertical|center_horizontal">
    <TableLayout 
            android:layout_height="wrap_content"
            android:layout_width="fill_parent"
            android:stretchColumns="*"
            android:clickable="false">
        <TableRow
            android:layout_width="fill_parent"
            android:background="#777777"
            android:clickable="false">
            <TextView 
                 android:id="@+id/heading"
                 android:text="This is the cool heading"             
                 android:textColor="#FFFFFF"
                 android:layout_width="fill_parent"
                 android:textSize="14sp"
                 android:paddingLeft="5sp"
                 android:paddingRight="5sp"
                 android:paddingTop="2sp"
                 android:paddingBottom="2sp"
                 android:textStyle="bold" 
                 android:clickable="false"  
                 />
        </TableRow>
         <TableRow
             android:clickable="false"
             android:linksClickable="false"
             android:focusable="false"
             android:focusableInTouchMode="false">
            <TextView
                 android:text="This is example text. It should not be clickable, but it is."
                 android:textSize="14sp"
                 android:paddingLeft="5sp"
                 android:paddingRight="5sp"
                 android:paddingTop="2sp"
                 android:paddingBottom="2sp"
                 android:scrollHorizontally="false"
                 android:inputType="textMultiLine"
                 android:linksClickable="false"
                 android:clickable="false"
                 android:focusable="false"
                 android:focusableInTouchMode="false"
                 android:layout_width="0sp"
                 />
               </TableRow>
              </TableLayout>
              </ScrollView>
              </RelativeLayout>
est l'ensemble de la tablerow est changé en gris foncé ou seulement le texte à l'intérieur du texte est modifié pour darkgrey?
Seul le texte devient gris.

OriginalL'auteur Bevor | 2011-11-27