Create your account

Already have an account? Login here

Note: By joining, you will receive periodic emails from Coursetro. You can unsubscribe from these emails.

Create account

88. Styles and Themes

Design + Code an Android App from Scratch

Woah, wait a second..

Scrounge up some loose change to become a pro member, or login to your account to view this lesson.

Alright, join now. Or login to your account if you're already a pro member.

This video talks about styles and themes in Android. Styles define the format and look for our User Interface. A Style is applied to an individual View or widget whereas a Theme is applied to an entire Activity or Application. Style definitions are added to the values.xml file under the res folder with the help of the style tag which can contain several item tags. Each item tag defines the property that you want to customise for the element on which this style will be applied. You can also inherit styles from an existing style and customise only those properties which you wish to change. When you apply a style to a View, it will apply the properties that it supports and ignore the others. You can use the styles defined by yourself which are contained in the values folder or the current theme which are accessed by the android:attr notation. When used as a theme, every View in the Activity or Application will apply every style property it supports. A style applied to a ViewGroup does not apply to the View elements inside that ViewGroup.

Course Cirriculum