|
Android example source code file (attrs.xml)
The attrs.xml Android example source code<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2006 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!-- Formatting note: terminate all comments with a period, to avoid breaking
the documentation output. To suppress comment lines from the documentation
output, insert an eat-comment element after the comment lines.
-->
<resources>
<!-- These are the standard attributes that make up a complete theme. -->
<declare-styleable name="Theme">
<!-- ============== -->
<!-- Generic styles -->
<!-- ============== -->
<eat-comment />
<!-- Default color of foreground imagery. -->
<attr name="colorForeground" format="color" />
<!-- Default color of foreground imagery on an inverted background. -->
<attr name="colorForegroundInverse" format="color" />
<!-- Color that matches (as closely as possible) the window background. -->
<attr name="colorBackground" format="color" />
<!-- This is a hint for a solid color that can be used for caching
rendered views. This will be the color of the background when
there is a solid background color; it will be null when the
background is a texture or translucent. -->
<attr name="colorBackgroundCacheHint" format="color" />
<!-- Default disabled alpha for widgets that set enabled/disabled alpha programmatically. -->
<attr name="disabledAlpha" format="float" />
<!-- Default background dim amount when a menu, dialog, or something similar pops up. -->
<attr name="backgroundDimAmount" format="float" />
<!-- Control whether dimming behind the window is enabled. The default
theme does not set this value, meaning it is based on whether the
window is floating. -->
<attr name="backgroundDimEnabled" format="boolean" />
<!-- =========== -->
<!-- Text styles -->
<!-- =========== -->
<eat-comment />
<!-- Default appearance of text: color, typeface, size, and style. -->
<attr name="textAppearance" format="reference" />
<!-- Default appearance of text against an inverted background:
color, typeface, size, and style. -->
<attr name="textAppearanceInverse" format="reference" />
<!-- The most prominent text color. -->
<attr name="textColorPrimary" format="reference|color" />
<!-- Secondary text color. -->
<attr name="textColorSecondary" format="reference|color" />
<!-- Tertiary text color. -->
<attr name="textColorTertiary" format="reference|color" />
<!-- Primary inverse text color, useful for inverted backgrounds. -->
<attr name="textColorPrimaryInverse" format="reference|color" />
<!-- Secondary inverse text color, useful for inverted backgrounds. -->
<attr name="textColorSecondaryInverse" format="reference|color" />
<!-- Tertiary inverse text color, useful for inverted backgrounds. -->
<attr name="textColorTertiaryInverse" format="reference|color" />
<!-- Inverse hint text color. -->
<attr name="textColorHintInverse" format="reference|color" />
<!-- Bright text color. Only differentiates based on the disabled state. -->
<attr name="textColorPrimaryDisableOnly" format="reference|color" />
<!-- Bright inverse text color. Only differentiates based on the disabled state. -->
<attr name="textColorPrimaryInverseDisableOnly" format="reference|color" />
<!-- Bright text color. This does not differentiate the disabled state. As an example,
buttons use this since they display the disabled state via the background and not the
foreground text color. -->
<attr name="textColorPrimaryNoDisable" format="reference|color" />
<!-- Dim text color. This does not differentiate the disabled state. -->
<attr name="textColorSecondaryNoDisable" format="reference|color" />
<!-- Bright inverse text color. This does not differentiate the disabled state. -->
<attr name="textColorPrimaryInverseNoDisable" format="reference|color" />
<!-- Dim inverse text color. This does not differentiate the disabled state. -->
<attr name="textColorSecondaryInverseNoDisable" format="reference|color" />
<!-- Text color for urls in search suggestions, used by things like global search and the browser. @hide -->
<attr name="textColorSearchUrl" format="reference|color" />
<!-- Search widget more corpus result item background. -->
<attr name="searchWidgetCorpusItemBackground" format="reference|color" />
<!-- Text color, typeface, size, and style for "large" text. Defaults to primary text color. -->
<attr name="textAppearanceLarge" format="reference" />
<!-- Text color, typeface, size, and style for "medium" text. Defaults to primary text color. -->
<attr name="textAppearanceMedium" format="reference" />
<!-- Text color, typeface, size, and style for "small" text. Defaults to secondary text color. -->
<attr name="textAppearanceSmall" format="reference" />
<!-- Text color, typeface, size, and style for "large" inverse text. Defaults to primary inverse text color. -->
<attr name="textAppearanceLargeInverse" format="reference" />
<!-- Text color, typeface, size, and style for "medium" inverse text. Defaults to primary inverse text color. -->
<attr name="textAppearanceMediumInverse" format="reference" />
<!-- Text color, typeface, size, and style for "small" inverse text. Defaults to secondary inverse text color. -->
<attr name="textAppearanceSmallInverse" format="reference" />
<!-- Text color, typeface, size, and style for system search result title. Defaults to primary inverse text color. -->
<attr name="textAppearanceSearchResultTitle" format="reference" />
<!-- Text color, typeface, size, and style for system search result subtitle. Defaults to primary inverse text color. -->
<attr name="textAppearanceSearchResultSubtitle" format="reference" />
<!-- Text color, typeface, size, and style for the text inside of a button. -->
<attr name="textAppearanceButton" format="reference" />
<!-- A styled string, specifying the style to be used for showing
inline candidate text when composing with an input method. The
text itself will be ignored, but the style spans will be applied
to the candidate text as it is edited. -->
<attr name="candidatesTextStyleSpans" format="reference|string" />
<!-- Drawable to use for check marks. -->
<attr name="textCheckMark" format="reference" />
<attr name="textCheckMarkInverse" format="reference" />
<!-- Drawable to use for multiple choice indicators. -->
<attr name="listChoiceIndicatorMultiple" format="reference" />
<!-- Drawable to use for single choice indicators. -->
<attr name="listChoiceIndicatorSingle" format="reference" />
<!-- ============= -->
<!-- Button styles -->
<!-- ============= -->
<eat-comment />
<!-- Normal Button style. -->
<attr name="buttonStyle" format="reference" />
<!-- Small Button style. -->
<attr name="buttonStyleSmall" format="reference" />
<!-- Button style to inset into an EditText. -->
<attr name="buttonStyleInset" format="reference" />
<!-- ToggleButton style. -->
<attr name="buttonStyleToggle" format="reference" />
<!-- ============== -->
<!-- Gallery styles -->
<!-- ============== -->
<eat-comment />
<!-- The preferred background for gallery items. This should be set
as the background of any Views you provide from the Adapter. -->
<attr name="galleryItemBackground" format="reference" />
<!-- =========== -->
<!-- List styles -->
<!-- =========== -->
<eat-comment />
<!-- The preferred list item height. -->
<attr name="listPreferredItemHeight" format="dimension" />
<!-- The drawable for the list divider. -->
<!-- The list item height for search results. @hide -->
<attr name="searchResultListItemHeight" format="dimension" />
<attr name="listDivider" format="reference" />
<!-- TextView style for list separators. -->
<attr name="listSeparatorTextViewStyle" format="reference" />
<!-- The preferred left padding for an expandable list item (for child-specific layouts,
use expandableListPreferredChildPaddingLeft). This takes into account
the indicator that will be shown to next to the item. -->
<attr name="expandableListPreferredItemPaddingLeft" format="dimension" />
<!-- The preferred left padding for an expandable list item that is a child.
If this is not provided, it defaults to the expandableListPreferredItemPaddingLeft. -->
<attr name="expandableListPreferredChildPaddingLeft" format="dimension" />
<!-- The preferred left bound for an expandable list item's indicator. For a child-specific
indicator, use expandableListPreferredChildIndicatorLeft. -->
<attr name="expandableListPreferredItemIndicatorLeft" format="dimension" />
<!-- The preferred right bound for an expandable list item's indicator. For a child-specific
indicator, use expandableListPreferredChildIndicatorRight. -->
<attr name="expandableListPreferredItemIndicatorRight" format="dimension" />
<!-- The preferred left bound for an expandable list child's indicator. -->
<attr name="expandableListPreferredChildIndicatorLeft" format="dimension" />
<!-- The preferred right bound for an expandable list child's indicator. -->
<attr name="expandableListPreferredChildIndicatorRight" format="dimension" />
<!-- ============= -->
<!-- Window styles -->
<!-- ============= -->
<eat-comment />
<!-- Drawable to use as the overall window background. There are a
few special considerations you should use when settings this
drawable:
<ul>
<li> This information will be used to infer the pixel format
for your window's surface. If the drawable has any
non-opaque pixels, your window will be translucent
(32 bpp).
<li> If you want to draw the entire background
yourself, you should set this drawable to some solid
color that closely matches that background (so the
system's preview of your window will match), and
then in code manually set your window's background to
null so it will not be drawn.
</ul> -->
<attr name="windowBackground" format="reference" />
<!-- Drawable to use as a frame around the window. -->
<attr name="windowFrame" format="reference" />
<!-- Flag indicating whether there should be no title on this window. -->
<attr name="windowNoTitle" format="boolean" />
<!-- Flag indicating whether this window should fill the entire screen. -->
<attr name="windowFullscreen" format="boolean" />
<!-- Flag indicating whether this is a floating window. -->
<attr name="windowIsFloating" format="boolean" />
<!-- Flag indicating whether this is a translucent window. -->
<attr name="windowIsTranslucent" format="boolean" />
<!-- Flag indicating that this window's background should be the
user's current wallpaper. -->
<attr name="windowShowWallpaper" format="boolean" />
<!-- This Drawable is overlaid over the foreground of the Window's content area, usually
to place a shadow below the title. -->
<attr name="windowContentOverlay" format="reference" />
<!-- The style resource to use for a window's title bar height. -->
<attr name="windowTitleSize" format="dimension" />
<!-- The style resource to use for a window's title text. -->
<attr name="windowTitleStyle" format="reference" />
<!-- The style resource to use for a window's title area. -->
<attr name="windowTitleBackgroundStyle" format="reference" />
<!-- Reference to a style resource holding
the set of window animations to use, which can be
any of the attributes defined by
{@link android.R.styleable#WindowAnimation}. -->
<attr name="windowAnimationStyle" format="reference" />
<!-- Defines the default soft input state that this window would
like when it is displayed. -->
<attr name="windowSoftInputMode">
<!-- Not specified, use what the system thinks is best. This
is the default. -->
<flag name="stateUnspecified" value="0" />
<!-- Leave the soft input window as-is, in whatever state it
last was. -->
<flag name="stateUnchanged" value="1" />
<!-- Make the soft input area hidden when normally appropriate
(when the user is navigating forward to your window). -->
<flag name="stateHidden" value="2" />
<!-- Always make the soft input area hidden when this window
has input focus. -->
<flag name="stateAlwaysHidden" value="3" />
<!-- Make the soft input area visible when normally appropriate
(when the user is navigating forward to your window). -->
<flag name="stateVisible" value="4" />
<!-- Always make the soft input area visible when this window
has input focus. -->
<flag name="stateAlwaysVisible" value="5" />
<!-- The window resize/pan adjustment has not been specified,
the system will automatically select between resize and pan
modes, depending
on whether the content of the window has any layout views
that can scroll their contents. If there is such a view,
then the window will be resized, with the assumption being
that the resizeable area can be reduced to make room for
the input UI. -->
<flag name="adjustUnspecified" value="0x00" />
<!-- Always resize the window: the content area of the window is
reduced to make room for the soft input area. -->
<flag name="adjustResize" value="0x10" />
<!-- Don't resize the window to make room for the soft input area;
instead pan the contents of the window as focus moves inside
of it so that the user can see what they are typing. This is
generally less desireable than panning because the user may
need to close the input area to get at and interact with
parts of the window. -->
<flag name="adjustPan" value="0x20" />
</attr>
<!-- Flag allowing you to disable the preview animation for a window.
The default value is false; if set to true, the system can never
use the window's theme to show a preview of it before your
actual instance is shown to the user. -->
<attr name="windowDisablePreview" format="boolean" />
<!-- Flag indicating that this window should not be displayed at all.
The default value is false; if set to true, and this window is
the main window of an Activity, then it will never actually
be added to the window manager. This means that your activity
must immediately quit without waiting for user interaction,
because there will be no such interaction coming. -->
<attr name="windowNoDisplay" format="boolean" />
<!-- ============ -->
<!-- Alert Dialog styles -->
<!-- ============ -->
<eat-comment />
<attr name="alertDialogStyle" format="reference" />
<!-- ============ -->
<!-- Panel styles -->
<!-- ============ -->
<eat-comment />
<!-- The background of a panel when it is inset from the left and right edges of the screen. -->
<attr name="panelBackground" format="reference|color" />
<!-- The background of a panel when it extends to the left and right edges of the screen. -->
<attr name="panelFullBackground" format="reference|color" />
<!-- Default color of foreground panel imagery. -->
<attr name="panelColorForeground" format="reference|color" />
<!-- Color that matches (as closely as possible) the panel background. -->
<attr name="panelColorBackground" format="reference|color" />
<!-- Default appearance of panel text. -->
<attr name="panelTextAppearance" format="reference" />
<!-- =================== -->
<!-- Other widget styles -->
<!-- =================== -->
<eat-comment />
<!-- Default AbsListView style. -->
<attr name="absListViewStyle" format="reference" />
<!-- Default AutoCompleteTextView style. -->
<attr name="autoCompleteTextViewStyle" format="reference" />
<!-- Default Checkbox style. -->
<attr name="checkboxStyle" format="reference" />
<!-- Default ListView style for drop downs. -->
<attr name="dropDownListViewStyle" format="reference" />
<!-- Default EditText style. -->
<attr name="editTextStyle" format="reference" />
<!-- Default ExpandableListView style. -->
<attr name="expandableListViewStyle" format="reference" />
<!-- Default Gallery style. -->
<attr name="galleryStyle" format="reference" />
<!-- Default GestureOverlayView style. -->
<attr name="gestureOverlayViewStyle" format="reference" />
<!-- Default GridView style. -->
<attr name="gridViewStyle" format="reference" />
<!-- The style resource to use for an ImageButton. -->
<attr name="imageButtonStyle" format="reference" />
<!-- The style resource to use for an ImageButton that is an image well. -->
<attr name="imageWellStyle" format="reference" />
<!-- Default ListView style. -->
<attr name="listViewStyle" format="reference" />
<!-- ListView with white background. -->
<attr name="listViewWhiteStyle" format="reference" />
<!-- Default PopupWindow style. -->
<attr name="popupWindowStyle" format="reference" />
<!-- Default ProgressBar style. This is a medium circular progress bar. -->
<attr name="progressBarStyle" format="reference" />
<!-- Horizontal ProgressBar style. This is a horizontal progress bar. -->
<attr name="progressBarStyleHorizontal" format="reference" />
<!-- Small ProgressBar style. This is a small circular progress bar. -->
<attr name="progressBarStyleSmall" format="reference" />
<!-- Small ProgressBar in title style. This is a small circular progress bar that will be placed in title bars. -->
<attr name="progressBarStyleSmallTitle" format="reference" />
<!-- Large ProgressBar style. This is a large circular progress bar. -->
<attr name="progressBarStyleLarge" format="reference" />
<!-- Inverse ProgressBar style. This is a medium circular progress bar. -->
<attr name="progressBarStyleInverse" format="reference" />
<!-- Small inverse ProgressBar style. This is a small circular progress bar. -->
<attr name="progressBarStyleSmallInverse" format="reference" />
<!-- Large inverse ProgressBar style. This is a large circular progress bar. -->
<attr name="progressBarStyleLargeInverse" format="reference" />
<!-- Default SeekBar style. -->
<attr name="seekBarStyle" format="reference" />
<!-- Default RatingBar style. -->
<attr name="ratingBarStyle" format="reference" />
<!-- Indicator RatingBar style. -->
<attr name="ratingBarStyleIndicator" format="reference" />
<!-- Small indicator RatingBar style. -->
<attr name="ratingBarStyleSmall" format="reference" />
<!-- Default RadioButton style. -->
<attr name="radioButtonStyle" format="reference" />
<!-- Default ScrollView style. -->
<attr name="scrollViewStyle" format="reference" />
<!-- Default HorizontalScrollView style. -->
<attr name="horizontalScrollViewStyle" format="reference" />
<!-- Default Spinner style. -->
<attr name="spinnerStyle" format="reference" />
<!-- Default Star style. -->
<attr name="starStyle" format="reference" />
<!-- Default TabWidget style. -->
<attr name="tabWidgetStyle" format="reference" />
<!-- Default TextView style. -->
<attr name="textViewStyle" format="reference" />
<!-- Default WebView style. -->
<attr name="webViewStyle" format="reference" />
<!-- Default style for drop down items. -->
<attr name="dropDownItemStyle" format="reference" />
<!-- Default style for spinner drop down items. -->
<attr name="spinnerDropDownItemStyle" format="reference" />
<!-- Default style for drop down hints. -->
<attr name="dropDownHintAppearance" format="reference" />
<!-- Default spinner item style. -->
<attr name="spinnerItemStyle" format="reference" />
<!-- Default MapView style. -->
<attr name="mapViewStyle" format="reference" />
<!-- Default quickcontact badge style. -->
<attr name="quickContactBadgeStyle" format="reference" />
<!-- Default quickcontact badge style with small quickcontact window. -->
<attr name="quickContactBadgeStyleWindowSmall" format="reference" />
<!-- Default quickcontact badge style with medium quickcontact window. -->
<attr name="quickContactBadgeStyleWindowMedium" format="reference" />
<!-- Default quickcontact badge style with large quickcontact window. -->
<attr name="quickContactBadgeStyleWindowLarge" format="reference" />
<!-- Default quickcontact badge style with small quickcontact window. -->
<attr name="quickContactBadgeStyleSmallWindowSmall" format="reference" />
<!-- Default quickcontact badge style with medium quickcontact window. -->
<attr name="quickContactBadgeStyleSmallWindowMedium" format="reference" />
<!-- Default quickcontact badge style with large quickcontact window. -->
<attr name="quickContactBadgeStyleSmallWindowLarge" format="reference" />
<!-- =================== -->
<!-- Preference styles -->
<!-- =================== -->
<eat-comment />
<!-- Default style for PreferenceScreen. -->
<attr name="preferenceScreenStyle" format="reference" />
<!-- Default style for PreferenceCategory. -->
<attr name="preferenceCategoryStyle" format="reference" />
<!-- Default style for Preference. -->
<attr name="preferenceStyle" format="reference" />
<!-- Default style for informational Preference. -->
<attr name="preferenceInformationStyle" format="reference" />
<!-- Default style for CheckBoxPreference. -->
<attr name="checkBoxPreferenceStyle" format="reference" />
<!-- Default style for YesNoPreference. -->
<attr name="yesNoPreferenceStyle" format="reference" />
<!-- Default style for DialogPreference. -->
<attr name="dialogPreferenceStyle" format="reference" />
<!-- Default style for EditTextPreference. -->
<attr name="editTextPreferenceStyle" format="reference" />
<!-- Default style for RingtonePreference. -->
<attr name="ringtonePreferenceStyle" format="reference" />
<!-- The preference layout that has the child/tabbed effect. -->
<attr name="preferenceLayoutChild" format="reference" />
</declare-styleable>
<!-- **************************************************************** -->
<!-- Other non-theme attributes. -->
<!-- **************************************************************** -->
<eat-comment />
<!-- Size of text. Recommended dimension type for text is "sp" for scaled-pixels (example: 15sp).
Supported values include the following:<p/>
<ul>
<li>px Pixels
<li>sp Scaled pixels (scaled to relative pixel size on screen). See {@link android.util.DisplayMetrics} for more information.
<li>pt Points
<li>dip Device independent pixels. See {@link android.util.DisplayMetrics} for more information.
</ul>
-->
<attr name="textSize" format="dimension" />
<!-- Default text typeface. -->
<attr name="typeface">
<enum name="normal" value="0" />
<enum name="sans" value="1" />
<enum name="serif" value="2" />
<enum name="monospace" value="3" />
</attr>
<!-- Default text typeface style. -->
<attr name="textStyle">
<flag name="normal" value="0" />
<flag name="bold" value="1" />
<flag name="italic" value="2" />
</attr>
<!-- Color of text (usually same as colorForeground). -->
<attr name="textColor" format="reference|color" />
<!-- Color of highlighted text. -->
<attr name="textColorHighlight" format="reference|color" />
<!-- Color of hint text (displayed when the field is empty). -->
<attr name="textColorHint" format="reference|color" />
<!-- Color of link text (URLs). -->
<attr name="textColorLink" format="reference|color" />
<!-- Where to ellipsize text. -->
<attr name="ellipsize">
<enum name="none" value="0" />
<enum name="start" value="1" />
<enum name="middle" value="2" />
<enum name="end" value="3" />
<enum name="marquee" value="4" />
</attr>
<!-- The type of data being placed in a text field, used to help an
input method decide how to let the user enter text. The constants
here correspond to those defined by
{@link android.text.InputType}. Generally you can select
a single value, though some can be combined together as
indicated. Setting this attribute to anything besides
<var>none also implies that the text is editable. -->
<attr name="inputType">
<!-- There is no content type. The text is not editable. -->
<flag name="none" value="0x00000000" />
<!-- Just plain old text. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_NORMAL}. -->
<flag name="text" value="0x00000001" />
<!-- Can be combined with and its variations to
request capitalization of all characters. Corresponds to
{@link android.text.InputType#TYPE_TEXT_FLAG_CAP_CHARACTERS}. -->
<flag name="textCapCharacters" value="0x00001001" />
<!-- Can be combined with and its variations to
request capitalization of the first character of every word. Corresponds to
{@link android.text.InputType#TYPE_TEXT_FLAG_CAP_WORDS}. -->
<flag name="textCapWords" value="0x00002001" />
<!-- Can be combined with and its variations to
request capitalization of the first character of every sentence. Corresponds to
{@link android.text.InputType#TYPE_TEXT_FLAG_CAP_SENTENCES}. -->
<flag name="textCapSentences" value="0x00004001" />
<!-- Can be combined with and its variations to
request auto-correction of text being input. Corresponds to
{@link android.text.InputType#TYPE_TEXT_FLAG_AUTO_CORRECT}. -->
<flag name="textAutoCorrect" value="0x00008001" />
<!-- Can be combined with and its variations to
specify that this field will be doing its own auto-completion and
talking with the input method appropriately. Corresponds to
{@link android.text.InputType#TYPE_TEXT_FLAG_AUTO_COMPLETE}. -->
<flag name="textAutoComplete" value="0x00010001" />
<!-- Can be combined with and its variations to
allow multiple lines of text in the field. If this flag is not set,
the text field will be constrained to a single line. Corresponds to
{@link android.text.InputType#TYPE_TEXT_FLAG_MULTI_LINE}. -->
<flag name="textMultiLine" value="0x00020001" />
<!-- Can be combined with and its variations to
indicate that though the regular text view should not be multiple
lines, the IME should provide multiple lines if it can. Corresponds to
{@link android.text.InputType#TYPE_TEXT_FLAG_IME_MULTI_LINE}. -->
<flag name="textImeMultiLine" value="0x00040001" />
<!-- Can be combined with and its variations to
indicate that the IME should not show any
dictionary-based word suggestions. Corresponds to
{@link android.text.InputType#TYPE_TEXT_FLAG_NO_SUGGESTIONS}. -->
<flag name="textNoSuggestions" value="0x00080001" />
<!-- Text that will be used as a URI. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_URI}. -->
<flag name="textUri" value="0x00000011" />
<!-- Text that will be used as an e-mail address. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_EMAIL_ADDRESS}. -->
<flag name="textEmailAddress" value="0x00000021" />
<!-- Text that is being supplied as the subject of an e-mail. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_EMAIL_SUBJECT}. -->
<flag name="textEmailSubject" value="0x00000031" />
<!-- Text that is the content of a short message. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_SHORT_MESSAGE}. -->
<flag name="textShortMessage" value="0x00000041" />
<!-- Text that is the content of a long message. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_LONG_MESSAGE}. -->
<flag name="textLongMessage" value="0x00000051" />
<!-- Text that is the name of a person. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_PERSON_NAME}. -->
<flag name="textPersonName" value="0x00000061" />
<!-- Text that is being supplied as a postal mailing address. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_POSTAL_ADDRESS}. -->
<flag name="textPostalAddress" value="0x00000071" />
<!-- Text that is a password. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_PASSWORD}. -->
<flag name="textPassword" value="0x00000081" />
<!-- Text that is a password that should be visible. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_VISIBLE_PASSWORD}. -->
<flag name="textVisiblePassword" value="0x00000091" />
<!-- Text that is being supplied as text in a web form. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_WEB_EDIT_TEXT}. -->
<flag name="textWebEditText" value="0x000000a1" />
<!-- Text that is filtering some other data. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_FILTER}. -->
<flag name="textFilter" value="0x000000b1" />
<!-- Text that is for phonetic pronunciation, such as a phonetic name
field in a contact entry. Corresponds to
{@link android.text.InputType#TYPE_CLASS_TEXT} |
{@link android.text.InputType#TYPE_TEXT_VARIATION_PHONETIC}. -->
<flag name="textPhonetic" value="0x000000c1" />
<!-- A numeric only field. Corresponds to
{@link android.text.InputType#TYPE_CLASS_NUMBER}. -->
<flag name="number" value="0x00000002" />
<!-- Can be combined with and its other options to
allow a signed number. Corresponds to
{@link android.text.InputType#TYPE_CLASS_NUMBER} |
{@link android.text.InputType#TYPE_NUMBER_FLAG_SIGNED}. -->
<flag name="numberSigned" value="0x00001002" />
<!-- Can be combined with and its other options to
allow a decimal (fractional) number. Corresponds to
{@link android.text.InputType#TYPE_CLASS_NUMBER} |
{@link android.text.InputType#TYPE_NUMBER_FLAG_DECIMAL}. -->
<flag name="numberDecimal" value="0x00002002" />
<!-- For entering a phone number. Corresponds to
{@link android.text.InputType#TYPE_CLASS_PHONE}. -->
<flag name="phone" value="0x00000003" />
<!-- For entering a date and time. Corresponds to
{@link android.text.InputType#TYPE_CLASS_DATETIME} |
{@link android.text.InputType#TYPE_DATETIME_VARIATION_NORMAL}. -->
<flag name="datetime" value="0x00000004" />
<!-- For entering a date. Corresponds to
{@link android.text.InputType#TYPE_CLASS_DATETIME} |
{@link android.text.InputType#TYPE_DATETIME_VARIATION_DATE}. -->
<flag name="date" value="0x00000014" />
<!-- For entering a time. Corresponds to
{@link android.text.InputType#TYPE_CLASS_DATETIME} |
{@link android.text.InputType#TYPE_DATETIME_VARIATION_TIME}. -->
<flag name="time" value="0x00000024" />
</attr>
<!-- Additional features you can enable in an IME associated with an editor
to improve the integration with your application. The constants
here correspond to those defined by
{@link android.view.inputmethod.EditorInfo#imeOptions}. -->
<attr name="imeOptions">
<!-- There are no special semantics associated with this editor. -->
<flag name="normal" value="0x00000000" />
<!-- There is no specific action associated with this editor, let the
editor come up with its own if it can.
Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_NULL}. -->
<flag name="actionUnspecified" value="0x00000000" />
<!-- This editor has no action associated with it.
Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_ACTION_NONE}. -->
<flag name="actionNone" value="0x00000001" />
<!-- The action key performs a "go"
operation to take the user to the target of the text they typed.
Typically used, for example, when entering a URL.
Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_ACTION_GO}. -->
<flag name="actionGo" value="0x00000002" />
<!-- The action key performs a "search"
operation, taking the user to the results of searching for the text
the have typed (in whatever context is appropriate).
Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_ACTION_SEARCH}. -->
<flag name="actionSearch" value="0x00000003" />
<!-- The action key performs a "send"
operation, delivering the text to its target. This is typically used
when composing a message.
Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_ACTION_SEND}. -->
<flag name="actionSend" value="0x00000004" />
<!-- The action key performs a "next"
operation, taking the user to the next field that will accept text.
Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_ACTION_NEXT}. -->
<flag name="actionNext" value="0x00000005" />
<!-- The action key performs a "done"
operation, closing the soft input method.
Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_ACTION_DONE}. -->
<flag name="actionDone" value="0x00000006" />
<!-- Used to specify that the IME does not need
to show its extracted text UI. For input methods that may be fullscreen,
often when in landscape mode, this allows them to be smaller and let part
of the application be shown behind. Though there will likely be limited
access to the application available from the user, it can make the
experience of a (mostly) fullscreen IME less jarring. Note that when
this flag is specified the IME may <em>not be set up to be able
to display text, so it should only be used in situations where this is
not needed.
<p>Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_FLAG_NO_EXTRACT_UI}. -->
<flag name="flagNoExtractUi" value="0x10000000" />
<!-- Used in conjunction with a custom action, this indicates that the
action should not be available as an accessory button when the
input method is full-screen.
Note that by setting this flag, there can be cases where the action
is simply never available to the user. Setting this generally means
that you think showing text being edited is more important than the
action you have supplied.
<p>Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_FLAG_NO_ACCESSORY_ACTION}. -->
<flag name="flagNoAccessoryAction" value="0x20000000" />
<!-- Used in conjunction with a custom action,
this indicates that the action should not be available in-line as
a replacement for the "enter" key. Typically this is
because the action has such a significant impact or is not recoverable
enough that accidentally hitting it should be avoided, such as sending
a message. Note that {@link android.widget.TextView} will
automatically set this flag for you on multi-line text views.
<p>Corresponds to
{@link android.view.inputmethod.EditorInfo#IME_FLAG_NO_ENTER_ACTION}. -->
<flag name="flagNoEnterAction" value="0x40000000" />
</attr>
<!-- A coordinate in the X dimension. -->
<attr name="x" format="dimension" />
<!-- A coordinate in the Y dimension. -->
<attr name="y" format="dimension" />
<!-- Specifies how to place the content of an object, both
on the x- and y-axis, within the object itself. -->
<attr name="gravity">
<!-- Push object to the top of its container, not changing its size. -->
<flag name="top" value="0x30" />
<!-- Push object to the bottom of its container, not changing its size. -->
<flag name="bottom" value="0x50" />
<!-- Push object to the left of its container, not changing its size. -->
<flag name="left" value="0x03" />
<!-- Push object to the right of its container, not changing its size. -->
<flag name="right" value="0x05" />
<!-- Place object in the vertical center of its container, not changing its size. -->
<flag name="center_vertical" value="0x10" />
<!-- Grow the vertical size of the object if needed so it completely fills its container. -->
<flag name="fill_vertical" value="0x70" />
<!-- Place object in the horizontal center of its container, not changing its size. -->
<flag name="center_horizontal" value="0x01" />
<!-- Grow the horizontal size of the object if needed so it completely fills its container. -->
<flag name="fill_horizontal" value="0x07" />
<!-- Place the object in the center of its container in both the vertical and horizontal axis, not changing its size. -->
<flag name="center" value="0x11" />
<!-- Grow the horizontal and vertical size of the object if needed so it completely fills its container. -->
<flag name="fill" value="0x77" />
<!-- Additional option that can be set to have the top and/or bottom edges of
the child clipped to its container's bounds.
The clip will be based on the vertical gravity: a top gravity will clip the bottom
edge, a bottom gravity will clip the top edge, and neither will clip both edges. -->
<flag name="clip_vertical" value="0x80" />
<!-- Additional option that can be set to have the left and/or right edges of
the child clipped to its container's bounds.
The clip will be based on the horizontal gravity: a left gravity will clip the right
edge, a right gravity will clip the left edge, and neither will clip both edges. -->
<flag name="clip_horizontal" value="0x08" />
</attr>
<!-- Controls whether links such as urls and email addresses are
automatically found and converted to clickable links. The default
value is "none", disabling this feature. -->
<attr name="autoLink">
<!-- Match no patterns (default). -->
<flag name="none" value="0x00" />
<!-- Match Web URLs. -->
<flag name="web" value="0x01" />
<!-- Match email addresses. -->
<flag name="email" value="0x02" />
<!-- Match phone numbers. -->
<flag name="phone" value="0x04" />
<!-- Match map addresses. -->
<flag name="map" value="0x08" />
<!-- Match all patterns (equivalent to web|email|phone|map). -->
<flag name="all" value="0x0f" />
</attr>
<!-- Reference to an array resource that will populate a list/adapter. -->
<attr name="entries" format="reference" />
<!-- Standard gravity constant that a child can supply to its parent.
Defines how to place the view, both its x- and y-axis, within its parent view group. -->
<attr name="layout_gravity">
<!-- Push object to the top of its container, not changing its size. -->
<flag name="top" value="0x30" />
<!-- Push object to the bottom of its container, not changing its size. -->
<flag name="bottom" value="0x50" />
<!-- Push object to the left of its container, not changing its size. -->
<flag name="left" value="0x03" />
<!-- Push object to the right of its container, not changing its size. -->
<flag name="right" value="0x05" />
<!-- Place object in the vertical center of its container, not changing its size. -->
<flag name="center_vertical" value="0x10" />
<!-- Grow the vertical size of the object if needed so it completely fills its container. -->
<flag name="fill_vertical" value="0x70" />
<!-- Place object in the horizontal center of its container, not changing its size. -->
<flag name="center_horizontal" value="0x01" />
<!-- Grow the horizontal size of the object if needed so it completely fills its container. -->
<flag name="fill_horizontal" value="0x07" />
<!-- Place the object in the center of its container in both the vertical and horizontal axis, not changing its size. -->
<flag name="center" value="0x11" />
<!-- Grow the horizontal and vertical size of the object if needed so it completely fills its container. -->
<flag name="fill" value="0x77" />
<!-- Additional option that can be set to have the top and/or bottom edges of
the child clipped to its container's bounds.
The clip will be based on the vertical gravity: a top gravity will clip the bottom
edge, a bottom gravity will clip the top edge, and neither will clip both edges. -->
<flag name="clip_vertical" value="0x80" />
<!-- Additional option that can be set to have the left and/or right edges of
the child clipped to its container's bounds.
The clip will be based on the horizontal gravity: a left gravity will clip the right
edge, a right gravity will clip the left edge, and neither will clip both edges. -->
<flag name="clip_horizontal" value="0x08" />
</attr>
<!-- Standard orientation constant. -->
<attr name="orientation">
<!-- Defines an horizontal widget. -->
<enum name="horizontal" value="0" />
<!-- Defines a vertical widget. -->
<enum name="vertical" value="1" />
</attr>
<!-- ========================== -->
<!-- Key Codes -->
<!-- ========================== -->
<eat-comment />
<!-- This enum provides the same keycode values as can be found in
{@link android.view.KeyEvent}. -->
<attr name="keycode">
<enum name="KEYCODE_UNKNOWN" value="0" />
<enum name="KEYCODE_SOFT_LEFT" value="1" />
<enum name="KEYCODE_SOFT_RIGHT" value="2" />
<enum name="KEYCODE_HOME" value="3" />
<enum name="KEYCODE_BACK" value="4" />
<enum name="KEYCODE_CALL" value="5" />
<enum name="KEYCODE_ENDCALL" value="6" />
<enum name="KEYCODE_0" value="7" />
<enum name="KEYCODE_1" value="8" />
<enum name="KEYCODE_2" value="9" />
<enum name="KEYCODE_3" value="10" />
<enum name="KEYCODE_4" value="11" />
<enum name="KEYCODE_5" value="12" />
<enum name="KEYCODE_6" value="13" />
<enum name="KEYCODE_7" value="14" />
<enum name="KEYCODE_8" value="15" />
<enum name="KEYCODE_9" value="16" />
<enum name="KEYCODE_STAR" value="17" />
<enum name="KEYCODE_POUND" value="18" />
<enum name="KEYCODE_DPAD_UP" value="19" />
<enum name="KEYCODE_DPAD_DOWN" value="20" />
<enum name="KEYCODE_DPAD_LEFT" value="21" />
<enum name="KEYCODE_DPAD_RIGHT" value="22" />
<enum name="KEYCODE_DPAD_CENTER" value="23" />
<enum name="KEYCODE_VOLUME_UP" value="24" />
<enum name="KEYCODE_VOLUME_DOWN" value="25" />
<enum name="KEYCODE_POWER" value="26" />
<enum name="KEYCODE_CAMERA" value="27" />
<enum name="KEYCODE_CLEAR" value="28" />
<enum name="KEYCODE_A" value="29" />
<enum name="KEYCODE_B" value="30" />
<enum name="KEYCODE_C" value="31" />
<enum name="KEYCODE_D" value="32" />
<enum name="KEYCODE_E" value="33" />
<enum name="KEYCODE_F" value="34" />
<enum name="KEYCODE_G" value="35" />
<enum name="KEYCODE_H" value="36" />
<enum name="KEYCODE_I" value="37" />
<enum name="KEYCODE_J" value="38" />
<enum name="KEYCODE_K" value="39" />
<enum name="KEYCODE_L" value="40" />
<enum name="KEYCODE_M" value="41" />
<enum name="KEYCODE_N" value="42" />
<enum name="KEYCODE_O" value="43" />
<enum name="KEYCODE_P" value="44" />
<enum name="KEYCODE_Q" value="45" />
<enum name="KEYCODE_R" value="46" />
<enum name="KEYCODE_S" value="47" />
<enum name="KEYCODE_T" value="48" />
<enum name="KEYCODE_U" value="49" />
<enum name="KEYCODE_V" value="50" />
<enum name="KEYCODE_W" value="51" />
<enum name="KEYCODE_X" value="52" />
<enum name="KEYCODE_Y" value="53" />
<enum name="KEYCODE_Z" value="54" />
<enum name="KEYCODE_COMMA" value="55" />
<enum name="KEYCODE_PERIOD" value="56" />
<enum name="KEYCODE_ALT_LEFT" value="57" />
<enum name="KEYCODE_ALT_RIGHT" value="58" />
<enum name="KEYCODE_SHIFT_LEFT" value="59" />
<enum name="KEYCODE_SHIFT_RIGHT" value="60" />
<enum name="KEYCODE_TAB" value="61" />
<enum name="KEYCODE_SPACE" value="62" />
<enum name="KEYCODE_SYM" value="63" />
<enum name="KEYCODE_EXPLORER" value="64" />
<enum name="KEYCODE_ENVELOPE" value="65" />
<enum name="KEYCODE_ENTER" value="66" />
<enum name="KEYCODE_DEL" value="67" />
<enum name="KEYCODE_GRAVE" value="68" />
<enum name="KEYCODE_MINUS" value="69" />
<enum name="KEYCODE_EQUALS" value="70" />
<enum name="KEYCODE_LEFT_BRACKET" value="71" />
<enum name="KEYCODE_RIGHT_BRACKET" value="72" />
<enum name="KEYCODE_BACKSLASH" value="73" />
<enum name="KEYCODE_SEMICOLON" value="74" />
<enum name="KEYCODE_APOSTROPHE" value="75" />
<enum name="KEYCODE_SLASH" value="76" />
<enum name="KEYCODE_AT" value="77" />
<enum name="KEYCODE_NUM" value="78" />
<enum name="KEYCODE_HEADSETHOOK" value="79" />
<enum name="KEYCODE_FOCUS" value="80" />
<enum name="KEYCODE_PLUS" value="81" />
<enum name="KEYCODE_MENU" value="82" />
<enum name="KEYCODE_NOTIFICATION" value="83" />
<enum name="KEYCODE_SEARCH" value="84" />
<enum name="KEYCODE_MEDIA_PLAY_PAUSE" value="85" />
<enum name="KEYCODE_MEDIA_STOP" value="86" />
<enum name="KEYCODE_MEDIA_NEXT" value="87" />
<enum name="KEYCODE_MEDIA_PREVIOUS" value="88" />
<enum name="KEYCODE_MEDIA_REWIND" value="89" />
<enum name="KEYCODE_MEDIA_FAST_FORWARD" value="90" />
<enum name="KEYCODE_MUTE" value="91" />
</attr>
<!-- ***************************************************************** -->
<!-- These define collections of attributes that can are with classes. -->
<!-- ***************************************************************** -->
<!-- ========================== -->
<!-- Special attribute classes. -->
<!-- ========================== -->
<eat-comment />
<!-- The set of attributes that describe a Windows's theme. -->
<declare-styleable name="Window">
<attr name="windowBackground" />
<attr name="windowContentOverlay" />
<attr name="windowFrame" />
<attr name="windowNoTitle" />
<attr name="windowFullscreen" />
<attr name="windowIsFloating" />
<attr name="windowIsTranslucent" />
<attr name="windowShowWallpaper" />
<attr name="windowAnimationStyle" />
<attr name="windowSoftInputMode" />
<attr name="windowDisablePreview" />
<attr name="windowNoDisplay" />
<attr name="textColor" />
<attr name="backgroundDimEnabled" />
<attr name="backgroundDimAmount" />
</declare-styleable>
<!-- The set of attributes that describe a AlertDialog's theme. -->
<declare-styleable name="AlertDialog">
<attr name="fullDark" format="reference|color" />
<attr name="topDark" format="reference|color" />
<attr name="centerDark" format="reference|color" />
<attr name="bottomDark" format="reference|color" />
<attr name="fullBright" format="reference|color" />
<attr name="topBright" format="reference|color" />
<attr name="centerBright" format="reference|color" />
<attr name="bottomBright" format="reference|color" />
<attr name="bottomMedium" format="reference|color" />
<attr name="centerMedium" format="reference|color" />
</declare-styleable>
<!-- Window animation class attributes. -->
<declare-styleable name="WindowAnimation">
<!-- The animation used when a window is being added. -->
<attr name="windowEnterAnimation" format="reference" />
<!-- The animation used when a window is being removed. -->
<attr name="windowExitAnimation" format="reference" />
<!-- The animation used when a window is going from INVISIBLE to VISIBLE. -->
<attr name="windowShowAnimation" format="reference" />
<!-- The animation used when a window is going from VISIBLE to INVISIBLE. -->
<attr name="windowHideAnimation" format="reference" />
<!-- When opening a new activity, this is the animation that is
run on the next activity (which is entering the screen). -->
<attr name="activityOpenEnterAnimation" format="reference" />
<!-- When opening a new activity, this is the animation that is
run on the previous activity (which is exiting the screen). -->
<attr name="activityOpenExitAnimation" format="reference" />
<!-- When closing the current activity, this is the animation that is
run on the next activity (which is entering the screen). -->
<attr name="activityCloseEnterAnimation" format="reference" />
<!-- When closing the current activity, this is the animation that is
run on the current activity (which is exiting the screen). -->
<attr name="activityCloseExitAnimation" format="reference" />
<!-- When opening an activity in a new task, this is the animation that is
run on the activity of the new task (which is entering the screen). -->
<attr name="taskOpenEnterAnimation" format="reference" />
<!-- When opening an activity in a new task, this is the animation that is
run on the activity of the old task (which is exiting the screen). -->
<attr name="taskOpenExitAnimation" format="reference" />
<!-- When closing the last activity of a task, this is the animation that is
run on the activity of the next task (which is entering the screen). -->
<attr name="taskCloseEnterAnimation" format="reference" />
<!-- When opening an activity in a new task, this is the animation that is
run on the activity of the old task (which is exiting the screen). -->
<attr name="taskCloseExitAnimation" format="reference" />
<!-- When bringing an existing task to the foreground, this is the
animation that is run on the top activity of the task being brought
to the foreground (which is entering the screen). -->
<attr name="taskToFrontEnterAnimation" format="reference" />
<!-- When bringing an existing task to the foreground, this is the
animation that is run on the current foreground activity
(which is exiting the screen). -->
<attr name="taskToFrontExitAnimation" format="reference" />
<!-- When sending the current task to the background, this is the
animation that is run on the top activity of the task behind
it (which is entering the screen). -->
<attr name="taskToBackEnterAnimation" format="reference" />
<!-- When sending the current task to the background, this is the
animation that is run on the top activity of the current task
(which is exiting the screen). -->
<attr name="taskToBackExitAnimation" format="reference" />
<!-- When opening a new activity that shows the wallpaper, while
currently not showing the wallpaper, this is the animation that
is run on the new wallpaper activity (which is entering the screen). -->
<attr name="wallpaperOpenEnterAnimation" format="reference" />
<!-- When opening a new activity that shows the wallpaper, while
currently not showing the wallpaper, this is the animation that
is run on the current activity (which is exiting the screen). -->
<attr name="wallpaperOpenExitAnimation" format="reference" />
<!-- When opening a new activity that hides the wallpaper, while
currently showing the wallpaper, this is the animation that
is run on the new activity (which is entering the screen). -->
<attr name="wallpaperCloseEnterAnimation" format="reference" />
<!-- When opening a new activity that hides the wallpaper, while
currently showing the wallpaper, this is the animation that
is run on the old wallpaper activity (which is exiting the screen). -->
<attr name="wallpaperCloseExitAnimation" format="reference" />
<!-- When opening a new activity that is on top of the wallpaper
when the current activity is also on top of the wallpaper,
this is the animation that is run on the new activity
(which is entering the screen). The wallpaper remains
static behind the animation. -->
<attr name="wallpaperIntraOpenEnterAnimation" format="reference" />
<!-- When opening a new activity that is on top of the wallpaper
when the current activity is also on top of the wallpaper,
this is the animation that is run on the current activity
(which is exiting the screen). The wallpaper remains
static behind the animation. -->
<attr name="wallpaperIntraOpenExitAnimation" format="reference" />
<!-- When closing a foreround activity that is on top of the wallpaper
when the previous activity is also on top of the wallpaper,
this is the animation that is run on the previous activity
(which is entering the screen). The wallpaper remains
static behind the animation. -->
<attr name="wallpaperIntraCloseEnterAnimation" format="reference" />
<!-- When closing a foreround activity that is on top of the wallpaper
when the previous activity is also on top of the wallpaper,
this is the animation that is run on the current activity
(which is exiting the screen). The wallpaper remains
static behind the animation. -->
<attr name="wallpaperIntraCloseExitAnimation" format="reference" />
</declare-styleable>
<!-- ============================= -->
<!-- View package class attributes -->
<!-- ============================= -->
<eat-comment />
<!-- Attributes that can be used with {@link android.view.View} or
any of its subclasses. Also see {@link #ViewGroup_Layout} for
attributes that are processed by the view's parent. -->
<declare-styleable name="View">
<!-- Supply an identifier name for this view, to later retrieve it
with {@link android.view.View#findViewById View.findViewById()} or
{@link android.app.Activity#findViewById Activity.findViewById()}.
This must be a
resource reference; typically you set this using the
<code>@+ syntax to create a new ID resources.
For example: <code>android:id="@+id/my_id" which
allows you to later retrieve the view
with <code>findViewById(R.id.my_id). -->
<attr name="id" format="reference" />
<!-- Supply a tag for this view containing a String, to be retrieved
later with {@link android.view.View#getTag View.getTag()} or
searched for with {@link android.view.View#findViewWithTag
View.findViewWithTag()}. It is generally preferable to use
IDs (through the android:id attribute) instead of tags because
they are faster and allow for compile-time type checking. -->
<attr name="tag" format="string" />
<!-- The initial horizontal scroll offset, in pixels.-->
<attr name="scrollX" format="dimension" />
<!-- The initial vertical scroll offset, in pixels. -->
<attr name="scrollY" format="dimension" />
<!-- A drawable to use as the background. This can be either a reference
to a full drawable resource (such as a PNG image, 9-patch,
XML state list description, etc), or a solid color such as "#ff000000"
(black). -->
<attr name="background" format="reference|color" />
<!-- Sets the padding, in pixels, of all four edges. Padding is defined as
space between the edges of the view and the view's content. A views size
will include it's padding. If a {@link android.R.attr#background}
is provided, the padding will initially be set to that (0 if the
drawable does not have padding). Explicitly setting a padding value
will override the corresponding padding found in the background. -->
<attr name="padding" format="dimension" />
<!-- Sets the padding, in pixels, of the left edge; see {@link android.R.attr#padding}. -->
<attr name="paddingLeft" format="dimension" />
<!-- Sets the padding, in pixels, of the top edge; see {@link android.R.attr#padding}. -->
<attr name="paddingTop" format="dimension" />
<!-- Sets the padding, in pixels, of the right edge; see {@link android.R.attr#padding}. -->
<attr name="paddingRight" format="dimension" />
<!-- Sets the padding, in pixels, of the bottom edge; see {@link android.R.attr#padding}. -->
<attr name="paddingBottom" format="dimension" />
<!-- Boolean that controls whether a view can take focus. By default the user can not
move focus to a view; by setting this attribute to true the view is
allowed to take focus. This value does not impact the behavior of
directly calling {@link android.view.View#requestFocus}, which will
always request focus regardless of this view. It only impacts where
focus navigation will try to move focus. -->
<attr name="focusable" format="boolean" />
<!-- Boolean that controls whether a view can take focus while in touch mode.
If this is true for a view, that view can gain focus when clicked on, and can keep
focus if another view is clicked on that doesn't have this attribute set to true. -->
<attr name="focusableInTouchMode" format="boolean" />
<!-- Controls the initial visibility of the view. -->
<attr name="visibility">
<!-- Visible on screen; the default value. -->
<enum name="visible" value="0" />
<!-- Not displayed, but taken into account during layout (space is left for it). -->
<enum name="invisible" value="1" />
<!-- Completely hidden, as if the view had not been added. -->
<enum name="gone" value="2" />
</attr>
<!-- Boolean internal attribute to adjust view layout based on
system windows such as the status bar.
If true, adjusts the padding of this view to leave space for the system windows.
Will only take effect if this view is in a non-embedded activity. -->
<attr name="fitsSystemWindows" format="boolean" />
<!-- Defines which scrollbars should be displayed on scrolling or not. -->
<attr name="scrollbars">
<!-- No scrollbar is displayed. -->
<flag name="none" value="0x00000000" />
<!-- Displays horizontal scrollbar only. -->
<flag name="horizontal" value="0x00000100" />
<!-- Displays vertical scrollbar only. -->
<flag name="vertical" value="0x00000200" />
</attr>
<!-- Controls the scrollbar style and position. The scrollbars can be overlaid or
inset. When inset, they add to the padding of the view. And the
scrollbars can be drawn inside the padding area or on the edge of
the view. For example, if a view has a background drawable and you
want to draw the scrollbars inside the padding specified by the
drawable, you can use insideOverlay or insideInset. If you want them
to appear at the edge of the view, ignoring the padding, then you can
use outsideOverlay or outsideInset.-->
<attr name="scrollbarStyle">
<!-- Inside the padding and overlaid -->
<enum name="insideOverlay" value="0x0" />
<!-- Inside the padding and inset -->
<enum name="insideInset" value="0x01000000" />
<!-- Edge of the view and overlaid -->
<enum name="outsideOverlay" value="0x02000000" />
<!-- Edge of the view and inset -->
<enum name="outsideInset" value="0x03000000" />
</attr>
<!-- Set this if the view will serve as a scrolling container, meaing
that it can be resized to shrink its overall window so that there
will be space for an input method. If not set, the default
value will be true if "scrollbars" has the vertical scrollbar
set, else it will be false. -->
<attr name="isScrollContainer" format="boolean" />
<!-- Defines whether to fade out scrollbars when they are not in use. -->
<attr name="fadeScrollbars" format="boolean" />
<!-- Defines the delay in milliseconds that a scrollbar takes to fade out. -->
<attr name="scrollbarFadeDuration" format="integer" />
<!-- Defines the delay in milliseconds that a scrollbar waits before fade out. -->
<attr name="scrollbarDefaultDelayBeforeFade" format="integer" />
<!-- Sets the width of vertical scrollbars and height of horizontal scrollbars. -->
<attr name="scrollbarSize" format="dimension" />
<!-- Defines the horizontal scrollbar thumb drawable. -->
<attr name="scrollbarThumbHorizontal" format="reference" />
<!-- Defines the vertical scrollbar thumb drawable. -->
<attr name="scrollbarThumbVertical" format="reference" />
<!-- Defines the horizontal scrollbar track drawable. -->
<attr name="scrollbarTrackHorizontal" format="reference" />
<!-- Defines the vertical scrollbar track drawable. -->
<attr name="scrollbarTrackVertical" format="reference" />
<!-- Defines whether the horizontal scrollbar track should always be drawn. -->
<attr name="scrollbarAlwaysDrawHorizontalTrack" format="boolean" />
<!-- Defines whether the vertical scrollbar track should always be drawn. -->
<attr name="scrollbarAlwaysDrawVerticalTrack" format="boolean" />
<!-- Defines which edges should be fadeded on scrolling. -->
<attr name="fadingEdge">
<!-- No edge is faded. -->
<flag name="none" value="0x00000000" />
<!-- Fades horizontal edges only. -->
<flag name="horizontal" value="0x00001000" />
<!-- Fades vertical edges only. -->
<flag name="vertical" value="0x00002000" />
</attr>
<!-- Defines the length of the fading edges. -->
<attr name="fadingEdgeLength" format="dimension" />
<!-- Defines the next view to give focus to when the next focus is
{@link android.view.View#FOCUS_LEFT}.
If the reference refers to a view that does not exist or is part
of a hierarchy that is invisible, a {@link java.lang.RuntimeException}
will result when the reference is accessed.-->
<attr name="nextFocusLeft" format="reference"/>
<!-- Defines the next view to give focus to when the next focus is
{@link android.view.View#FOCUS_RIGHT}
If the reference refers to a view that does not exist or is part
of a hierarchy that is invisible, a {@link java.lang.RuntimeException}
will result when the reference is accessed.-->
<attr name="nextFocusRight" format="reference"/>
<!-- Defines the next view to give focus to when the next focus is
{@link android.view.View#FOCUS_UP}
If the reference refers to a view that does not exist or is part
of a hierarchy that is invisible, a {@link java.lang.RuntimeException}
will result when the reference is accessed.-->
<attr name="nextFocusUp" format="reference"/>
<!-- Defines the next view to give focus to when the next focus is
{@link android.view.View#FOCUS_DOWN}
If the reference refers to a view that does not exist or is part
of a hierarchy that is invisible, a {@link java.lang.RuntimeException}
will result when the reference is accessed.-->
<attr name="nextFocusDown" format="reference"/>
<!-- Defines whether this view reacts to click events. -->
<attr name="clickable" format="boolean" />
<!-- Defines whether this view reacts to long click events. -->
<attr name="longClickable" format="boolean" />
<!-- If unset, no state will be saved for this view when it is being
frozen. The default is true, allowing the view to be saved
(however it also must have an ID assigned to it for its
state to be saved). Setting this to false only disables the
state for this view, not for its children which may still
be saved. -->
<attr name="saveEnabled" format="boolean" />
<!-- Defines the quality of translucent drawing caches. This property is used
only when the drawing cache is enabled and translucent. The default value is auto. -->
<attr name="drawingCacheQuality">
<!-- Lets the framework decide what quality level should be used
for the drawing cache. -->
<enum name="auto" value="0" />
<!-- Low quality. When set to low quality, the drawing cache uses a lower color
depth, thus losing precision in rendering gradients, but uses less memory. -->
<enum name="low" value="1" />
<!-- High quality. When set to high quality, the drawing cache uses a higher
color depth but uses more memory. -->
<enum name="high" value="2" />
</attr>
<!-- Controls whether the view's window should keep the screen on
while visible. -->
<attr name="keepScreenOn" format="boolean" />
<!-- When this attribute is set to true, the view gets its drawable state
(focused, pressed, etc.) from its direct parent rather than from itself. -->
<attr name="duplicateParentState" format="boolean" />
<!-- Defines the minimum height of the view. It is not guaranteed
the view will be able to achieve this minimum height (for example,
if its parent layout constrains it with less available height). -->
<attr name="minHeight" />
<!-- Defines the minimum width of the view. It is not guaranteed
the view will be able to achieve this minimum width (for example,
if its parent layout constrains it with less available width). -->
<attr name="minWidth" />
<!-- Boolean that controls whether a view should have sound effects
enabled for events such as clicking and touching. -->
<attr name="soundEffectsEnabled" format="boolean" />
<!-- Boolean that controls whether a view should have haptic feedback
enabled for events such as long presses. -->
<attr name="hapticFeedbackEnabled" format="boolean" />
<!-- Defines text that briefly describes content of the view. This property is used
primarily for accessibility. Since some views do not have textual
representation this attribute can be used for providing such. -->
<attr name="contentDescription" format="string" localization="suggested" />
<!-- Name of the method in this View's context to invoke when the view is
clicked. This name must correspond to a public method that takes
exactly one parameter of type View. For instance, if you specify
<code>android:onClick="sayHello", you must declare a
<code>public void sayHello(View v) method of your context
(typically, your Activity). -->
<attr name="onClick" format="string" />
</declare-styleable>
<!-- Attributes that can be used with a {@link android.view.ViewGroup} or any
of its subclasses. Also see {@link #ViewGroup_Layout} for
attributes that this class processes in its children. -->
<declare-styleable name="ViewGroup">
<!-- Defines whether a child is limited to draw inside of its bounds or not.
This is useful with animations that scale the size of the children to more
than 100% for instance. In such a case, this property should be set to false
to allow the children to draw outside of their bounds. The default value of
this property is true. -->
<attr name="clipChildren" format="boolean" />
<!-- Defines whether the ViewGroup will clip its drawing surface so as to exclude
the padding area. This property is set to true by default. -->
<attr name="clipToPadding" format="boolean" />
<!-- Defines the layout animation to use the first time the ViewGroup is laid out.
Layout animations can also be started manually after the first layout. -->
<attr name="layoutAnimation" format="reference" />
<!-- Defines whether layout animations should create a drawing cache for their
children. Enabling the animation cache consumes more memory and requires
a longer initialization but provides better performance. The animation
cache is enabled by default. -->
<attr name="animationCache" format="boolean" />
<!-- Defines the persistence of the drawing cache. The drawing cache might be
enabled by a ViewGroup for all its children in specific situations (for
instance during a scrolling.) This property lets you persist the cache
in memory after its initial usage. Persisting the cache consumes more
memory but may prevent frequent garbage collection is the cache is created
over and over again. By default the persistence is set to scrolling. -->
<attr name="persistentDrawingCache">
<!-- The drawing cache is not persisted after use. -->
<flag name="none" value="0x0" />
<!-- The drawing cache is persisted after a layout animation. -->
<flag name="animation" value="0x1" />
<!-- The drawing cache is persisted after a scroll. -->
<flag name="scrolling" value="0x2" />
<!-- The drawing cache is always persisted. -->
<flag name="all" value="0x3" />
</attr>
<!-- Defines whether the ViewGroup should always draw its children using their
drawing cache or not. The default value is true. -->
<attr name="alwaysDrawnWithCache" format="boolean" />
<!-- Sets whether this ViewGroup's drawable states also include
its children's drawable states. This is used, for example, to
make a group appear to be focused when its child EditText or button
is focused. -->
<attr name="addStatesFromChildren" format="boolean" />
<!-- Defines the relationship between the ViewGroup and its descendants
when looking for a View to take focus. -->
<attr name="descendantFocusability">
<!-- The ViewGroup will get focus before any of its descendants. -->
<enum name="beforeDescendants" value="0" />
<!-- The ViewGroup will get focus only if none of its descendants want it. -->
<enum name="afterDescendants" value="1" />
<!-- The ViewGroup will block its descendants from receiving focus. -->
<enum name="blocksDescendants" value="2" />
</attr>
</declare-styleable>
<!-- A {@link android.view.ViewStub} lets you lazily include other XML layouts
inside your application at runtime. -->
<declare-styleable name="ViewStub">
<!-- Supply an identifier for the layout resource to inflate when the ViewStub
becomes visible or when forced to do so. The layout resource must be a
valid reference to a layout. -->
<attr name="layout" format="reference" />
<!-- Overrides the id of the inflated View with this value. -->
<attr name="inflatedId" format="reference" />
</declare-styleable>
<!-- ===================================== -->
<!-- View package parent layout attributes -->
<!-- ===================================== -->
<eat-comment />
<!-- This is the basic set of layout attributes that are common to all
layout managers. These attributes are specified with the rest of
a view's normal attributes (such as {@link android.R.attr#background},
but will be parsed by the view's parent and ignored by the child.
<p>The values defined here correspond to the base layout attribute
class {@link android.view.ViewGroup.LayoutParams}. -->
<declare-styleable name="ViewGroup_Layout">
<!-- Specifies the basic width of the view. This is a required attribute
for any view inside of a containing layout manager. Its value may
be a dimension (such as "12dip") for a constant width or one of
the special constants. -->
<attr name="layout_width" format="dimension">
<!-- The view should be as big as its parent (minus padding). -->
<enum name="fill_parent" value="-1" />
<!-- The view should be only big enough to enclose its content (plus padding). -->
<enum name="wrap_content" value="-2" />
</attr>
<!-- Specifies the basic height of the view. This is a required attribute
for any view inside of a containing layout manager. Its value may
be a dimension (such as "12dip") for a constant height or one of
the special constants. -->
<attr name="layout_height" format="dimension">
<!-- The view should be as big as its parent (minus padding). -->
<enum name="fill_parent" value="-1" />
<!-- The view should be only big enough to enclose its content (plus padding). -->
<enum name="wrap_content" value="-2" />
</attr>
</declare-styleable>
<!-- This is the basic set of layout attributes for layout managers that
wish to place margins around their child views.
These attributes are specified with the rest of
a view's normal attributes (such as {@link android.R.attr#background},
but will be parsed by the view's parent and ignored by the child.
<p>The values defined here correspond to the base layout attribute
class {@link android.view.ViewGroup.MarginLayoutParams}. -->
<declare-styleable name="ViewGroup_MarginLayout">
<attr name="layout_width" />
<attr name="layout_height" />
<!-- Specifies extra space on the left, top, right and bottom
sides of this view. This space is outside this view's bounds. -->
<attr name="layout_margin" format="dimension" />
<!-- Specifies extra space on the left side of this view.
This space is outside this view's bounds. -->
<attr name="layout_marginLeft" format="dimension" />
<!-- Specifies extra space on the top side of this view.
This space is outside this view's bounds. -->
<attr name="layout_marginTop" format="dimension" />
<!-- Specifies extra space on the right side of this view.
This space is outside this view's bounds. -->
<attr name="layout_marginRight" format="dimension" />
<!-- Specifies extra space on the bottom side of this view.
This space is outside this view's bounds. -->
<attr name="layout_marginBottom" format="dimension" />
</declare-styleable>
<!-- Use
Other Android examples (source code examples)Here is a short list of links related to this Android attrs.xml source code file: |
... this post is sponsored by my books ... | |
![]() #1 New Release! |
![]() FP Best Seller |
Copyright 1998-2024 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.