Package org.eclipse.draw2d

Examples of org.eclipse.draw2d.Label


  /**
   * @generated
   */
  protected IFigure createSelectionFeedbackFigure() {
    if (getHostFigure() instanceof Label) {
      Label feedbackFigure = new Label();
      feedbackFigure.setOpaque(true);
      feedbackFigure
          .setBackgroundColor(ColorConstants.menuBackgroundSelected);
      feedbackFigure
          .setForegroundColor(ColorConstants.menuForegroundSelected);
      return feedbackFigure;
    } else {
      RectangleFigure feedbackFigure = new RectangleFigure();
      feedbackFigure.setFill(false);
      return feedbackFigure;
    }
  }
View Full Code Here


  /**
   * @generated
   */
  protected void updateLabel(Label target) {
    Label source = (Label) getHostFigure();
    target.setText(source.getText());
    target.setTextAlignment(source.getTextAlignment());
    target.setFont(source.getFont());
  }
View Full Code Here

  /**
   * @generated
   */
  protected IFigure createSelectionFeedbackFigure() {
    if (getHostFigure() instanceof Label) {
      Label feedbackFigure = new Label();
      feedbackFigure.setOpaque(true);
      feedbackFigure
          .setBackgroundColor(ColorConstants.menuBackgroundSelected);
      feedbackFigure
          .setForegroundColor(ColorConstants.menuForegroundSelected);
      return feedbackFigure;
    } else {
      RectangleFigure feedbackFigure = new RectangleFigure();
      feedbackFigure.setFill(false);
      return feedbackFigure;
    }
  }
View Full Code Here

  /**
   * @generated
   */
  protected void updateLabel(Label target) {
    Label source = (Label) getHostFigure();
    target.setText(source.getText());
    target.setTextAlignment(source.getTextAlignment());
    target.setFont(source.getFont());
  }
View Full Code Here

  /**
   * @generated
   */
  protected IFigure createSelectionFeedbackFigure() {
    if (getHostFigure() instanceof Label) {
      Label feedbackFigure = new Label();
      feedbackFigure.setOpaque(true);
      feedbackFigure
          .setBackgroundColor(ColorConstants.menuBackgroundSelected);
      feedbackFigure
          .setForegroundColor(ColorConstants.menuForegroundSelected);
      return feedbackFigure;
    } else {
      RectangleFigure feedbackFigure = new RectangleFigure();
      feedbackFigure.setFill(false);
      return feedbackFigure;
    }
  }
View Full Code Here

  /**
   * @generated
   */
  protected void updateLabel(Label target) {
    Label source = (Label) getHostFigure();
    target.setText(source.getText());
    target.setTextAlignment(source.getTextAlignment());
    target.setFont(source.getFont());
  }
View Full Code Here

  public EventFigure(String name, long end, long start) {

    this.layout = new ToolbarLayout();
    setLayoutManager(this.layout);
    Label nameLabel = new Label();
    nameLabel.setText(name);
    setBackgroundColor(ColorConstants.lightGray);
    add(nameLabel);

    LineBorder border = new LineBorder(ColorConstants.gray);
    setBorder(border);
    setOpaque(true);

    setToolTip(new Label(" " + name + " " + "\n Start: "
        + TimeUtils.formatToTime(start) + "\n End  : "
        + TimeUtils.formatToTime(end) + " "));
  }
View Full Code Here

public class PunctualEventFigure extends Ellipse {

  public PunctualEventFigure(String name, long begin) {
    setOpaque(true);
    setToolTip(new Label(" " + name + "\n Start: "
        + TimeUtils.formatToTime(begin) + " "));
  }
View Full Code Here

    PointList points = new PointList();
    points.addPoint(start);
    points.addPoint(end);
    this.setPoints(points);

    Label labels[] = new Label[numSegments];
    for (int i = 0; i < numSegments; i++) {
      String lbl = ((i) * (((during)/numSegments))/1000) + "";
      labels[i] = new Label(lbl);
      labels[i].setForegroundColor(ColorConstants.black);
      contents.add(labels[i]);
      int xPos = labelPositions[i];
      int yPos = (int) ySpan;
      int width = 30;
View Full Code Here

    PointList points = new PointList();
    points.addPoint(start);
    points.addPoint(end);
    this.setPoints(points);

    Label labels[] = new Label[numSegments];
    for (int i = 0; i < numSegments; i++) {
      labels[i] = new Label(series[i]);
      labels[i].setForegroundColor(ColorConstants.black);
      contents.add(labels[i]);
      int width = 60;
      int height = 15;
      int xPos = xOffset - width;
View Full Code Here

TOP

Related Classes of org.eclipse.draw2d.Label

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.