> Is there a better option available to display, say, 4/5 rows of
> textual
> data on top of a background image?
> I guess I could use a Canvas and drawString at a co-ordinate but that
> sounds messy.
I guess the canvas is the only option, if you must have the
background image. But it probably is not as messy as you might think.
An alert would also work, but this is not quite what you want. But
it lets you display a little bit of text with an image (I think the
image will be above the text .. not sure tho).
> .. for the gauage, yes it takes some time to return ... which is why I
> wanted a progress bar ... is there any way to force a refresh? Or is
> there another approach? Surely a progress gauage was designed for such
> scenarios?
Yes, but I have never used progress bars .. A wild guess would be to
call Thread.yield (); or maybe Thread.sleep (10); to give control to the
JVM .. maybe then it will display the progress bar thing. Worth a try.
hth

Signature
jb
(reply address in rot13, unscramble first)
Chris Smith - 28 Jul 2005 17:23 GMT
> Yes, but I have never used progress bars .. A wild guess would be to
> call Thread.yield (); or maybe Thread.sleep (10); to give control to the
> JVM .. maybe then it will display the progress bar thing. Worth a try.
Actually, it's not. An important thing to remember in J2ME is that
implementations are given a lot more flexibility than in J2SE. Unless
your goal is for your application to only work on one specific phone,
it's NOT good enough to program by trial and error. It is necessary to
understand the specification and its guarantees and contracts, so that
you avoid the pitfalls of writing code that works fine in the emulator
or in your specific mobile device that you're using for testing, but
doesn't work anywhere else.

Signature
www.designacourse.com
The Easiest Way To Train Anyone... Anywhere.
Chris Smith - Lead Software Developer/Technical Trainer
MindIQ Corporation
> Is there a better option available to display, say, 4/5 rows of textual
> data on top of a background image?
> I guess I could use a Canvas and drawString at a co-ordinate but that
> sounds messy.
First you should convince yourself that you really need a background
image. If you do, then Canvas is the way to go.
> .. for the gauage, yes it takes some time to return ... which is why I
> wanted a progress bar ... is there any way to force a refresh? Or is
> there another approach? Surely a progress gauage was designed for such
> scenarios?
Yes, the progress bar is designed for such scenarios... but you can't do
them in the thread that's used to call event handlers. J2ME doesn't
actually guarantee that this will break, unlike J2SE's AWT which is
quite explicit about the matter. Still, it doesn't guarantee that this
will work either. Instead, you should try starting a new Thread to do
the long work and update the Gauge occasionally.

Signature
www.designacourse.com
The Easiest Way To Train Anyone... Anywhere.
Chris Smith - Lead Software Developer/Technical Trainer
MindIQ Corporation