0

We are using LCDUI for our j2me application and I want to change my form size to minimize for looks like popup window. But I can't resize the form.

But we have one method in form class setSize(Dimension d); But there is no use.

I suspect there is no way to change the LCDUI form size.

Please Enlighten me on this...

and also is there any way to change form size in LWUIT?

gnat
  • 6,213
  • 108
  • 53
  • 73
Saravanan
  • 11,372
  • 43
  • 143
  • 213

1 Answers1

3

Form's size cannot be changed ! If you don't need to place Components inside it then I suggest you to use Canvas so that you can , in this situation , simulate size change by painting for example a Rectangle with the appropriate Dimension.

Mun0n
  • 4,438
  • 4
  • 28
  • 46
pheromix
  • 18,213
  • 29
  • 88
  • 158
  • 3
    In LWUIT you can show a dialog with any size using the show method that accepts 4 integers. Since a dialog derives from Form you get the same effect. – Shai Almog Jan 26 '12 at 12:07
  • @ShaiAlmog:I want to close the dialog when pressing particular key.But i could not able to make that...is there any way for that? – Saravanan Jan 26 '12 at 15:24
  • Derive dialog and override keyreleased or add a listener to the Dialog for key release event. Notice that lines of code AFTER the show() method will not execute until the dialog is disposed unless you make the dialog modless. – Shai Almog Jan 26 '12 at 19:56