[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.tools.gef] Problems with moving Label/Figure in Connection

Hi , all..
I have created a connection between two figures. What can i do to move the label along the conn in "every certain distance"?


Here is portion of the code:

PolylineConnection conn = new PolylineConnection();
ChopboxAnchor sourceAnchor = new ChopboxAnchor(nodeFigure1); ChopboxAnchor targetAnchor = new ChopboxAnchor(nodeFigure2);
conn.setSourceAnchor(sourceAnchor);
conn.setTargetAnchor(targetAnchor);


Label label = new Label(" ");
label.setOpaque(true);
label.setBackgroundColor(ColorConstants.blue);
label.setVisible(true);
// just display the label located at source
conn.add(label, new ConnectionLocator(conn,2));


Thanks in advance....