Monday, December 26, 2011

XML - Layout gist

xmlns: android This is an XML namespace declaration that tells the android tools that we are going to refer to common attributes defined in the android namespace. The outermost tag in every Android layout file must have this attribute.
android:idThis attribute assigns a unique identifier to any of the android.widget class.
android:layout_width as the name implies, its the screen width and
android:layout_height the screen height.
android:textThis sets the text that TextView should display.
res/values/strings.xmlyou use a string resource instead of a hard-coded string value.

No comments:

Post a Comment