• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Android User Interface Development - Is it easier/ harder than Blackberry UI development?

 
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Android User Interface Development - Is it easier/ harder than Blackberry UI development? How close are the libraries to regular java swing libraries? What prior knowledge does the book assume?
 
author
Posts: 13
Android Google Web Toolkit Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi there Henry,

I wouldn't say that Android UI development is easier or harder than any other type of UI development, it's just different. It doesn't have much in common with the Swing API, but in some ways can be seen to share more with the Google Web Toolkit (although even this comparison is not very good).

Android is expected to run on a wide range of devices with limited functionality, and so the same user interface layout won't look great across all of the device variations. Android solves this problem by encouraging (though not forcing) you to declare the layout and styles of your user interface in an XML file which is processed when your application is packaged (a normal part of your Android build process). When you ask it to load the "main" screen layout, the resource loading API will find the XML file that best matches the current device configuration.

As a common example, you want a screen to appear one way when the device is held in a portrait orientation, and a different layout if it's held in a landscape orientation. If this screen layout is named "edit" you would have a resource directory with the following entries:

/res/layout/edit.xml
/res/layout-land/edit.xml

It's a very simple mechanism, and works for many other types of resources (text, images, etc.). More information about how resources are loaded and handled can be found in the official Android documentation.

Finally: your question about what prior knowledge the book assumes. The book is a beginners guide, and so tries to assume as little prior knowledge as possible. The only thing the book expects of the reader is a reasonable grasp of the Java language.

Thanks for the question.
 
Henry Naf.
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you Jason for the very detailed reply!
reply
    Bookmark Topic Watch Topic
  • New Topic