Search in sources :

Example 1 with LineLayout

use of org.eclipse.gemoc.timeline.layout.LineLayout in project gemoc-studio by eclipse.

the class TimelineWindowEditPart method createFigure.

@Override
protected IFigure createFigure() {
    final LineLayout layout = new LineLayout();
    layout.setHorizontal(false);
    layout.setMajorAlignment(FlowLayout.ALIGN_TOPLEFT);
    layout.setMinorAlignment(FlowLayout.ALIGN_TOPLEFT);
    layout.setMinorSpacing(SPACING);
    layout.setMargin(MARGIN);
    FreeformLayer res = new FreeformLayer();
    res.setLayoutManager(layout);
    return res;
}
Also used : LineLayout(org.eclipse.gemoc.timeline.layout.LineLayout) FreeformLayer(org.eclipse.draw2d.FreeformLayer)

Example 2 with LineLayout

use of org.eclipse.gemoc.timeline.layout.LineLayout in project gemoc-studio by eclipse.

the class BranchEditPart method createFigure.

@Override
protected IFigure createFigure() {
    final LineLayout layout = new LineLayout();
    layout.setHorizontal(true);
    layout.setMajorAlignment(FlowLayout.ALIGN_TOPLEFT);
    layout.setMinorAlignment(FlowLayout.ALIGN_BOTTOMRIGHT);
    layout.setMinorSpacing(SPACING);
    layout.setMargin(MARGIN);
    FreeformLayer res = new FreeformLayer();
    final Label toolTip = new Label();
    toolTip.setFont(JFaceResources.getFont(JFaceResources.TEXT_FONT));
    toolTip.setBackgroundColor(ColorConstants.tooltipBackground);
    toolTip.setForegroundColor(ColorConstants.tooltipForeground);
    toolTip.setText(getModel().getTimelineWindow().getProvider().getTextAt(getModel().getBranch()));
    res.setToolTip(toolTip);
    res.setLayoutManager(layout);
    return res;
}
Also used : Label(org.eclipse.draw2d.Label) LineLayout(org.eclipse.gemoc.timeline.layout.LineLayout) FreeformLayer(org.eclipse.draw2d.FreeformLayer)

Example 3 with LineLayout

use of org.eclipse.gemoc.timeline.layout.LineLayout in project gemoc-studio by eclipse.

the class ChoiceEditPart method createFigure.

@Override
protected IFigure createFigure() {
    final LineLayout layout = new LineLayout();
    layout.setHorizontal(false);
    layout.setMajorAlignment(FlowLayout.ALIGN_TOPLEFT);
    layout.setMinorAlignment(FlowLayout.ALIGN_TOPLEFT);
    layout.setMinorSpacing(SPACING);
    FreeformLayer res = new FreeformLayer();
    res.setLayoutManager(layout);
    label = new Label();
    res.add(label);
    return res;
}
Also used : Label(org.eclipse.draw2d.Label) LineLayout(org.eclipse.gemoc.timeline.layout.LineLayout) FreeformLayer(org.eclipse.draw2d.FreeformLayer)

Aggregations

FreeformLayer (org.eclipse.draw2d.FreeformLayer)3 LineLayout (org.eclipse.gemoc.timeline.layout.LineLayout)3 Label (org.eclipse.draw2d.Label)2