Skip to main content


2 replies [Last post]
Joined: 2008-06-10

Hello there,

First of all, great work on the toolkit.

I already have an application developed on lcdui, and now I am trying to port it over to LWUIT.
In my lcdui.Form , I could do form.append(progressGauge)
But I noticed that in LWUIT, there is no Gauge widget! The gauge is a central part of my app and I need to add it to my LWUIT form... please provide some suggestions.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2003-11-07

Hi Nafs,
are you looking for a Gauge as a progress indicator or for an editable Gauge?

If the former then I wrote a simple progress indicator implementation in the blog:

If the latter you can probably start from my example, make it focusable and then handle key events appropriately.


Joined: 2008-06-10

yes I was looking for a progress indicator type Gauge

anyway, I re-wrote your Gauge a little to use lcdui's setValue() instead, so this is what width calculation in paint() looks like:

int clippedWidth = (int)((currentVal / maxValue) * getWidth());

this way i dont have to change my old lcdui code which uses Gauge
It works... all good. thanks.