Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

special effects for cardlayout of pictures?

 
Ana Suvari
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I'm new to this forum and Java. Sorry i forgot to say on my first post. But i am also wondering why they use my real name and not login id?

Anyhow, I have a cardlayout of pictures in Java and i am wondering if i could code some way for each slide to move in slowly from left to right, top to bottom, or have each slide fade in/out or have each text word to appear one at a time. All i am describing is capable in MS Powerpoint. I am wondering if i can do the same in Java? I know sure what possible. If it's possible because you tried it, can you offer some tips on what i should be reading?

I know i would need timers but that's about it. I am not sure if i can manipulate the slides like this.
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the left to right and top to bottom could be done via drawing the images in a component's paintComponent(),
specifying the x,y as negative values initially then adding a bit each time to x,y (in a timer) and calling repaint().

don't know that you'd need a cardLayout for this, perhaps just a JPanel or JLabel
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But i am also wondering why they use my real name and not login id?

Welcome to our friendly forum ! Names are used as display names. You can read about this policy here, and here.
 
salvin francis
Bartender
Posts: 1268
10
Eclipse IDE Google Web Toolkit Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A card layout was made to display one component at a time,
it was not made from the point of view of animations.

If you do want such a feature, you would have to do it yourself, and yes, using the CardLayout itself in this situation is a bad idea unless you want
to delegate the animation to a proxy object and use the CardLayout at the end of each transition.
 
Rob Spoor
Sheriff
Pie
Posts: 20511
54
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Perhaps JGoodies Animation can help you out.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic