Wednesday, 7 November 2012

Android Manifest XML file


  • Used to define some of the resources

  1. Layouts (UI)
  2. Strings
  3. Manifest file

  • Shouldn’t usually have to edit it directly,Eclipse can do that for you
  • Preferred way of creating UIs

  1. Separates the description of the layout from any actual code that controls it
  2. Can easily take a UI from one platform to another

R Class

  • Auto-generated: you shouldn’t edit it
  • Contains IDs of the project resources
  • Enforces good software engineering
  • Use findViewById and Resources object to get access to the resources

  1. Ex. Button b = (Button)findViewById(
  2. Ex. getResources().getString(R.string.hello));


  • Eclipse has a great UI creator
  • Generates the XML for you
  • Composed of View objects
  • Can be specified for portrait and landscape mode


Anonymous said...

Effective tutorials...