Style, Theme
Styling and theme resources are all used to beautify your Android app.
Styles: A collection of formats that can be reused.
The Android style resource is stored with the Res/values folder, its root element is <resources.../>, and the element can contain multiple <style> child elements, each <style> defines a style. \
The <style> element specifies the following properties:
1.name
2.parent: Specifies the parent class style that the style inherits from. When a style inherits from a parent style, the style gets all the styles defined in the parent style, and the current style can override the style specified in the parent class style.
The <style> element can be wrapped over multiple <item.../> sub-elements, each <item. /> defines a format item.
Eg:
Application Method:
Topic Resources
The theme resource XML file is also stored under the Res/values folder, the root element is <resources.../>, and the theme is defined using the <style> element.
The difference between theme resources and styles:
1. The theme cannot be used as a single view component, and the subject should function for all activity in the entire app or for the specified activity;
2. The format of the theme definition should be to change the appearance of the window format, such as the window title, window border, etc.;
Topic Resources also support inheritance relationships:
Several built-in theme resources, such as:theme.dialog==>, are available in the Android system.
Instance Use procedure:
Android Learning notes 38--styles and themes