List of usage examples for javax.swing JComponent doLayout
public void doLayout()
From source file:com.projity.pm.graphic.network.NetworkRenderer.java
public void paintNode(Graphics2D g, GraphicNode node) { Rectangle bounds = getBounds(node); if (isEditing(node)) { editor.paintEditor(node);//from w w w. j a va 2s . c o m } else { JComponent c = renderer.getRendererComponent(node, ((NetworkParams) graphInfo).getZoom()); if (container == null) { //c=new JLabel("test"); c.setDoubleBuffered(false); c.setOpaque(false); c.setForeground(Color.BLACK); c.setSize(bounds.width, bounds.height); g.translate(bounds.x, bounds.y); c.doLayout(); c.print(g); g.translate(-bounds.x, -bounds.y); } else rendererPane.paintComponent(g, c, container, bounds.x, bounds.y, bounds.width, bounds.height, true); } }