Yigit Boyar | aba8d47 | 2015-03-03 18:12:33 -0800 | [diff] [blame] | 1 | <!-- |
| 2 | ~ Copyright (C) 2015 The Android Open Source Project |
| 3 | ~ |
| 4 | ~ Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | ~ you may not use this file except in compliance with the License. |
| 6 | ~ You may obtain a copy of the License at |
| 7 | ~ |
| 8 | ~ http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | ~ |
| 10 | ~ Unless required by applicable law or agreed to in writing, software |
| 11 | ~ distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | ~ See the License for the specific language governing permissions and |
| 14 | ~ limitations under the License. |
| 15 | --> |
| 16 | |
Aurimas Liutikas | ac5fe7c | 2018-03-06 14:40:53 -0800 | [diff] [blame] | 17 | <androidx.gridlayout.widget.GridLayout |
Yigit Boyar | aba8d47 | 2015-03-03 18:12:33 -0800 | [diff] [blame] | 18 | xmlns:android="http://schemas.android.com/apk/res/android" |
| 19 | xmlns:app="http://schemas.android.com/apk/res-auto" |
| 20 | android:id="@+id/gridView" |
| 21 | android:layout_width="match_parent" |
| 22 | android:layout_height="wrap_content" |
| 23 | android:layout_margin="10dp" |
| 24 | android:background="@android:color/white" |
| 25 | app:columnCount="2" |
| 26 | app:rowCount="1" |
| 27 | app:orientation="horizontal"> |
| 28 | |
| 29 | <TextView |
| 30 | android:id="@+id/leftView" |
| 31 | android:layout_width="0dp" |
| 32 | android:background="@color/red" |
| 33 | app:layout_columnWeight="2" |
| 34 | android:maxLines="3" |
| 35 | android:text="column 1, with weight of 2"/> |
| 36 | |
| 37 | <TextView |
| 38 | android:id="@+id/rightView" |
| 39 | android:layout_width="0dp" |
| 40 | app:layout_columnWeight="1" |
| 41 | android:minLines="3" |
| 42 | android:background="@color/blue" |
| 43 | android:text="column 2, with weight of 1"/> |
Aurimas Liutikas | ac5fe7c | 2018-03-06 14:40:53 -0800 | [diff] [blame] | 44 | </androidx.gridlayout.widget.GridLayout> |