Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JFrames  RSS feed

 
Hatem Hassanein
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need a way to get the position of a JFrame, move it a certain direction and then back a few times to create a "shaking" affect. I have no idea on how to do this, and I would greatly appreciate it if someone explained how this could be achieved.
- Hatem
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to JavaRanch!
Do you mean something annoying like this:Take a good look at the JFrame class documentation for the methods available to JFrames.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How annoying. I have seen some web pages that do that and it drives me nuts.
 
Hatem Hassanein
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks! Btw, I'm making a Chat Client and server and I thought it would be a good idea to have a buzz feature like in Yahoo Instant Messenger.
 
John Smith
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just some advice: make sure this "buzz" feature turns off rather quickly. Items that vibrate on the screen are extremely distracting and most people find it hard to concentrate when this type of thing is going on. Have you ever seen those banner ads that vibrate? I always scroll the article I'm trying to read down just enough to hide them...
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!