LWUIT 1.1 for Java ME Developers


LWUIT 1.1 for Java ME Developers
eBook: $26.99
Formats: PDF, PacktLib, ePub and Mobi formats
$22.94
save 15%!
Print + free eBook + free PacktLib access to the book: $71.98    Print cover: $44.99
$44.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Reviews
Support
Sample Chapters
  • Make your applications stand out with dazzling graphics that look and behave the same on different mobile devices
  • Log information on the runtime behavior of your program
  • Write applications with attractive visual effects like transitions and animations
  • Use localization so that your applications can adapt to different languages and locales

Book Details

Language : English
Paperback : 364 pages [ 235mm x 191mm ]
Release Date : August 2009
ISBN : 184719740X
ISBN 13 : 9781847197405
Author(s) : Biswajit Sarkar
Topics and Technologies : All Books, Application Development, Mobile, Java, Open Source

Back to BOOK PAGE

Table of Contents

Preface
Chapter 1: Introduction to LWUIT
Chapter 2: Components
Chapter 3: The Container Family
Chapter 4: The Label Family
Chapter 5: List and ComboBox
Chapter 6: TextArea and TextField
Chapter 7: Arranging Widgets with Layout Managers
Chapter 8: Creating a Custom Component
Chapter 9: Resources Class, Resource File and LWUIT Designer
Chapter 10: Using Themes
Chapter 11: Adding Animations and Transitions
Chapter 12: Painters
Chapter 13: Effects and Logging—Useful Utilities
Index
  • Chapter 1: Introduction to LWUIT
    • Why we need the LWUIT
    • LWUIT overview
    • Widgets
      • Container and Form
      • The TabbedPane
      • Calendar
      • Dialog
      • Label and Button
      • TextArea and TextField
      • List
      • ComboBox
    • The underlying support elements
      • Resource
      • Layout managers
      • Style
      • Painter
      • UIManager
      • LookAndFeel
    • Functionalities
      • Animations and transitions
      • Themes
      • Logging
    • The Basic architecture
    • LWUITImplementation—the foundation of LWUIT
    • The Display class
    • Summary
  • Chapter 2: Components
    • The LWUIT bundle
    • Getting equipped
    • Hello LWUIT!
      • Creating the project
      • The code
    • Deploying an application
    • The Component class
      • Methods to handle size and location
      • Methods for event handling
      • Methods for rendering
        • The painting process
      • Miscellaneous methods
      • Animation support for components
      • Handling Style
    • The Graphics class
    • Summary
  • Chapter 3: The Container Family
    • The Container
      • Creating a Container
      • The methods of the Container class
    • The form
      • Creating a form
      • Handling commands
      • The Command class
        • Creating a command
        • Methods of Command class
        • Installing a command
      • Managing the form's appearance
        • Setting the TitleBar's looks
      • The Font class
        • Creating a Font
        • The methods of the Font class
      • Installing a new font
        • Setting the MenuBar's looks
        • Setting the Form's Looks
    • The Dialog
      • Creating a Dialog
      • The methods of the Dialog class
      • Displaying a dialog
    • The Calendar
      • Creating a Calendar
      • Methods of Calendar class
      • Using a Calendar
    • The TabbedPane
      • Creating a TabbedPane
      • Methods of TabbedPane class
      • A TabbedPane in action
    • Style for the future
    • Summary
  • Chapter 4: The Label Family
    • The Border class
    • The Label
      • The LabelDemo example
      • Creating a Label
      • Methods of the Label class
      • The LabelDemo application
    • The Button class
      • Creating a Button
      • The methods of Button class
      • The DemoButton example
    • The CheckBox
      • Creating a CheckBox
      • Methods of the CheckBox class
      • The "Languages Known" example
    • The RadioButton and ButtonGroup
      • The ButtonGroup class
      • Creating a RadioButton
      • Methods of the RadioButton class
      • The "Reservation" Example
    • Summary
  • Chapter 5: List and ComboBox
    • The list
      • Creating a List
      • The methods of the List class
      • Setting up a basic list
      • A list with custom rendering
      • The ToDoList
    • The ComboBox
      • Creating a ComboBox
      • The methods of the ComboBox class
      • A combo box with the default renderer
      • A combo box with a custom renderer
    • Summary
  • Chapter 6: TextArea and TextField
    • The TextArea
      • Creating a TextArea
      • The methods of the TextArea class
      • Putting TextArea class through its paces
    • The TextField class
      • Creating a TextField
      • The methods of the TextField class
      • Checking out TextField
    • Summary
  • Chapter 8: Creating a Custom Component
    • The making of a component
      • The TimeViewer class
      • The TimeTeller class
        • The Real time mode
        • The ElapsedTime mode
      • The TimeTellerMIDlet
    • Enhancements
    • Summary
  • Chapter 9: Resources Class, Resource File and LWUIT Designer
    • The LWUIT Designer
      • Creating a resource file
        • Adding an image
        • Adding an animation
        • Adding a font
        • Adding a localization resource
        • Adding a Theme
      • Saving a resource file
    • The Resources class
    • The SampleResource demo
      • The manual approach
      • The automatic approach
    • Summary
  • Chapter 10: Using Themes
    • Working with theme files
      • Viewing a theme file
      • Editing a theme file
      • Populating a theme
    • Theming custom components
    • Manual styling versus theming
    • Theming on the fly
    • New version of the LWUIT Designer
    • Summary
  • Chapter 11: Adding Animations and Transitions
    • Animations
      • The Hello MIDlet
    • Transition
      • The Transition class
        • CommonTransitions
        • Transition3D
      • Using transitions
        • The DemoTransition application
      • Transition for components
    • Authoring transitions
      • The BlindsTransition class
      • The StepMotion class
      • The MIDlet
    • Summary
  • Chapter 12: Painters
    • The Painter interface
    • The DemoPainter application
    • Drawing a multi-layered background
      • The PainterChain class
      • The DemoPainterChain application
    • Using a glass pane
      • The DemoGlassPane application
      • A GlassPane with multiple layers
    • Summary
Back to BOOK PAGE

Biswajit Sarkar

Biswajit Sarkar is an electrical engineer with a specialization in Programmable Industrial Automation. He has had extensive experience across the entire spectrum of Industrial Automation – from hardware and firmware designing for general and special purpose Programmable Controllers to marketing and project management and also in leading a team of young and highly talented engineers engaged in product development (both hardware and software). He has been associated with a wide variety of automation projects including controls for special-purpose machines, blast furnace charge control, large air-pollution control systems, controls for cogeneration plants in sugar factories, supervisory control for small hydroelectric plants, turbine governors, and substation automation including associated SCADA.

Currently Biswajit consults on Industrial Automation and Java ME-based applications. He has written extensively for Java.net on Java Native Interface, Java ME and LWUIT. He has taught courses on mathematics and analytical reasoning at a number of leading institutes in India. Biswajit has also taught a specially designed course on Java for MS and Ph.D. students as well as post doctoral fellows at the Center for Coastal Physical Oceanography, Old Dominion University, Norfolk, Virginia (USA).

Biswajit, originally from Calcutta, now lives in Nashik, India with his wife.

Code Downloads

Download the code and support files for this book.


Submit Errata

Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


Errata

- 2 submitted: last submission 01 Jul 2013

Errata type: Others | Page number: 3 and 25

The link to download the LWUIT bundle is broken.  Given link is https://lwuit.dev.java.net/servlets/ProjectDocumentList , but this seems to be broken. You can download the LWUIT bundle from any of the following two links:

Errata type: Typo | Page number: 44 and 45

On page 44 of the book, in the fourth paragraph under the The painting process section, the word "DefaultLookAndeel" should be "DefaultLookAndFeel".

On page 45 of the book, in the fourth paragraph, the word "Border clss" should be "Border class".

Sample chapters

You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

Frequently bought together

LWUIT 1.1 for Java ME Developers +    Python Geospatial Development =
50% Off
the second eBook
Price for both: €30.90

Buy both these recommended eBooks together and get 50% off the cheapest eBook.

What you will learn from this book

  • Customize the way common components appear on screen for a unique look and feel
  • Add user interface elements to your applications and learn how to style them
  • Assemble sophisticated interfaces using containers, labels, and lists
  • Enhance the organization of your interface using layout managers
  • Add animations and transitions to your application
  • Create a theme to ensure visual coherence in your application
  • Use painters and painter chains for attractive backgrounds and superimposed patterns with components
  • Create resources with the LWUIT Designer
  • Build custom components by extending Component class Debug applications using the Log class

In Detail

Writing appealing cross-device applications today in Java ME is challenging as implementation differences in fonts, layout, and menus can make your application look and behave very differently on different devices. So far, the only way out has been low-level programming with its associated complexity.

The Lightweight UI Toolkit (LWUIT), an open source Java library, offers Java ME developers an easy-to-use API for creating impressive user interfaces with a device-independent look and feel. The LWUIT library contains many components and tools for bringing consistency and visual gloss to the user interface of your applications, and this book will take you through all of this, to help you get the user interfaces you want.

Java ME allows us to write applications that are, generally speaking, portable across a wide range of small devices that support the platform. While the basic functionalities usually work well on all supported devices, the area that does pose problems for developers is the User Interface. Native implementations of javax.microedition.lcdui – the primary API for UIs in Java ME – differ so widely from one device to another that maintaining a device-independent and uniform look and feel is virtually impossible. Another problem with the javax.microedition.lcdui package is that it does not support components and capabilities that can fully satisfy present day user expectations. The Lightweight UI Toolkit is the solution to these problems. LWUIT offers a wide range of components with a device-independent look and feel for building UIs. While some of these widgets are also available under lcdui, there are a number of new ones too. These additions enable application developers to design UIs that can come very close to their desktop counterparts in terms of visual sophistication and LWUIT is not just about new components either. The API supports a whole range of new functionalities (like Theming and Transitions) too.

This book takes Java ME developers through the library, with examples showing how to use the main components and functionalities. It also goes beyond a description of what is available by showing how to extend the library by plugging in custom-built classes.

Build captivating and device-independent UI screens using the LWUIT library

Approach

This book presents LWUIT through an optimum mix of theory and practice. Classes are described and their applications are demonstrated through a large number of examples. Example code is thoroughly analyzed and many screenshots are included to show what happens when the code is executed. Custom classes are built progressively with a thorough explanation of each step. The book also presents the underlying structural features of LWUIT that are important for skillful use of the API

Who this book is for

This book is for Java ME developers who want to create compelling user interfaces for Java ME applications, and want to use LWUIT to make this happen

Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software