In addition to Weibo, there is also WeChat
Please pay attention

WeChat public account
Shulou
2025-11-08 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article focuses on "how to use custom Layout to reset the title bar", interested friends may wish to take a look. The method introduced in this paper is simple, fast and practical. Let the editor take you to learn "how to use custom Layout to reset the title bar"!
The default title bar of Android UI is defined by android:label and displayed in the upper left corner of the screen. Android allows Activity to customize the title bar and reset it using a custom Layout, such as a Windows Mobile-style title bar.
App- > Activity- > Custom Title redefine the Activity title bar as the left and right text boxes, and the Layout definition R.layout.custom_title_1 is as follows:
(the following xml contains two text boxes, one left and one right.
In addition to using the ContentView set by setContentView, there is also a Windows class object corresponding to each Activity. The Windows class object is used to control the title bar, which can be customized or not displayed. )
Windows defines some Feature, which allows developers to make some customization: the Feature ID corresponding to the custom title bar is Window.FEATURE_CUSTOM_TITLE.
RequestWindowFeature (Window.FEATURE_CUSTOM_TITLE); setContentView (R.layout.custom_title); getWindow (). SetFeatureInt (Window.FEATURE_CUSTOM_TITLE, R.layout.custom_title_1); now that you have a better understanding of "how to reset the title block using custom Layout", you might as well do it! Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope





About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.