1 <?xml version="1.0" encoding="utf-8"?> 2 <!-- 3 Copyright (C) 2014 The Android Open Source Project 4 5 Licensed under the Apache License, Version 2.0 (the "License"); 6 you may not use this file except in compliance with the License. 7 You may obtain a copy of the License at 8 9 http://www.apache.org/licenses/LICENSE-2.0 10 11 Unless required by applicable law or agreed to in writing, software 12 distributed under the License is distributed on an "AS IS" BASIS, 13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 See the License for the specific language governing permissions and 15 limitations under the License. 16 --> 17 18 <resources> 19 <declare-styleable name="lbBaseGridView"> 20 <!-- Allow DPAD key to navigate out at the front of the View (where position = 0), 21 default is false --> 22 <attr name="focusOutFront" format="boolean" /> 23 <!-- Allow DPAD key to navigate out at the end of the view, default is false --> 24 <attr name="focusOutEnd" format="boolean" /> 25 <!-- Defining margin between two items horizontally --> 26 <attr name="horizontalMargin" format="dimension" /> 27 <!-- Defining margin between two items vertically --> 28 <attr name="verticalMargin" format="dimension" /> 29 <!-- Defining gravity of child view --> 30 <attr name="android:gravity" /> 31 </declare-styleable> 32 33 <declare-styleable name="lbHorizontalGridView"> 34 <!-- Defining height of each row of HorizontalGridView --> 35 <attr name="rowHeight" format="dimension" > 36 <enum name="wrap_content" value="-2" /> 37 </attr> 38 <!-- Defining number of rows --> 39 <attr name="numberOfRows" format="integer" /> 40 </declare-styleable> 41 42 <declare-styleable name="lbVerticalGridView"> 43 <!-- Defining width of each column of VerticalGridView --> 44 <attr name="columnWidth" format="dimension" > 45 <enum name="wrap_content" value="-2" /> 46 </attr> 47 <!-- Defining number of columns --> 48 <attr name="numberOfColumns" format="integer" /> 49 </declare-styleable> 50 51 <declare-styleable name="lbBaseCardView"> 52 <!-- Defines the type of the card layout --> 53 <attr name="cardType" format="enum"> 54 <!-- A simple card layout with a single layout region. --> 55 <enum name="mainOnly" value="0" /> 56 <!-- A card layout with two layout regions: a main area which is 57 always visible, and an info region that appears over the lower 58 area of the main region. --> 59 <enum name="infoOver" value="1" /> 60 <!-- A card layout with two layout regions: a main area which is 61 always visible, and an info region that appears below the main 62 region. --> 63 <enum name="infoUnder" value="2" /> 64 <!-- A card layout with three layout regions: a main area which is 65 always visible, an info region that appears below the main 66 region, and an extra region that appears below the info region 67 after a small delay. --> 68 <enum name="infoUnderWithExtra" value="3" /> 69 </attr> 70 <!-- Defines when the info region of a card layout is displayed. --> 71 <attr name="infoVisibility" format="enum"> 72 <!-- Always display the info region. --> 73 <enum name="always" value="0"/> 74 <!-- Display the info region only when activated. --> 75 <enum name="activated" value="1"/> 76 <!-- Display the info region only when selected. --> 77 <enum name="selected" value="2"/> 78 </attr> 79 <!-- Defines when the extra region of a card layout is displayed. 80 Depends on infoVisibility, meaning the extra region never displays 81 if the info region is not displayed as well. --> 82 <attr name="extraVisibility" format="enum"> 83 <!-- Always display the extra region. --> 84 <enum name="always" value="0"/> 85 <!-- Display the extra region only when activated. --> 86 <enum name="activated" value="1"/> 87 <!-- Display the extra region only when selected. --> 88 <enum name="selected" value="2"/> 89 </attr> 90 <!-- Defines the delay in milliseconds before the selection animation 91 runs for a card layout. --> 92 <attr name="selectedAnimationDelay" format="integer" /> 93 <!-- Defines the duration in milliseconds of the selection animation for 94 a card layout. --> 95 <attr name="selectedAnimationDuration" format="integer" /> 96 <!-- Defines the duration in milliseconds of the activated animation for 97 a card layout. --> 98 <attr name="activatedAnimationDuration" format="integer" /> 99 </declare-styleable> 100 101 <!-- This is the basic set of layout attributes for elements within a card 102 layout. These attributes are specified with the rest of an elements's 103 normal attributes. --> 104 <declare-styleable name="lbBaseCardView_Layout"> 105 <!-- The card layout region defined by this element. At most one of 106 element of each type should be specified as an immediate child of 107 the card layout. --> 108 <attr name="layout_viewType" format="enum"> 109 <!-- The main region of the card. --> 110 <enum name="main" value="0"/> 111 <!-- The info region of the card. --> 112 <enum name="info" value="1"/> 113 <!-- The extra region of the card. --> 114 <enum name="extra" value="2"/> 115 </attr> 116 </declare-styleable> 117 118 <declare-styleable name="lbImageCardView"> 119 <attr name="infoAreaBackground" format="reference|color"/> 120 </declare-styleable> 121 122 <declare-styleable name="lbSearchOrbView"> 123 <!-- Defining icon of the search affordance --> 124 <attr name="searchOrbIcon" format="reference"/> 125 <!-- Defining icon tint color of the search affordance --> 126 <attr name="searchOrbIconColor" format="reference|color"/> 127 <!-- Defining color of the search affordance --> 128 <attr name="searchOrbColor" format="reference|color" /> 129 <!-- Defining pulse color of the search affordance --> 130 <attr name="searchOrbBrightColor" format="reference|color" /> 131 </declare-styleable> 132 133 <declare-styleable name="lbPlaybackControlsActionIcons"> 134 <attr name="play" format="reference"/> 135 <attr name="pause" format="reference"/> 136 <attr name="fast_forward" format="reference"/> 137 <attr name="rewind" format="reference"/> 138 <attr name="skip_next" format="reference"/> 139 <attr name="skip_previous" format="reference"/> 140 <attr name="thumb_up_outline" format="reference"/> 141 <attr name="thumb_up" format="reference"/> 142 <attr name="thumb_down_outline" format="reference"/> 143 <attr name="thumb_down" format="reference"/> 144 <attr name="repeat" format="reference"/> 145 <attr name="repeat_one" format="reference"/> 146 <attr name="shuffle" format="reference"/> 147 <attr name="high_quality" format="reference"/> 148 <attr name="closed_captioning" format="reference"/> 149 </declare-styleable> 150 151 <declare-styleable name="LeanbackTheme"> 152 153 <!-- left padding of BrowseFragment, RowsFragment, DetailsFragment --> 154 <attr name="browsePaddingLeft" format="dimension" /> 155 <!-- right padding of BrowseFragment, RowsFragment, DetailsFragment --> 156 <attr name="browsePaddingRight" format="dimension" /> 157 <!-- top padding of BrowseFragment --> 158 <attr name="browsePaddingTop" format="dimension" /> 159 <!-- bottom padding of BrowseFragment --> 160 <attr name="browsePaddingBottom" format="dimension" /> 161 <!-- start margin of RowsFragment inside BrowseFragment when HeadersFragment is visible --> 162 <attr name="browseRowsMarginStart" format="dimension" /> 163 <!-- top margin of RowsFragment inside BrowseFragment when BrowseFragment title is visible --> 164 <attr name="browseRowsMarginTop" format="dimension" /> 165 <!-- fading edge length of start of browse row when HeadersFragment is visible --> 166 <attr name="browseRowsFadingEdgeLength" format="dimension" /> 167 168 <!-- BrowseFragment Title text style --> 169 <attr name="browseTitleTextStyle" format="reference" /> 170 171 <!-- BrowseFragment Title icon style --> 172 <attr name="browseTitleIconStyle" format="reference" /> 173 174 <!-- BrowseFragment TitleView style --> 175 <attr name="browseTitleViewStyle" format="reference" /> 176 177 <!-- vertical grid style inside HeadersFragment --> 178 <attr name="headersVerticalGridStyle" format="reference" /> 179 <!-- header style inside HeadersFragment --> 180 <attr name="headerStyle" format="reference" /> 181 182 <!-- vertical grid style inside RowsFragment --> 183 <attr name="rowsVerticalGridStyle" format="reference" /> 184 185 <!-- horizontal grid style inside a row --> 186 <attr name="rowHorizontalGridStyle" format="reference" /> 187 <!-- header style inside a row --> 188 <attr name="rowHeaderStyle" format="reference" /> 189 190 <!-- hover card title style --> 191 <attr name="rowHoverCardTitleStyle" format="reference" /> 192 <!-- hover card description style --> 193 <attr name="rowHoverCardDescriptionStyle" format="reference" /> 194 195 <!-- CardView styles --> 196 <attr name="baseCardViewStyle" format="reference" /> 197 <attr name="imageCardViewStyle" format="reference" /> 198 199 <!-- for details overviews --> 200 <attr name="detailsDescriptionTitleStyle" format="reference" /> 201 <attr name="detailsDescriptionSubtitleStyle" format="reference" /> 202 <attr name="detailsDescriptionBodyStyle" format="reference" /> 203 <attr name="detailsActionButtonStyle" format="reference" /> 204 205 <!-- for playback controls --> 206 <attr name="playbackControlsButtonStyle" format="reference" /> 207 <attr name="playbackControlsTimeStyle" format="reference" /> 208 209 <!-- style for a vertical grid of items --> 210 <attr name="itemsVerticalGridStyle" format="reference" /> 211 212 <!-- for messages in the error fragment --> 213 <attr name="errorMessageStyle" format="reference" /> 214 215 <!-- Default brand color used for the background of certain leanback visual elements 216 such as the headers fragment. If your app runs on: 217 a) SDK 21+: set colorPrimary, used by the leanback launcher and elsewhere, and defaultBrandColor will inherit it. 218 b) SDK < 21: set the brand color explicitly via defaultBrandColor, or programatically. 219 --> 220 <attr name="defaultBrandColor" format="reference|color" /> 221 222 <!-- Default colors --> 223 <attr name="defaultSearchColor" format="reference|color" /> 224 <!-- Default color that search orb pulses to. If not set, this color is determined programatically based on the defaultSearchColor --> 225 <attr name="defaultSearchBrightColor" format="reference|color" /> 226 227 <!-- Style for searchOrb --> 228 <attr name="searchOrbViewStyle" format="reference"/> 229 <attr name="defaultSearchIcon" format="reference" /> 230 231 <attr name="playbackProgressPrimaryColor" format="reference|color" /> 232 <attr name="playbackControlsIconHighlightColor" format="reference|color" /> 233 <attr name="playbackControlsActionIcons" format="reference" /> 234 235 <!-- Default color for dimmed views. --> 236 <attr name="overlayDimMaskColor" format="color" /> 237 <!-- Default level of dimming for active views. --> 238 <attr name="overlayDimActiveLevel" format="fraction" /> 239 <!-- Default level of dimming for dimmed views. --> 240 <attr name="overlayDimDimmedLevel" format="fraction" /> 241 242 </declare-styleable> 243 244 245 </resources> 246