Home | History | Annotate | Download | only in layout
      1 <?xml version="1.0" encoding="utf-8"?>
      2 <!-- Copyright (C) 2011 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 
     17 <!-- NOTE: this explicitly uses right/left padding, since the
     18      graph isn't swapped in RTL languages -->
     19 <com.android.settings.widget.ChartDataUsageView
     20     xmlns:android="http://schemas.android.com/apk/res/android"
     21     xmlns:settings="http://schemas.android.com/apk/res/com.android.settings"
     22     android:id="@+id/chart"
     23     android:layout_width="match_parent"
     24     android:layout_height="@dimen/data_usage_chart_height"
     25     android:paddingLeft="?android:attr/listPreferredItemPaddingStart"
     26     android:paddingRight="40dp"
     27     android:paddingTop="16dp"
     28     android:paddingBottom="24dp">
     29 
     30     <com.android.settings.widget.ChartGridView
     31         android:id="@+id/grid"
     32         android:layout_width="match_parent"
     33         android:layout_height="match_parent"
     34         android:layout_gravity="start|bottom"
     35         android:paddingBottom="24dp"
     36         android:textColor="?android:attr/textColorPrimary"
     37         android:textAppearance="@android:style/TextAppearance.Material.Caption"
     38         settings:borderDrawable="@drawable/data_grid_border" />
     39 
     40     <com.android.settings.widget.ChartNetworkSeriesView
     41         android:id="@+id/series"
     42         android:layout_width="match_parent"
     43         android:layout_height="match_parent"
     44         android:layout_gravity="start|bottom"
     45         settings:strokeColor="#00000000"
     46         settings:fillColor="#ff009688"
     47         settings:fillColorSecondary="#ff80cbc4"
     48         settings:safeRegion="3dp" />
     49 
     50     <com.android.settings.widget.ChartNetworkSeriesView
     51         android:id="@+id/detail_series"
     52         android:layout_width="match_parent"
     53         android:layout_height="match_parent"
     54         android:layout_gravity="start|bottom"
     55         settings:strokeColor="#00000000"
     56         settings:fillColor="#ff009688"
     57         settings:fillColorSecondary="#ff009688"
     58         settings:safeRegion="3dp" />
     59 
     60     <com.android.settings.widget.ChartSweepView
     61         android:id="@+id/sweep_warning"
     62         android:layout_width="match_parent"
     63         android:layout_height="wrap_content"
     64         android:nextFocusUp="@+id/sweep_limit"
     65         settings:sweepDrawable="@drawable/data_sweep_warning"
     66         settings:followAxis="vertical"
     67         settings:neighborMargin="5dip"
     68         settings:labelSize="60dip"
     69         settings:labelTemplate="@string/data_usage_sweep_warning"
     70         settings:labelColor="#ff37474f"
     71         settings:safeRegion="4dp" />
     72 
     73     <com.android.settings.widget.ChartSweepView
     74         android:id="@+id/sweep_limit"
     75         android:layout_width="match_parent"
     76         android:layout_height="wrap_content"
     77         android:nextFocusDown="@+id/sweep_warning"
     78         settings:sweepDrawable="@drawable/data_sweep_limit"
     79         settings:followAxis="vertical"
     80         settings:neighborMargin="5dip"
     81         settings:labelSize="60dip"
     82         settings:labelTemplate="@string/data_usage_sweep_limit"
     83         settings:labelColor="#fff4511e"
     84         settings:safeRegion="4dp" />
     85 
     86 </com.android.settings.widget.ChartDataUsageView>
     87