Android custom title bar with full background color

Source: Internet
Author: User

1> prepare a background image:Background_pix.png

Bitmap_repeat.xml

 

3> define the style File style. xml

@ Style/StatusBarBackground

4> reference the topic android: theme = in manifest. xml"@ Style/XTheme"

 
  • Custom title bar layout file ct_title.xml

Note: In the ct_title.xml file, setting the title bar background in the following way will result in insufficient filling.

Android: background = "@ drawable/bitmap_repeat"
 

 

 

 

Reprinted please indicate the source: http://www.cnblogs.com/yydcdut/p/3694597.html

See http://www.iteye.com/topic/760314 for details

Code: http://pan.baidu.com/s/1dD1Qx01
Second.zip

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.