2013-12-20 30 views
-1

我想在佈局上製作47個按鈕,但我無法弄清楚如何在佈局上爲它們創建空間,並使佈局上下滑動。我知道,有很多主題關於這一點,但我嘗試了所有這些,我沒有幫助我..所以,請,如果有人可以解釋和編寫一個佈局全按鈕和滑動過程中所需的所有文件。請,非常感謝你,我會很抱歉。謝謝 !如何讓我的頁面上下滑動?

+0

你確定你想要那麼多按鈕嗎?它可能會違反許多UI/UX標準。 – rrirower

+0

你究竟試過了什麼? – gaurav5430

+0

使用滾動視圖。 – mayuri

回答

1

試試這會幫助你。

<ScrollView xmlns:android="http://schemas.android.com/apk/res/android" 
    xmlns:tools="http://schemas.android.com/tools" 
    android:layout_width="match_parent" 
    android:layout_height="match_parent" 
    > 
    <LinearLayout 
     android:layout_width="fill_parent" 
     android:layout_height="fill_parent" 
     android:orientation="vertical" 
     > 
     <Button 
      android:layout_width="wrap_content" 
      android:layout_height="wrap_content" 
      android:text="" 
      /> 
     . 
     . 
     . 
    </LinearLayout> 
</ScrollView> 
+0

Thx男人。它幫助! – user3104504

相關問題