Jcomponent divison
I want divide jcomponent into different parts
public TaskGraphComponent(ProjectFrame proFrame,TaskGraphModel model,TaskGraphPainter painter) {
this.proFrame = proFrame;
_painter = painter;
setLayout(new BorderLayout());
setModel(model);
_mouseHandler = new GraphMouseHandler(this);
_verticalScroll1 = new JScrollBar(JScrollBar.VERTICAL);
this.add(_verticalScroll1, BorderLayout.EAST);
_verticalScroll1.addAdjustmentListener(this);
_verticalScroll1.setVisible(true);
setBorder(BorderFactory.createEmptyBorder(0,0,15,0));
this.addMouseMotionListener(_mouseHandler);
this.addMouseListener(_mouseHandler);
this.addMouseWheelListener(_mouseHandler);
this.addKeyListener(_mouseHandler);
this.addComponentListener(this);
this.setFocusable(false);
this.setSize(10, 50);
ToolTipManager.sharedInstance().setDismissDelay(8000);
ToolTipManager.sharedInstance().setReshowDelay(3000);
}
Here TaskGraphComponent is jcomponent can i make into differnt parts vertically TaskGraphC开发者_运维知识库omponent is jcomponent uses Borderlayout.TaskgraphComponent wil show big screen . Actually task is i want to spilt this taskGraphComponent into parts
layout managers?
http://download.oracle.com/javase/tutorial/uiswing/layout/visual.html
精彩评论