Anybody has a clue about where (in the code) the splitter bar is painted?
2 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   bernard_poulin
Posted On:   Monday, March 26, 2001 01:55 PM

How do I remove the painting of the splitter of a JSplitPane?

Splitter bars will really look good the day this will be a standard feature:

I'm trying to understand where this painting really comes from. It's kinda difficult to follow what is going on here.

Anybody has a clue about where (in the code) the splitter bar is painted?

thanks a lot.

Bernard

Re: Anybody has a clue about where (in the code) the splitter bar is painted?

Posted By:   Scott_Stanchfield  
Posted On:   Wednesday, April 25, 2001 08:06 AM

Not sure what you're trying to do, but all painting of Swing components is done from the look and feel classes.

The look and feel could vary based on the user's or application's settings.

Take a look at javax.swing.plaf.SplitPaneUI and the various implementations like


  • com.sun.java.swing.plaf.windows.WindowsSplitPaneUI
  • com.sun.java.swing.plaf.motif.MotifSplitPaneUI
  • javax.swing.plaf.basic.BasicSplitPaneUI

Re: Anybody has a clue about where (in the code) the splitter bar is painted?

Posted By:   Sandip_Chitale  
Posted On:   Thursday, March 29, 2001 10:26 PM

javax/swing/plaf/basic/BasicSplitPaneDivider.java subclasses a container. Here is the class header comment

/**
* Divider used by BasicSplitPaneUI. Subclassers may wish to override
* paint to do something more interesting.
* The border effect is drawn in BasicSplitPaneUI, so if you don't like
* that border, reset it there.
* To conditionally drag from certain areas subclass mousePressed and
* call super when you wish the dragging to begin.
*



It is created by public BasicSplitPaneDivider createDefaultDivider() method of
javax.swing.plaf.basic.BasicSplitPaneUI
About | Sitemap | Contact