Package org.eclipse.draw2d

Examples of org.eclipse.draw2d.Layer


    return highlight;
  }

  public Layer getHandleLayer()
  {
    Layer handle = (Layer) ((ChsScalableRootEditPart) getViewer().getRootEditPart()).
      getLayer(LayerConstants.HANDLE_LAYER);

    return handle;
  }
View Full Code Here


    return highlight;
  }

  public Layer getHandleLayer()
  {
    Layer handle = (Layer) ((ChsScalableRootEditPart) getViewer().getRootEditPart()).
      getLayer(LayerConstants.HANDLE_LAYER);

    return handle;
  }
View Full Code Here

    return highlight;
  }

  public Layer getHandleLayer()
  {
    Layer handle = (Layer) ((ChsScalableRootEditPart) getViewer().getRootEditPart()).
      getLayer(LayerConstants.HANDLE_LAYER);

    return handle;
  }
View Full Code Here

  protected org.eclipse.draw2d.LayeredPane createPrintableLayers() {
    final LayeredPane tmp = super.createPrintableLayers();
    // tmp.setPreferredSize(1800, 1800);
    int z = 0;
    for (final String l : MapEditor.LAYERS) {
      final Layer layer = new Layer();
      layer.setLayoutManager(new XYLayout());
      final Label lab = new Label(l);
      lab.setLocation(new Point(10, 10 + z * 20));
      lab.setSize(100, 20);
      layer.add(lab);
      tmp.add(layer, l, 0);
      z++;
    }
    return tmp;
  }
View Full Code Here

   * @return the created figure.
   */
 
  public IFigure createFigure(IFigure figure) {
    LayeredPane pane = new LayeredPane();
    Layer layer = new Layer();
    if (figureLayout == null) {
        if (fillParent) {
            figureLayout = new FillParentLayout();
        } else {
        figureLayout = new AlignedFlowLayout() {
         
          @Override
          protected void setBoundsOfChild(IFigure parent,  IFigure child,  Rectangle bounds) {
            parent.getClientArea(Rectangle.SINGLETON);
            bounds.translate(Rectangle.SINGLETON.x, Rectangle.SINGLETON.y);
            if (resizeChildren)
              child.setBounds(bounds);
            else
              child.setLocation(bounds.getLocation());
          }
        };
        }
    }
    layer.setLayoutManager(figureLayout);
    pane.add(layer);
    layer.add(figure);
    if (decorationLayer == null) {
      decorationLayer = new Layer();
    }
    decorationLayer.setLayoutManager(decorationLayout);
   
    pane.add(decorationLayer);
   
View Full Code Here

        ScrollPane scrollpane = new ScrollPane();
        pane = new FreeformLayer();
        pane.setLayoutManager(new FreeformLayout());
        setLayoutManager(new StackLayout());
        add(scrollpane);
        IFigure panel = new Layer();
        FlowLayout flowLayout = new FlowLayout();
        flowLayout.setMajorAlignment(FlowLayout.ALIGN_CENTER);
        panel.setLayoutManager(flowLayout);
        panel.add(label);
        add(panel);
        scrollpane.setViewport(new FreeformViewport());
        scrollpane.setContents(pane);
    }
View Full Code Here

TOP

Related Classes of org.eclipse.draw2d.Layer

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.