public void paint(Graphics g) { // super.repaint(); pWidth = this.getWidth() - (inset.left + inset.right); pHeight = this.getHeight() - (inset.top + inset.bottom); top.setBounds(0, 0, pWidth, (int) (pHeight * (1.0f - graphVerticalSize))); nodeGraph.setBounds(0, 0, (int) (top.getWidth() * 0.8f) - 5, top.getHeight()); nodeGraphView.setBounds(0, 20, nodeGraph.getWidth(), nodeGraph.getHeight() - 20); nodeGraphView.getGraphLayout().setSize(nodeGraphView.getSize()); nodeGraphInform.setBounds( (int) (top.getWidth() * 0.8f), 20, (int) (top.getWidth() * 0.2f), top.getHeight() - 20); nodeGraphMap.setBounds(0, 0, nodeGraphInform.getWidth(), nodeGraphInform.getWidth()); nodeGraphMap .getGraphLayout() .setSize(new Dimension(nodeGraphInform.getWidth(), nodeGraphInform.getWidth())); nodeGraphProtocolView.setBounds( 0, nodeGraphMap.getHeight() + 5, nodeGraphInform.getWidth(), nodeGraphInform.getHeight() - nodeGraphMap.getHeight() - 5); /* Relaxer relaxer = nodeGraphView.getModel().getRelaxer(); if(relaxer != null) { relaxer.stop(); relaxer.prerelax(); relaxer.relax(); } */ trafficGraph.setBounds( 0, (int) (pHeight * (1.0f - graphVerticalSize)) + 10, pWidth, (int) (pHeight * graphVerticalSize)); trafficGraph.repaint(); graphVerticalSizeBt.setBounds(0, (int) (pHeight * (1.0f - graphVerticalSize)), pWidth, 10); graphVerticalSizeBt.repaint(); graphHorizontalSizeBt.setBounds((int) (top.getWidth() * 0.8f) - 5, 20, 5, top.getHeight()); graphHorizontalSizeBt.repaint(); }