当前位置: 代码迷 >> Android >> 这布局如何实现的?哪位高手能帮小弟我看下的
  详细解决方案

这布局如何实现的?哪位高手能帮小弟我看下的

热度:55   发布时间:2016-04-27 22:31:15.0
这布局怎么实现的?谁能帮我看下的

第一眼看上去像是自定义radioButtton , 不过不确定 
------解决思路----------------------
<RadioGroup
            android:id="@+id/radioGroupTab"
            android:layout_width="fill_parent"
            android:layout_height="40dip"
            android:orientation="horizontal"
            android:weightSum="2" >

            <RadioButton
                android:id="@+id/radioType0"
                android:layout_width="fill_parent"
                android:layout_height="fill_parent"
                android:layout_weight="1"
                android:button="@null"
                android:checked="true"
                android:gravity="center"
                android:text="@string/orderType0"
                android:textColor="@drawable/selector_tabtextcolor"
                android:textSize="@dimen/textSize" />

            <TextView
                android:layout_width="1px"
                android:layout_height="fill_parent"
                android:layout_marginBottom="2dp"
                android:layout_marginTop="2dp"
                android:background="@color/listSepLineColor" />

            <RadioButton
                android:id="@+id/radioType1"
                android:layout_width="fill_parent"
                android:layout_height="fill_parent"
                android:layout_weight="1"
                android:button="@null"
                android:gravity="center"
                android:text="@string/orderType1"
                android:textColor="@drawable/selector_tabtextcolor"
                android:textSize="@dimen/textSize" />
        </RadioGroup>
------解决思路----------------------
用tab也可以,或者自己弄两个按钮上去,下面放个线性布局也行啊
------解决思路----------------------
radiobutton,或者textview都可以实现,不过之前有个人实现过这个效果。但是具体不记得在哪看过的了,实现的也是用textview
  相关解决方案