This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes Make JScrollBar blink Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Make JScrollBar blink" Watch "Make JScrollBar blink" New topic
Author

Make JScrollBar blink

ashish kulkarni
Ranch Hand

Joined: Aug 15, 2002
Posts: 130
Hi,
i want to make my JScrollBar blink, how can i make it
any code for doing it


A$HI$H
Nathan Pruett
Bartender

Joined: Oct 18, 2000
Posts: 4121

Here's an example...



Making the knob blink instead of the background poses a problem. The JScrollBar class doesn't let you access any attributes of the knob, so you can't change them. You could change the color of the knob through UIManager, but that would change the color of every knob on every scrollbar in the whole application. So if you wanted to do this, you would completely have to rewrite the JScrollBar class to allow you to set the color of the scrollbar knob.


-Nate
Write once, run anywhere, because there's nowhere to hide! - /. A.C.
 
Don't get me started about those stupid light bulbs.
 
subject: Make JScrollBar blink
 
Similar Threads
blink minimized window
SpinEdit
Minimized task bar blinking
detecting eye blink with the help of java
Programmatically set the knob position of a JScrollBar