Lines Matching refs:background

441  * If you set a background drawable for a View, then the View will draw it for you
769 * this flag set and a background. Use with DRAW_MASK when calling setFlags.
951 * background, if any.
1667 * Indicates whether the background is opaque.
3070 * Solid color to use as a background when creating the drawing cache. Enables
3269 * particular its background) as well as the Button class's attributes.
3286 Drawable background = null;
3330 background = a.getDrawable(attr);
3646 if (background != null) {
3647 setBackground(background);
3664 // Padding from the background drawable is stored at this point in mUserPaddingLeftInitial
3678 // Padding from the background drawable is stored at this point in mUserPaddingLeftInitial
4004 // Re-apply user/background padding so that scrollbar(s) get added
9321 * An example of overlapping rendering is a TextView with a background image, such as a
9322 * Button. An example of non-overlapping rendering is a TextView with no background, or
10498 // - Has a background
11143 * if a view has a background drawable and you want to draw the scrollbars
11521 * @param canvas the canvas on which the background will be drawn
12387 // the parameters of their background drawable without calling
12389 // (for instance isOpaque() returns true, but the background is
12775 * Setting a solid background color for the drawing cache's bitmaps will improve
12779 * @param color The background color to use for the drawing cache's bitmap
12795 * @return The background color to used for the drawing cache's bitmap
13674 * 1. Draw the background
13682 // Step 1, draw the background, if needed
13686 final Drawable background = mBackground;
13687 if (background != null) {
13692 background.setBounds(0, 0, mRight - mLeft, mBottom - mTop);
13697 background.draw(canvas);
13700 background.draw(canvas);
13862 * Override this if your view is known to always be drawn on top of a solid color background,
13870 * @return The known solid color background for this view, or 0 if the color may vary
14440 * Sets the background color for this view.
14441 * @param color the color of the background
14454 * Set the background to a given resource. The resource should refer to
14455 * a Drawable object or 0 to remove the background.
14476 * Set the background to a given Drawable, or remove the background. If the
14477 * background has padding, this View's padding is set to the background's
14478 * padding. However, when a background is removed, this View's padding isn't
14482 * @param background The Drawable to use as the background, or null to remove the
14483 * background
14485 public void setBackground(Drawable background) {
14487 setBackgroundDrawable(background);
14494 public void setBackgroundDrawable(Drawable background) {
14497 if (background == mBackground) {
14506 * Regardless of whether we're setting a new background or not, we want
14514 if (background != null) {
14521 background.setLayoutDirection(getLayoutDirection());
14522 if (background.getPadding(padding)) {
14524 switch (background.getLayoutDirection()) {
14540 if (mBackground == null || mBackground.getMinimumHeight() != background.getMinimumHeight() ||
14541 mBackground.getMinimumWidth() != background.getMinimumWidth()) {
14545 background.setCallback(this);
14546 if (background.isStateful()) {
14547 background.setState(getDrawableState());
14549 background.setVisible(getVisibility() == VISIBLE, false);
14550 mBackground = background;
14558 /* Remove the background */
14563 * This view ONLY drew the background before and we're removing
14564 * the background, so now it won't draw anything
14572 * When the background is set, we try to apply its padding to this
14573 * View. When the background is removed, we don't touch this View's
14578 // The old background's minimum size could have affected this
14594 * Gets the background drawable
14596 * @return The drawable used as the background for this view, if any.
15553 * The base class implementation of measure defaults to the background size,
15689 * and the background's minimum height
15705 * and the background's minimum width
15903 // The ONLY_DRAWS_BACKGROUND flag IS set and the background drawable
15904 // exists, so we remove the background drawable's non-transparent