Search in sources :

Example 46 with Label

use of org.eclipse.draw2d.Label in project tdi-studio-se by Talend.

the class XmlMapSearchZoneToolBar method createZoneContent.

@Override
public void createZoneContent() {
    super.createZoneContent();
    Label findLabel = new Label("Find :");
    add(findLabel);
    searchText = new VarNodeTextLabel();
    searchText.setDirectEditType(DirectEditType.SERACH);
    // searchText.setText("Enter search text prefix or pattern(*,?)");
    searchText.setLabelAlignment(PositionConstants.LEFT);
    searchText.setBorder(new LineBorder(ColorConstants.gray));
    searchText.setOpaque(true);
    searchText.setBackgroundColor(ColorConstants.white);
    add(searchText);
    this.add(move_down);
    this.add(move_up);
    this.add(hightLightAll);
    move_down.setEnabled(true);
    move_up.setEnabled(true);
}
Also used : VarNodeTextLabel(org.talend.designer.gefabstractmap.figures.VarNodeTextLabel) LineBorder(org.eclipse.draw2d.LineBorder) VarNodeTextLabel(org.talend.designer.gefabstractmap.figures.VarNodeTextLabel) Label(org.eclipse.draw2d.Label)

Example 47 with Label

use of org.eclipse.draw2d.Label in project tdi-studio-se by Talend.

the class TreeBranchContent method createContent.

protected void createContent() {
    GridLayout manager = new GridLayout(4, false);
    manager.horizontalSpacing = 5;
    manager.verticalSpacing = 1;
    manager.marginHeight = -1;
    manager.marginWidth = 5;
    setLayoutManager(manager);
    nameFigure = new Label();
    nameFigure.setText(getNameValue());
    this.add(nameFigure);
}
Also used : GridLayout(org.eclipse.draw2d.GridLayout) Label(org.eclipse.draw2d.Label)

Example 48 with Label

use of org.eclipse.draw2d.Label in project tdi-studio-se by Talend.

the class AbstractTableContainer method createContents.

protected void createContents() {
    setLayoutManager(new TableContainerLayout(tableModelManager));
    this.setBorder(new LineBorder(ColorProviderMapper.getColor(ColorInfo.COLOR_TREE_BORDER)));
    header = new Figure();
    header.setOpaque(true);
    header.setBackgroundColor(ColorConstants.tooltipBackground);
    header.setBorder(new RowBorder());
    header.setLayoutManager(new EqualWidthLayout());
    Label tableName = new Label();
    // tableName.setBorder(new LineBorder(ColorConstants.black));
    tableName.setText(getTreeDisplayName());
    tableName.setFont(FontProviderMapper.getFont(FontInfo.FONT_SYSTEM_BOLD));
    tableName.setLabelAlignment(PositionConstants.LEFT);
    tableName.setBorder(new MarginBorder(5, 10, 5, -1));
    header.add(tableName);
    toolBarContainer = createToolBarContainer();
    header.setOpaque(true);
    header.setBackgroundColor(ColorProviderMapper.getColor(ColorInfo.ZONE_BACKGROUND_COLOR));
    this.add(header);
    if (toolBarContainer != null) {
        header.add(toolBarContainer);
    }
    createTreeSettings(this);
    if (withScroll) {
        ScrollPane scroll = new ScrollPane();
        scroll.setVerticalScrollBarVisibility(ScrollPane.NEVER);
        scroll.getViewport().setContents(createTable());
        scroll.getViewport().setContentsTracksWidth(true);
        // ///
        scroll.setBackgroundColor(ColorConstants.white);
        scroll.setOpaque(true);
        this.add(scroll);
    } else {
        this.add(createTable());
    }
}
Also used : RowBorder(org.talend.designer.gefabstractmap.figures.borders.RowBorder) ScrollPane(org.eclipse.draw2d.ScrollPane) LineBorder(org.eclipse.draw2d.LineBorder) MarginBorder(org.eclipse.draw2d.MarginBorder) Label(org.eclipse.draw2d.Label) TableContainerLayout(org.talend.designer.gefabstractmap.figures.layout.TableContainerLayout) EqualWidthLayout(org.talend.designer.gefabstractmap.figures.layout.EqualWidthLayout) IFigure(org.eclipse.draw2d.IFigure) GenericFigure(org.talend.designer.gefabstractmap.figures.GenericFigure) Figure(org.eclipse.draw2d.Figure)

Example 49 with Label

use of org.eclipse.draw2d.Label in project tdi-studio-se by Talend.

the class ToolBarContainer method setTooltips.

protected void setTooltips(Figure figure, String text) {
    Label tooltip = new Label();
    tooltip.setText(text);
    figure.setToolTip(tooltip);
}
Also used : Label(org.eclipse.draw2d.Label)

Example 50 with Label

use of org.eclipse.draw2d.Label in project tdi-studio-se by Talend.

the class InputZoneToolBar method createZoneContent.

@Override
public void createZoneContent() {
    super.createZoneContent();
    this.add(move_up);
    this.add(move_down);
    Label figure = new Label("");
    figure.setOpaque(true);
    figure.setBackgroundColor(ColorConstants.lightGray);
    add(figure);
    // disable for 5.0.0
    // propertyButton = new PropertyButton();
    // add(propertyButton);
    this.add(min_size);
    setTooltips();
}
Also used : Label(org.eclipse.draw2d.Label)

Aggregations

Label (org.eclipse.draw2d.Label)56 IFigure (org.eclipse.draw2d.IFigure)8 Rectangle (org.eclipse.draw2d.geometry.Rectangle)8 Point (org.eclipse.draw2d.geometry.Point)7 LineBorder (org.eclipse.draw2d.LineBorder)6 WrapLabel (org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel)6 Image (org.eclipse.swt.graphics.Image)6 MouseEvent (org.eclipse.draw2d.MouseEvent)5 MouseListener (org.eclipse.draw2d.MouseListener)5 ArrayList (java.util.ArrayList)4 List (java.util.List)4 Figure (org.eclipse.draw2d.Figure)4 RectangleFigure (org.eclipse.draw2d.RectangleFigure)4 Dimension (org.eclipse.draw2d.geometry.Dimension)4 PolylineConnection (org.eclipse.draw2d.PolylineConnection)3 ToolbarLayout (org.eclipse.draw2d.ToolbarLayout)3 EImage (org.talend.commons.ui.runtime.image.EImage)3 ComboCellLabel (org.talend.designer.gefabstractmap.figures.ComboCellLabel)3 RowBorder (org.talend.designer.gefabstractmap.figures.borders.RowBorder)3 CompoundBorder (org.eclipse.draw2d.CompoundBorder)2