Click here to Skip to main content
11,495,716 members (51,348 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Java J2ME
I am working on J2ME Aplication using LWUIT.Now i have to create a form having four image buttons in 2x2 matrix.That i did using GridLayout but how to resize the image Buttons according to the Screen size of Mobile using LWUIT toolkit?Also i want to know how to use the concept of Tooltip in J2ME as it is not available in J2ME?
Posted 22-Oct-12 1:54am
AkshiD444

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

make it relative: get the screen resolution and make up the buttons size according to that.

// logic code - not usable!
ScreenWidth wide = 200;
button.setSize((int)(wide*0.2), (int)(wide*0.2)); // cast the double to int | Button will be 20% of screen width
  Permalink  
Comments
Akanksha Raina at 23-Oct-12 3:11am
   
thnx.Will you please tell me how to use Tooltip in case of J2ME as it is not directly available in J2ME.So,how to use this?
TorstenH. at 23-Oct-12 5:00am
   
No sorry, J2ME is not my thingy.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Dnyaneshwar@Pune 692
1 CHill60 318
2 Sascha Lefèvre 275
3 Nakul Chaudhari 236
4 RyanDev 220
0 Sergey Alexandrovich Kryukov 10,362
1 OriginalGriff 8,821
2 Sascha Lefèvre 3,899
3 Maciej Los 3,422
4 Richard Deeming 2,600


Advertise | Privacy | Mobile
Web01 | 2.8.150520.1 | Last Updated 22 Oct 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100