2017-05-14 1 views
0

라디오 버튼에 옵션이 표시되는 것과 마찬가지로 확인란을 가로로 (세로로) 대신 표시 할 수 있습니까? 긍정적으로, 어떻게 이것을 할 수 있습니까?가로로 체크 박스 표시

감사합니다. 어떤 시점에서 그들이에 시작 했죠하지만 요셉은

+0

을 당신이 체크 박스의 당신이 레이아웃을 설정할 수있는 LinearLayout 안에 안드로이드 수평해야하는 경우 : 오리엔테이션 ="뭉개 버려 선형 레이아웃 propertys에서 "수평, 내부의 모든 요소를 선형 레이아웃이 수평으로 표시됩니다. –

+1

감사합니다. – JF0001

답변

0

예, 선형 레이아웃에서 그들을 감싸

는 ".. 당신이 행에 원하는만큼 다음과 같은 많은 추가, 각 하나 layout_weight 제공 "함께 당신은 그렇게 안 ..

<?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"> 


    <LinearLayout 
     android:layout_width="match_parent" 
     android:orientation="horizontal" 
     android:layout_height="wrap_content"> 

     <CheckBox 
      android:id="@+id/checkBox" 
      android:layout_weight="1" 
      android:layout_width="0dp" 
      android:layout_height="wrap_content" 
      android:text="CheckBox" /> 

     <CheckBox 
      android:id="@+id/checkBox2" 
      android:layout_weight="1" 
      android:layout_width="0dp" 
      android:layout_height="wrap_content" 
      android:text="CheckBox" /> 

     //Copy Paste More CheckBoxes... 

    </LinearLayout> 
</LinearLayout> 
+0

예를 들어 주셔서 감사합니다. – JF0001