attrs.xml revision 62b4c5b5b0cb218a06037cea049d5d8ec4310832
1<?xml version="1.0" encoding="utf-8"?> 2<!-- Copyright (C) 2012 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<resources> 18 <!-- Many app-specific attributes are declared in this file. 19 Unless otherwise specified, they are intended to be set within 20 the context of a theme declaration. 21 22 Each cluster of attributes below states whether it is meant to 23 be set by the app and read by the system, or set by the system and 24 read by the app. --> 25 <eat-comment/> 26 27 28 <attr name="title" format="string"/> 29 <attr name="height" format="dimension"/> 30 <!-- Specifies whether the theme is light, otherwise it is dark. --> 31 <attr name="isLightTheme" format="boolean" /> 32 33 <!-- These are the standard attributes that make up a complete theme. --> 34 <declare-styleable name="Theme"> 35 36 <!-- ============= --> 37 <!-- Window styles --> 38 <!-- ============= --> 39 <eat-comment /> 40 41 <!-- Flag indicating whether this window should have an Action Bar 42 in place of the usual title bar. --> 43 <attr name="windowActionBar" format="boolean" /> 44 45 <!-- Flag indicating whether this window's Action Bar should overlay 46 application content. Does nothing if the window would not 47 have an Action Bar. --> 48 <attr name="windowActionBarOverlay" format="boolean" /> 49 50 <!-- Flag indicating whether action modes should overlay window content 51 when there is not reserved space for their UI (such as an Action Bar). --> 52 <attr name="windowActionModeOverlay" format="boolean" /> 53 54 <!-- A fixed width for the window along the major axis of the screen, 55 that is, when in landscape. Can be either an absolute dimension 56 or a fraction of the screen size in that dimension. --> 57 <attr name="windowFixedWidthMajor" format="dimension|fraction" /> 58 <!-- A fixed height for the window along the minor axis of the screen, 59 that is, when in landscape. Can be either an absolute dimension 60 or a fraction of the screen size in that dimension. --> 61 <attr name="windowFixedHeightMinor" format="dimension|fraction" /> 62 63 <!-- A fixed width for the window along the minor axis of the screen, 64 that is, when in portrait. Can be either an absolute dimension 65 or a fraction of the screen size in that dimension. --> 66 <attr name="windowFixedWidthMinor" format="dimension|fraction" /> 67 <!-- A fixed height for the window along the major axis of the screen, 68 that is, when in portrait. Can be either an absolute dimension 69 or a fraction of the screen size in that dimension. --> 70 <attr name="windowFixedHeightMajor" format="dimension|fraction" /> 71 72 <attr name="android:windowIsFloating" /> 73 74 <!-- =================== --> 75 <!-- Action bar styles --> 76 <!-- =================== --> 77 <eat-comment /> 78 <!-- Default style for tabs within an action bar --> 79 <attr name="actionBarTabStyle" format="reference" /> 80 <attr name="actionBarTabBarStyle" format="reference" /> 81 <attr name="actionBarTabTextStyle" format="reference" /> 82 <attr name="actionOverflowButtonStyle" format="reference" /> 83 <attr name="actionOverflowMenuStyle" format="reference" /> 84 <!-- Reference to a theme that should be used to inflate popups 85 shown by widgets in the action bar. --> 86 <attr name="actionBarPopupTheme" format="reference" /> 87 <!-- Reference to a style for the Action Bar --> 88 <attr name="actionBarStyle" format="reference" /> 89 <!-- Reference to a style for the split Action Bar. This style 90 controls the split component that holds the menu/action 91 buttons. actionBarStyle is still used for the primary 92 bar. --> 93 <attr name="actionBarSplitStyle" format="reference" /> 94 <!-- Reference to a theme that should be used to inflate the 95 action bar. This will be inherited by any widget inflated 96 into the action bar. --> 97 <attr name="actionBarTheme" format="reference" /> 98 <!-- Reference to a theme that should be used to inflate widgets 99 and layouts destined for the action bar. Most of the time 100 this will be a reference to the current theme, but when 101 the action bar has a significantly different contrast 102 profile than the rest of the activity the difference 103 can become important. If this is set to @null the current 104 theme will be used.--> 105 <attr name="actionBarWidgetTheme" format="reference" /> 106 <!-- Size of the Action Bar, including the contextual 107 bar used to present Action Modes. --> 108 <attr name="actionBarSize" format="dimension" > 109 <enum name="wrap_content" value="0" /> 110 </attr> 111 <!-- Custom divider drawable to use for elements in the action bar. --> 112 <attr name="actionBarDivider" format="reference" /> 113 <!-- Custom item state list drawable background for action bar items. --> 114 <attr name="actionBarItemBackground" format="reference" /> 115 <!-- TextAppearance style that will be applied to text that 116 appears within action menu items. --> 117 <attr name="actionMenuTextAppearance" format="reference" /> 118 <!-- Color for text that appears within action menu items. --> 119 <!-- Color for text that appears within action menu items. --> 120 <attr name="actionMenuTextColor" format="color|reference"/> 121 122 123 <!-- =================== --> 124 <!-- Action mode styles --> 125 <!-- =================== --> 126 <eat-comment/> 127 <attr name="actionModeStyle" format="reference"/> 128 <attr name="actionModeCloseButtonStyle" format="reference"/> 129 <!-- Background drawable to use for action mode UI --> 130 <attr name="actionModeBackground" format="reference"/> 131 <!-- Background drawable to use for action mode UI in the lower split bar --> 132 <attr name="actionModeSplitBackground" format="reference"/> 133 <!-- Drawable to use for the close action mode button --> 134 <attr name="actionModeCloseDrawable" format="reference"/> 135 <!-- Drawable to use for the Cut action button in Contextual Action Bar --> 136 <attr name="actionModeCutDrawable" format="reference"/> 137 <!-- Drawable to use for the Copy action button in Contextual Action Bar --> 138 <attr name="actionModeCopyDrawable" format="reference"/> 139 <!-- Drawable to use for the Paste action button in Contextual Action Bar --> 140 <attr name="actionModePasteDrawable" format="reference"/> 141 <!-- Drawable to use for the Select all action button in Contextual Action Bar --> 142 <attr name="actionModeSelectAllDrawable" format="reference"/> 143 <!-- Drawable to use for the Share action button in WebView selection action modes --> 144 <attr name="actionModeShareDrawable" format="reference"/> 145 <!-- Drawable to use for the Find action button in WebView selection action modes --> 146 <attr name="actionModeFindDrawable" format="reference"/> 147 <!-- Drawable to use for the Web Search action button in WebView selection action modes --> 148 <attr name="actionModeWebSearchDrawable" format="reference"/> 149 150 <!-- PopupWindow style to use for action modes when showing as a window overlay. --> 151 <attr name="actionModePopupWindowStyle" format="reference"/> 152 153 154 <!-- =================== --> 155 <!-- Text styles --> 156 <!-- =================== --> 157 <eat-comment /> 158 <!-- Text color, typeface, size, and style for the text inside of a popup menu. --> 159 <attr name="textAppearanceLargePopupMenu" format="reference"/> 160 <!-- Text color, typeface, size, and style for small text inside of a popup menu. --> 161 <attr name="textAppearanceSmallPopupMenu" format="reference"/> 162 163 164 <!-- =================== --> 165 <!-- Other widget styles --> 166 <!-- =================== --> 167 <eat-comment /> 168 169 <!-- Default ActionBar dropdown style. --> 170 <attr name="actionDropDownStyle" format="reference"/> 171 <!-- The preferred item height for dropdown lists. --> 172 <attr name="dropdownListPreferredItemHeight" format="dimension"/> 173 174 <!-- Default Spinner style. --> 175 <attr name="spinnerStyle" format="reference" /> 176 <!-- Default Spinner style. --> 177 <attr name="spinnerDropDownItemStyle" format="reference" /> 178 <!-- Specifies a drawable to use for the 'home as up' indicator. --> 179 <attr name="homeAsUpIndicator" format="reference"/> 180 181 <!-- Default action button style. --> 182 <attr name="actionButtonStyle" format="reference"/> 183 184 <!-- A style that may be applied to horizontal LinearLayouts 185 to form a button bar. --> 186 <attr name="buttonBarStyle" format="reference"/> 187 <!-- A style that may be applied to Buttons placed within a 188 LinearLayout with the style buttonBarStyle to form a button bar. --> 189 <attr name="buttonBarButtonStyle" format="reference"/> 190 <!-- A style that may be applied to buttons or other selectable items 191 that should react to pressed and focus states, but that do not 192 have a clear visual border along the edges. --> 193 <attr name="selectableItemBackground" format="reference"/> 194 <!-- Background drawable for borderless standalone items that need focus/pressed states. --> 195 <attr name="selectableItemBackgroundBorderless" format="reference" /> 196 <!-- A drawable that may be used as a vertical divider between visual elements. --> 197 <attr name="dividerVertical" format="reference"/> 198 <!-- A drawable that may be used as a horizontal divider between visual elements. --> 199 <attr name="dividerHorizontal" format="reference"/> 200 <!-- Default ActivityChooserView style. --> 201 <attr name="activityChooserViewStyle" format="reference" /> 202 203 <!-- Default Toolbar style. --> 204 <attr name="toolbarStyle" format="reference" /> 205 <!-- Default Toolar NavigationButtonStyle --> 206 <attr name="toolbarNavigationButtonStyle" format="reference" /> 207 208 <!-- Default PopupMenu style. --> 209 <attr name="popupMenuStyle" format="reference"/> 210 <!-- Default PopupWindow style. --> 211 <attr name="popupWindowStyle" format="reference" /> 212 213 <!-- EditText text foreground color. --> 214 <attr name="editTextColor" format="reference|color" /> 215 <!-- EditText background drawable. --> 216 <attr name="editTextBackground" format="reference" /> 217 218 <!-- Default style for the Switch widget. --> 219 <attr name="switchStyle" format="reference" /> 220 221 <!-- ============================ --> 222 <!-- SearchView styles and assets --> 223 <!-- ============================ --> 224 <eat-comment /> 225 <!-- Text color, typeface, size, and style for system search result title. Defaults to primary inverse text color. --> 226 <attr name="textAppearanceSearchResultTitle" format="reference" /> 227 <!-- Text color, typeface, size, and style for system search result subtitle. Defaults to primary inverse text color. --> 228 <attr name="textAppearanceSearchResultSubtitle" format="reference" /> 229 <!-- Text color for urls in search suggestions, used by things like global search --> 230 <attr name="textColorSearchUrl" format="reference|color" /> 231 <!-- Style for the search query widget. --> 232 <attr name="searchViewStyle" format="reference" /> 233 234 <!-- =========== --> 235 <!-- List styles --> 236 <!-- =========== --> 237 <eat-comment /> 238 239 <!-- The preferred list item height. --> 240 <attr name="listPreferredItemHeight" format="dimension"/> 241 <!-- A smaller, sleeker list item height. --> 242 <attr name="listPreferredItemHeightSmall" format="dimension"/> 243 <!-- A larger, more robust list item height. --> 244 <attr name="listPreferredItemHeightLarge" format="dimension"/> 245 246 <!-- The preferred padding along the left edge of list items. --> 247 <attr name="listPreferredItemPaddingLeft" format="dimension"/> 248 <!-- The preferred padding along the right edge of list items. --> 249 <attr name="listPreferredItemPaddingRight" format="dimension"/> 250 251 <!-- ListPopupWindow compatibility --> 252 <attr name="dropDownListViewStyle" format="reference"/> 253 <attr name="listPopupWindowStyle" format="reference"/> 254 255 <!-- The preferred TextAppearance for the primary text of list items. --> 256 <attr name="textAppearanceListItem" format="reference"/> 257 <!-- The preferred TextAppearance for the primary text of small list items. --> 258 <attr name="textAppearanceListItemSmall" format="reference"/> 259 260 261 <!-- ============ --> 262 <!-- Panel styles --> 263 <!-- ============ --> 264 <eat-comment /> 265 266 <!-- The background of a panel when it is inset from the left and right edges of the screen. --> 267 <attr name="panelBackground" format="reference" /> 268 <!-- Default Panel Menu width. --> 269 <attr name="panelMenuListWidth" format="dimension" /> 270 <!-- Default Panel Menu style. --> 271 <attr name="panelMenuListTheme" format="reference" /> 272 <!-- Drawable used as a background for selected list items. --> 273 <attr name="listChoiceBackgroundIndicator" format="reference" /> 274 275 <!-- ============= --> 276 <!-- Color palette --> 277 <!-- ============= --> 278 <eat-comment /> 279 280 <!-- The primary branding color for the app. By default, this is the color applied to the 281 action bar background. --> 282 <attr name="colorPrimary" format="color" /> 283 284 <!-- Dark variant of the primary branding color. By default, this is the color applied to 285 the status bar (via statusBarColor) and navigation bar (via navigationBarColor). --> 286 <attr name="colorPrimaryDark" format="color" /> 287 288 <!-- Bright complement to the primary branding color. By default, this is the color applied 289 to framework controls (via colorControlActivated). --> 290 <attr name="colorAccent" format="color" /> 291 292 <!-- The color applied to framework controls in their normal state. --> 293 <attr name="colorControlNormal" format="color" /> 294 295 <!-- The color applied to framework controls in their activated (ex. checked) state. --> 296 <attr name="colorControlActivated" format="color" /> 297 298 <!-- The color applied to framework control highlights (ex. ripples, list selectors). --> 299 <attr name="colorControlHighlight" format="color" /> 300 301 <!-- The color applied to framework buttons in their normal state. --> 302 <attr name="colorButtonNormal" format="color" /> 303 304 <!-- The color applied to framework switch thumbs in their normal state. --> 305 <attr name="colorSwitchThumbNormal" format="color" /> 306 307 <!-- Whether appcompat should use its styled widgets on pre-Lollipop devices. 308 If this is disabled then widgets will be styled using the platform-default style 309 for the device. This flag has no effect on Android 5.0 or newer. --> 310 <attr name="compatibleWidgetStylingEnabled" format="boolean" /> 311 312 </declare-styleable> 313 314 315 <!-- ============================================ --> 316 317 <!-- Attributes used to style the Action Bar. 318 These should be set on your theme; the default actionBarStyle will 319 propagate them to the correct elements as needed. 320 321 Please Note: when overriding attributes for an ActionBar style 322 you must specify each attribute twice: once with the "android:" 323 namespace prefix and once without. --> 324 <declare-styleable name="ActionBar"> 325 <!-- The type of navigation to use. --> 326 <attr name="navigationMode"> 327 <!-- Normal static title text --> 328 <enum name="normal" value="0"/> 329 <!-- The action bar will use a selection list for navigation. --> 330 <enum name="listMode" value="1"/> 331 <!-- The action bar will use a series of horizontal tabs for navigation. --> 332 <enum name="tabMode" value="2"/> 333 </attr> 334 <!-- Options affecting how the action bar is displayed. --> 335 <attr name="displayOptions"> 336 <flag name="none" value="0" /> 337 <flag name="useLogo" value="0x1"/> 338 <flag name="showHome" value="0x2"/> 339 <flag name="homeAsUp" value="0x4"/> 340 <flag name="showTitle" value="0x8"/> 341 <flag name="showCustom" value="0x10"/> 342 <flag name="disableHome" value="0x20"/> 343 </attr> 344 <!-- Specifies title text used for navigationMode="normal" --> 345 <attr name="title"/> 346 <!-- Specifies subtitle text used for navigationMode="normal" --> 347 <attr name="subtitle" format="string"/> 348 <!-- Specifies a style to use for title text. --> 349 <attr name="titleTextStyle" format="reference"/> 350 <!-- Specifies a style to use for subtitle text. --> 351 <attr name="subtitleTextStyle" format="reference"/> 352 <!-- Specifies the drawable used for the application icon. --> 353 <attr name="icon" format="reference"/> 354 <!-- Specifies the drawable used for the application logo. --> 355 <attr name="logo" format="reference"/> 356 <!-- Specifies the drawable used for item dividers. --> 357 <attr name="divider" format="reference"/> 358 <!-- Specifies a background drawable for the action bar. --> 359 <attr name="background" format="reference"/> 360 <!-- Specifies a background drawable for a second stacked row of the action bar. --> 361 <attr name="backgroundStacked" format="reference|color"/> 362 <!-- Specifies a background drawable for the bottom component of a split action bar. --> 363 <attr name="backgroundSplit" format="reference|color"/> 364 <!-- Specifies a layout for custom navigation. Overrides navigationMode. --> 365 <attr name="customNavigationLayout" format="reference"/> 366 <!-- Specifies a fixed height. --> 367 <attr name="height"/> 368 <!-- Specifies a layout to use for the "home" section of the action bar. --> 369 <attr name="homeLayout" format="reference"/> 370 <!-- Specifies a style resource to use for an embedded progress bar. --> 371 <attr name="progressBarStyle" format="reference"/> 372 <!-- Specifies a style resource to use for an indeterminate progress spinner. --> 373 <attr name="indeterminateProgressStyle" format="reference"/> 374 <!-- Specifies the horizontal padding on either end for an embedded progress bar. --> 375 <attr name="progressBarPadding" format="dimension"/> 376 <!-- Up navigation glyph --> 377 <attr name="homeAsUpIndicator" /> 378 <!-- Specifies padding that should be applied to the left and right sides of 379 system-provided items in the bar. --> 380 <attr name="itemPadding" format="dimension"/> 381 <!-- Set true to hide the action bar on a vertical nested scroll of content. --> 382 <attr name="hideOnContentScroll" format="boolean"/> 383 <!-- Minimum inset for content views within a bar. Navigation buttons and 384 menu views are excepted. Only valid for some themes and configurations. --> 385 <attr name="contentInsetStart" format="dimension"/> 386 <!-- Minimum inset for content views within a bar. Navigation buttons and 387 menu views are excepted. Only valid for some themes and configurations. --> 388 <attr name="contentInsetEnd" format="dimension"/> 389 <!-- Minimum inset for content views within a bar. Navigation buttons and 390 menu views are excepted. Only valid for some themes and configurations. --> 391 <attr name="contentInsetLeft" format="dimension"/> 392 <!-- Minimum inset for content views within a bar. Navigation buttons and 393 menu views are excepted. Only valid for some themes and configurations. --> 394 <attr name="contentInsetRight" format="dimension"/> 395 <!-- Elevation for the action bar itself --> 396 <attr name="elevation" format="dimension" /> 397 <!-- Reference to a theme that should be used to inflate popups 398 shown by widgets in the action bar. --> 399 <attr name="popupTheme" format="reference" /> 400 </declare-styleable> 401 402 <!-- Valid LayoutParams for views placed in the action bar as custom views. --> 403 <declare-styleable name="ActionBarLayout"> 404 <attr name="android:layout_gravity"/> 405 </declare-styleable> 406 407 <declare-styleable name="ActionMenuItemView"> 408 <attr name="android:minWidth"/> 409 </declare-styleable> 410 411 <declare-styleable name="ActionMode"> 412 <!-- Specifies a style to use for title text. --> 413 <attr name="titleTextStyle"/> 414 <!-- Specifies a style to use for subtitle text. --> 415 <attr name="subtitleTextStyle"/> 416 <!-- Specifies a background for the action mode bar. --> 417 <attr name="background"/> 418 <!-- Specifies a background for the split action mode bar. --> 419 <attr name="backgroundSplit"/> 420 <!-- Specifies a fixed height for the action mode bar. --> 421 <attr name="height"/> 422 <!-- Specifies a layout to use for the "close" item at the starting edge. --> 423 <attr name="closeItemLayout" format="reference" /> 424 </declare-styleable> 425 426 <declare-styleable name="View"> 427 <!-- Sets the padding, in pixels, of the start edge; see {@link android.R.attr#padding}. --> 428 <attr name="paddingStart" format="dimension"/> 429 <!-- Sets the padding, in pixels, of the end edge; see {@link android.R.attr#padding}. --> 430 <attr name="paddingEnd" format="dimension"/> 431 432 <!-- Boolean that controls whether a view can take focus. By default the user can not 433 move focus to a view; by setting this attribute to true the view is 434 allowed to take focus. This value does not impact the behavior of 435 directly calling {@link android.view.View#requestFocus}, which will 436 always request focus regardless of this view. It only impacts where 437 focus navigation will try to move focus. --> 438 <attr name="android:focusable" /> 439 </declare-styleable> 440 441 <declare-styleable name="MenuView"> 442 <!-- Default appearance of menu item text. --> 443 <attr name="android:itemTextAppearance"/> 444 <!-- Default horizontal divider between rows of menu items. --> 445 <attr name="android:horizontalDivider"/> 446 <!-- Default vertical divider between menu items. --> 447 <attr name="android:verticalDivider"/> 448 <!-- Default background for the menu header. --> 449 <attr name="android:headerBackground"/> 450 <!-- Default background for each menu item. --> 451 <attr name="android:itemBackground"/> 452 <!-- Default animations for the menu. --> 453 <attr name="android:windowAnimationStyle"/> 454 <!-- Default disabled icon alpha for each menu item that shows an icon. --> 455 <attr name="android:itemIconDisabledAlpha"/> 456 <!-- Whether space should be reserved in layout when an icon is missing. --> 457 <attr name="preserveIconSpacing" format="boolean" /> 458 </declare-styleable> 459 <declare-styleable name="ActionMenuView"> 460 <!-- Size of padding on either end of a divider. --> 461 </declare-styleable> 462 463 <!-- Base attributes that are available to all groups. --> 464 <declare-styleable name="MenuGroup"> 465 466 <!-- The ID of the group. --> 467 <attr name="android:id" /> 468 469 <!-- The category applied to all items within this group. 470 (This will be or'ed with the orderInCategory attribute.) --> 471 <attr name="android:menuCategory" /> 472 473 <!-- The order within the category applied to all items within this group. 474 (This will be or'ed with the category attribute.) --> 475 <attr name="android:orderInCategory" /> 476 477 <!-- Whether the items are capable of displaying a check mark. --> 478 <attr name="android:checkableBehavior" /> 479 480 <!-- Whether the items are shown/visible. --> 481 <attr name="android:visible" /> 482 483 <!-- Whether the items are enabled. --> 484 <attr name="android:enabled" /> 485 486 </declare-styleable> 487 488 <!-- Base attributes that are available to all Item objects. --> 489 <declare-styleable name="MenuItem"> 490 491 <!-- The ID of the item. --> 492 <attr name="android:id" /> 493 494 <!-- The category applied to the item. 495 (This will be or'ed with the orderInCategory attribute.) --> 496 <attr name="android:menuCategory" /> 497 498 <!-- The order within the category applied to the item. 499 (This will be or'ed with the category attribute.) --> 500 <attr name="android:orderInCategory" /> 501 502 <!-- The title associated with the item. --> 503 <attr name="android:title" /> 504 505 <!-- The condensed title associated with the item. This is used in situations where the 506 normal title may be too long to be displayed. --> 507 <attr name="android:titleCondensed" /> 508 509 <!-- The icon associated with this item. This icon will not always be shown, so 510 the title should be sufficient in describing this item. --> 511 <attr name="android:icon" /> 512 513 <!-- The alphabetic shortcut key. This is the shortcut when using a keyboard 514 with alphabetic keys. --> 515 <attr name="android:alphabeticShortcut" /> 516 517 <!-- The numeric shortcut key. This is the shortcut when using a numeric (e.g., 12-key) 518 keyboard. --> 519 <attr name="android:numericShortcut" /> 520 521 <!-- Whether the item is capable of displaying a check mark. --> 522 <attr name="android:checkable" /> 523 524 <!-- Whether the item is checked. Note that you must first have enabled checking with 525 the checkable attribute or else the check mark will not appear. --> 526 <attr name="android:checked" /> 527 528 <!-- Whether the item is shown/visible. --> 529 <attr name="android:visible" /> 530 531 <!-- Whether the item is enabled. --> 532 <attr name="android:enabled" /> 533 534 <!-- Name of a method on the Context used to inflate the menu that will be 535 called when the item is clicked. --> 536 <attr name="android:onClick" /> 537 538 <!-- How this item should display in the Action Bar, if present. --> 539 <attr name="showAsAction"> 540 <!-- Never show this item in an action bar, show it in the overflow menu instead. 541 Mutually exclusive with "ifRoom" and "always". --> 542 <flag name="never" value="0" /> 543 <!-- Show this item in an action bar if there is room for it as determined 544 by the system. Favor this option over "always" where possible. 545 Mutually exclusive with "never" and "always". --> 546 <flag name="ifRoom" value="1" /> 547 <!-- Always show this item in an actionbar, even if it would override 548 the system's limits of how much stuff to put there. This may make 549 your action bar look bad on some screens. In most cases you should 550 use "ifRoom" instead. Mutually exclusive with "ifRoom" and "never". --> 551 <flag name="always" value="2" /> 552 <!-- When this item is shown as an action in the action bar, show a text 553 label with it even if it has an icon representation. --> 554 <flag name="withText" value="4" /> 555 <!-- This item's action view collapses to a normal menu 556 item. When expanded, the action view takes over a 557 larger segment of its container. --> 558 <flag name="collapseActionView" value="8" /> 559 </attr> 560 561 <!-- An optional layout to be used as an action view. 562 See {@link android.view.MenuItem#setActionView(android.view.View)} 563 for more info. --> 564 <attr name="actionLayout" format="reference" /> 565 566 <!-- The name of an optional View class to instantiate and use as an 567 action view. See {@link android.view.MenuItem#setActionView(android.view.View)} 568 for more info. --> 569 <attr name="actionViewClass" format="string" /> 570 571 <!-- The name of an optional ActionProvider class to instantiate an action view 572 and perform operations such as default action for that menu item. 573 See {@link android.view.MenuItem#setActionProvider(android.view.ActionProvider)} 574 for more info. --> 575 <attr name="actionProviderClass" format="string" /> 576 577 </declare-styleable> 578 579 <declare-styleable name="Spinner"> 580 <!-- The prompt to display when the spinner's dialog is shown. --> 581 <attr name="prompt" format="reference" /> 582 <!-- Display mode for spinner options. --> 583 <attr name="spinnerMode" format="enum"> 584 <!-- Spinner options will be presented to the user as a dialog window. --> 585 <enum name="dialog" value="0" /> 586 <!-- Spinner options will be presented to the user as an inline dropdown 587 anchored to the spinner widget itself. --> 588 <enum name="dropdown" value="1" /> 589 </attr> 590 <!-- List selector to use for spinnerMode="dropdown" display. --> 591 <attr name="android:dropDownSelector" /> 592 <!-- Background drawable to use for the dropdown in spinnerMode="dropdown". --> 593 <attr name="android:popupBackground" /> 594 <!-- Vertical offset from the spinner widget for positioning the dropdown in 595 spinnerMode="dropdown". --> 596 <attr name="android:dropDownVerticalOffset" /> 597 <!-- Horizontal offset from the spinner widget for positioning the dropdown 598 in spinnerMode="dropdown". --> 599 <attr name="android:dropDownHorizontalOffset" /> 600 <!-- Width of the dropdown in spinnerMode="dropdown". --> 601 <attr name="android:dropDownWidth" /> 602 <!-- Reference to a layout to use for displaying a prompt in the dropdown for 603 spinnerMode="dropdown". This layout must contain a TextView with the id 604 {@code @android:id/text1} to be populated with the prompt text. --> 605 <attr name="popupPromptView" format="reference" /> 606 <!-- Gravity setting for positioning the currently selected item. --> 607 <attr name="android:gravity" /> 608 <!-- Whether this spinner should mark child views as enabled/disabled when 609 the spinner itself is enabled/disabled. --> 610 <attr name="disableChildrenWhenDisabled" format="boolean" /> 611 <attr name="android:background" /> 612 </declare-styleable> 613 614 <declare-styleable name="SearchView"> 615 <!-- The layout to use for the search view. --> 616 <attr name="layout" format="reference" /> 617 <!-- The default state of the SearchView. If true, it will be iconified when not in 618 use and expanded when clicked. --> 619 <attr name="iconifiedByDefault" format="boolean" /> 620 <!-- An optional maximum width of the SearchView. --> 621 <attr name="android:maxWidth" /> 622 <!-- An optional query hint string to be displayed in the empty query field. --> 623 <attr name="queryHint" format="string" /> 624 <!-- The IME options to set on the query text field. --> 625 <attr name="android:imeOptions" /> 626 <!-- The input type to set on the query text field. --> 627 <attr name="android:inputType" /> 628 <!-- Close button icon --> 629 <attr name="closeIcon" format="reference" /> 630 <!-- Go button icon --> 631 <attr name="goIcon" format="reference" /> 632 <!-- Search icon --> 633 <attr name="searchIcon" format="reference" /> 634 <!-- Voice button icon --> 635 <attr name="voiceIcon" format="reference" /> 636 <!-- Commit icon shown in the query suggestion row --> 637 <attr name="commitIcon" format="reference" /> 638 <!-- Layout for query suggestion rows --> 639 <attr name="suggestionRowLayout" format="reference" /> 640 <!-- Background for the section containing the search query --> 641 <attr name="queryBackground" format="reference" /> 642 <!-- Background for the section containing the action (e.g. voice search) --> 643 <attr name="submitBackground" format="reference" /> 644 <attr name="android:focusable" /> 645 </declare-styleable> 646 647 <!-- Attrbitutes for a ActivityChooserView. --> 648 <declare-styleable name="ActivityChooserView"> 649 <!-- The maximal number of items initially shown in the activity list. --> 650 <attr name="initialActivityCount" format="string" /> 651 <!-- The drawable to show in the button for expanding the activities overflow popup. 652 <strong>Note:</strong> Clients would like to set this drawable 653 as a clue about the action the chosen activity will perform. For 654 example, if share activity is to be chosen the drawable should 655 give a clue that sharing is to be performed. 656 --> 657 <attr name="expandActivityOverflowButtonDrawable" format="reference" /> 658 </declare-styleable> 659 660 <declare-styleable name="CompatTextView"> 661 <!-- Present the text in ALL CAPS. This may use a small-caps form when available. --> 662 <attr name="textAllCaps" format="reference|boolean" /> 663 </declare-styleable> 664 665 <declare-styleable name="LinearLayoutCompat"> 666 <!-- Should the layout be a column or a row? Use "horizontal" 667 for a row, "vertical" for a column. The default is 668 horizontal. --> 669 <attr name="android:orientation" /> 670 <attr name="android:gravity" /> 671 <!-- When set to false, prevents the layout from aligning its children's 672 baselines. This attribute is particularly useful when the children 673 use different values for gravity. The default value is true. --> 674 <attr name="android:baselineAligned" /> 675 <!-- When a linear layout is part of another layout that is baseline 676 aligned, it can specify which of its children to baseline align to 677 (that is, which child TextView).--> 678 <attr name="android:baselineAlignedChildIndex" /> 679 <!-- Defines the maximum weight sum. If unspecified, the sum is computed 680 by adding the layout_weight of all of the children. This can be 681 used for instance to give a single child 50% of the total available 682 space by giving it a layout_weight of 0.5 and setting the weightSum 683 to 1.0. --> 684 <attr name="android:weightSum" /> 685 <!-- When set to true, all children with a weight will be considered having 686 the minimum size of the largest child. If false, all children are 687 measured normally. --> 688 <attr name="measureWithLargestChild" format="boolean" /> 689 <!-- Drawable to use as a vertical divider between buttons. --> 690 <attr name="divider" /> 691 <!-- Setting for which dividers to show. --> 692 <attr name="showDividers"> 693 <flag name="none" value="0" /> 694 <flag name="beginning" value="1" /> 695 <flag name="middle" value="2" /> 696 <flag name="end" value="4" /> 697 </attr> 698 <!-- Size of padding on either end of a divider. --> 699 <attr name="dividerPadding" format="dimension" /> 700 </declare-styleable> 701 702 <declare-styleable name="LinearLayoutCompat_Layout"> 703 <attr name="android:layout_width" /> 704 <attr name="android:layout_height" /> 705 <attr name="android:layout_weight" /> 706 <attr name="android:layout_gravity" /> 707 </declare-styleable> 708 709 <declare-styleable name="Toolbar"> 710 <attr name="titleTextAppearance" format="reference" /> 711 <attr name="subtitleTextAppearance" format="reference" /> 712 <attr name="title" /> 713 <attr name="subtitle" /> 714 <attr name="android:gravity" /> 715 <attr name="titleMargins" format="dimension" /> 716 <attr name="titleMarginStart" format="dimension" /> 717 <attr name="titleMarginEnd" format="dimension" /> 718 <attr name="titleMarginTop" format="dimension" /> 719 <attr name="titleMarginBottom" format="dimension" /> 720 <attr name="contentInsetStart" /> 721 <attr name="contentInsetEnd" /> 722 <attr name="contentInsetLeft" /> 723 <attr name="contentInsetRight" /> 724 <attr name="maxButtonHeight" format="dimension" /> 725 726 <!-- Specifies a theme override for a view. When a theme override is set, the 727 view will be inflated using a {@link android.content.Context} themed with 728 the specified resource. During XML inflation, any child views under the 729 view with a theme override will inherit the themed context. --> 730 <attr name="theme" format="reference" /> 731 732 <attr name="collapseIcon" format="reference" /> 733 <!-- Reference to a theme that should be used to inflate popups 734 shown by widgets in the toolbar. --> 735 <attr name="popupTheme" /> 736 <!-- Icon drawable to use for the navigation button located at 737 the start of the toolbar. --> 738 <attr name="navigationIcon" format="reference" /> 739 <!-- Text to set as the content description for the navigation button 740 located at the start of the toolbar. --> 741 <attr name="navigationContentDescription" format="string" /> 742 743 <!-- Allows us to read in the minHeight attr pre-v16 --> 744 <attr name="android:minHeight" /> 745 </declare-styleable> 746 747 <declare-styleable name="PopupWindowBackgroundState"> 748 <!-- State identifier indicating the popup will be above the anchor. --> 749 <attr name="state_above_anchor" format="boolean" /> 750 </declare-styleable> 751 752 <declare-styleable name="ListPopupWindow"> 753 <!-- Amount of pixels by which the drop down should be offset vertically. --> 754 <attr name="android:dropDownVerticalOffset" /> 755 <!-- Amount of pixels by which the drop down should be offset horizontally. --> 756 <attr name="android:dropDownHorizontalOffset" /> 757 </declare-styleable> 758 759 <declare-styleable name="PopupWindow"> 760 <!-- Whether the popup window should overlap its anchor view. --> 761 <attr name="overlapAnchor" format="boolean" /> 762 <attr name="android:popupBackground" /> 763 </declare-styleable> 764 765 <declare-styleable name="DrawerArrowToggle"> 766 <!-- The drawing color for the bars --> 767 <attr name="color" format="color"/> 768 <!-- Whether bars should rotate or not during transition --> 769 <attr name="spinBars" format="boolean"/> 770 <!-- The total size of the drawable --> 771 <attr name="drawableSize" format="dimension"/> 772 <!-- The max gap between the bars when they are parallel to each other --> 773 <attr name="gapBetweenBars" format="dimension"/> 774 <!-- The size of the top and bottom bars when they merge to the middle bar to form an arrow --> 775 <attr name="topBottomBarArrowSize" format="dimension"/> 776 <!-- The size of the middle bar when top and bottom bars merge into middle bar to form an arrow --> 777 <attr name="middleBarArrowSize" format="dimension"/> 778 <!-- The size of the bars when they are parallel to each other --> 779 <attr name="barSize" format="dimension"/> 780 <!-- The thickness (stroke size) for the bar paint --> 781 <attr name="thickness" format="dimension"/> 782 </declare-styleable> 783 784 <attr name="drawerArrowStyle" format="reference" /> 785 786 <declare-styleable name="ViewStubCompat"> 787 <!-- Supply an identifier for the layout resource to inflate when the ViewStub 788 becomes visible or when forced to do so. The layout resource must be a 789 valid reference to a layout. --> 790 <attr name="android:layout" /> 791 <!-- Overrides the id of the inflated View with this value. --> 792 <attr name="android:inflatedId" /> 793 <attr name="android:id" /> 794 </declare-styleable> 795 796 <declare-styleable name="SwitchCompat"> 797 <!-- Drawable to use as the "thumb" that switches back and forth. --> 798 <attr name="android:thumb" /> 799 <!-- Drawable to use as the "track" that the switch thumb slides within. --> 800 <attr name="track" format="reference" /> 801 <!-- Text to use when the switch is in the checked/"on" state. --> 802 <attr name="android:textOn" /> 803 <!-- Text to use when the switch is in the unchecked/"off" state. --> 804 <attr name="android:textOff" /> 805 <!-- Amount of padding on either side of text within the switch thumb. --> 806 <attr name="thumbTextPadding" format="dimension" /> 807 <!-- TextAppearance style for text displayed on the switch thumb. --> 808 <attr name="switchTextAppearance" format="reference" /> 809 <!-- Minimum width for the switch component --> 810 <attr name="switchMinWidth" format="dimension" /> 811 <!-- Minimum space between the switch and caption text --> 812 <attr name="switchPadding" format="dimension" /> 813 <!-- Whether to split the track and leave a gap for the thumb drawable. --> 814 <attr name="splitTrack" format="boolean" /> 815 <!-- Whether to draw on/off text. --> 816 <attr name="showText" format="boolean" /> 817 </declare-styleable> 818 819</resources> 820