• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Horizantal image scroll in J2ME form

 
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Friends,

I have been trying to figure out if J2ME javax.microedition.lcdui.Form allows for horizontal scrolling.

When form items are added to this form, and they exceed the form area, the vertical scrollbar appears automatically. This is not the case however when an ImageItem wider than the form is placed onto it. That is, if say the form on a Nokia mobile with a screen of 125x100 takes precisely those dimensions, and an ImageItem of 200x200 is placed on it. Vertical scrolling appears automatically, but not the horizontal.

I tried with resizing the image using the code snippet attached in this url.

Image zooming.

However the reduced size of the image makes it very hazy and unusuable thu si had to discard this option.
Now I desperately need to find a way to get the horizantal scroll work.

I know it can be done using Canvas class , but then my entire code will also change so please help me out with its implementation in a Form.

Thanks,
 
Ranch Hand
Posts: 68
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This link might help
http://www.experts-exchange.com/Programming/Languages/Java/Q_20840864.html
(You must register to view the code. I could paste it here if you have problem with login)
 
Dushyant Chhetri
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Aleksandar,

I tried the link below but as you mentioned I could not log in ti view the solution.

It would be very helpful if you would paste the code out here.

Thanks in advance..
 
Aleksandar Babic
Ranch Hand
Posts: 68
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Here it is!

 
Dushyant Chhetri
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Aleksandar Babic.
It is working just the way I wanted it.
 
Aleksandar Babic
Ranch Hand
Posts: 68
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Great! You're welcome
 
reply
    Bookmark Topic Watch Topic
  • New Topic