Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 1 | <?xml version="1.0" encoding="utf-8"?> |
| 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 | <com.android.launcher3.widget.WidgetCell |
| 17 | xmlns:android="http://schemas.android.com/apk/res/android" |
| 18 | xmlns:launcher="http://schemas.android.com/apk/res-auto" |
Hyunyoung Song | 4cea4c8 | 2015-04-17 19:02:30 -0700 | [diff] [blame] | 19 | android:layout_width="@dimen/widget_preview_container_width" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 20 | android:layout_height="wrap_content" |
| 21 | android:layout_weight="1" |
Hyunyoung Song | 475784a | 2015-04-22 13:59:20 -0700 | [diff] [blame] | 22 | android:layout_marginTop="@dimen/widget_preview_padding_top" |
| 23 | android:layout_marginLeft="8dp" |
| 24 | android:layout_marginBottom="8dp" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 25 | android:orientation="vertical" |
Hyunyoung Song | 475784a | 2015-04-22 13:59:20 -0700 | [diff] [blame] | 26 | android:background="@color/bubble_dark_background" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 27 | android:focusable="true"> |
| 28 | |
| 29 | <LinearLayout |
Hyunyoung Song | 4cea4c8 | 2015-04-17 19:02:30 -0700 | [diff] [blame] | 30 | android:layout_width="wrap_content" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 31 | android:layout_height="wrap_content" |
| 32 | android:paddingTop="@dimen/widget_preview_label_vertical_padding" |
| 33 | android:paddingBottom="@dimen/widget_preview_label_vertical_padding" |
| 34 | android:paddingLeft="@dimen/widget_preview_label_horizontal_padding" |
| 35 | android:paddingRight="@dimen/widget_preview_label_horizontal_padding" |
| 36 | android:orientation="horizontal"> |
| 37 | |
| 38 | <!-- The name of the widget. --> |
| 39 | <TextView |
| 40 | android:id="@+id/widget_name" |
| 41 | android:layout_width="wrap_content" |
| 42 | android:layout_height="wrap_content" |
| 43 | android:layout_weight="1" |
| 44 | android:gravity="start" |
| 45 | android:singleLine="true" |
Hyunyoung Song | a23dab9 | 2015-04-09 16:54:31 -0700 | [diff] [blame] | 46 | android:ellipsize="end" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 47 | android:fadingEdge="horizontal" |
| 48 | |
| 49 | android:textColor="#FFFFFFFF" |
Hyunyoung Song | b99ff3e | 2015-04-23 15:17:50 -0700 | [diff] [blame^] | 50 | android:textSize="16sp" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 51 | android:textAlignment="viewStart" |
| 52 | android:fontFamily="sans-serif-condensed" |
| 53 | android:shadowRadius="2.0" |
| 54 | android:shadowColor="#B0000000" /> |
| 55 | |
| 56 | <!-- The original dimensions of the widget (can't be the same text as above due to different |
| 57 | style. --> |
| 58 | <TextView |
| 59 | android:id="@+id/widget_dims" |
| 60 | android:layout_width="wrap_content" |
| 61 | android:layout_height="wrap_content" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 62 | android:layout_marginStart="5dp" |
| 63 | android:layout_marginLeft="5dp" |
| 64 | android:layout_weight="0" |
| 65 | android:gravity="start" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 66 | android:textColor="#FFFFFFFF" |
Hyunyoung Song | b99ff3e | 2015-04-23 15:17:50 -0700 | [diff] [blame^] | 67 | android:textSize="16sp" |
Hyunyoung Song | 4cea4c8 | 2015-04-17 19:02:30 -0700 | [diff] [blame] | 68 | android:textAlignment="viewStart" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 69 | android:fontFamily="sans-serif-condensed" |
| 70 | android:shadowRadius="2.0" |
| 71 | android:shadowColor="#B0000000" /> |
| 72 | </LinearLayout> |
| 73 | |
| 74 | <!-- The image of the widget. --> |
| 75 | <com.android.launcher3.widget.WidgetImageView |
| 76 | android:id="@+id/widget_preview" |
| 77 | style="@style/WidgetImageView" |
Hyunyoung Song | 4cea4c8 | 2015-04-17 19:02:30 -0700 | [diff] [blame] | 78 | android:layout_width="match_parent" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 79 | android:layout_height="wrap_content" |
| 80 | android:layout_weight="1" |
Hyunyoung Song | 3f47144 | 2015-04-08 19:01:34 -0700 | [diff] [blame] | 81 | android:scaleType="matrix" /> |
| 82 | |
| 83 | </com.android.launcher3.widget.WidgetCell> |