Last change
on this file since 46 was
5,
checked in by zeiss, 14 years ago
|
|
-
Property svn:mime-type set to
text/plain
|
File size:
912 bytes
|
Rev | Line | |
---|
[5] | 1 | package de.ugoe.cs.swe.bnftools.ui.views.syntaxdiagram;
|
---|
| 2 |
|
---|
| 3 | import org.eclipse.draw2d.ToolbarLayout;
|
---|
| 4 |
|
---|
| 5 | public class OptionRepetitionFigure extends SyntaxDiagramFigure {
|
---|
| 6 |
|
---|
| 7 | public OptionRepetitionFigure(SyntaxDiagramFigure f) {
|
---|
| 8 | super();
|
---|
| 9 |
|
---|
| 10 | setLayoutManager(new ToolbarLayout());
|
---|
| 11 |
|
---|
| 12 | RepetitionFigure repetition = new RepetitionFigure(f);
|
---|
| 13 | OptionFigure optional = new OptionFigure(repetition);
|
---|
| 14 |
|
---|
| 15 | add(optional);
|
---|
| 16 |
|
---|
| 17 | PathFigure leftConnectionPath = new PathFigure();
|
---|
| 18 | leftConnectionPath.setSourceAnchor(this.getLeftAnchor());
|
---|
| 19 | leftConnectionPath.setTargetAnchor(optional.getLeftAnchor());
|
---|
| 20 | add(leftConnectionPath);
|
---|
| 21 |
|
---|
| 22 | PathFigure rightConnectionPath = new PathFigure();
|
---|
| 23 | rightConnectionPath.setSourceAnchor(optional.getRightAnchor());
|
---|
| 24 | rightConnectionPath.setTargetAnchor(this.getRightAnchor());
|
---|
| 25 | add(rightConnectionPath);
|
---|
| 26 |
|
---|
| 27 | setBorder(new LineMarginBorder(10, 40, 10, 40, 0));
|
---|
| 28 | }
|
---|
| 29 |
|
---|
| 30 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.