2017-05-31 1 views

Répondre

0

je me suis dit une réponse à ma propre question. Voici le code:

<?xml version="1.0" encoding="utf-8"?> 
<LinearLayout 
    xmlns:android="http://schemas.android.com/apk/res/android" 
    android:orientation="vertical" android:layout_width="match_parent" 
    android:layout_height="match_parent"> 
    <HorizontalScrollView 
     android:layout_width="match_parent" 
     android:layout_height="wrap_content"> 
     <LinearLayout 
      android:layout_width="wrap_content" 
      android:layout_height="match_parent"> 
      <Button 
       android:layout_width="wrap_content" 
       android:layout_height="match_parent" 
       android:text="Button 1"/> 
      <Button 
       android:layout_width="wrap_content" 
       android:layout_height="match_parent" 
       android:text="Button 2"/> 
      <Button 
       android:layout_width="wrap_content" 
       android:layout_height="match_parent" 
       android:text="Button 3"/> 
      <Button 
       android:layout_width="wrap_content" 
       android:layout_height="match_parent" 
       android:text="Button 4"/> 
      <Button 
       android:layout_width="wrap_content" 
       android:layout_height="match_parent" 
       android:text="Button 5"/> 
      <Button 
       android:layout_width="wrap_content" 
       android:layout_height="match_parent" 
       android:text="Button 6"/> 

     </LinearLayout> 
    </HorizontalScrollView> 
</LinearLayout>