Examples of Rectangle


Examples of org.eclipse.sapphire.ui.Rectangle

   * Creates a new {@link ContextButtonPadData}.
   */
  public ContextButtonPadData() {
    this.topContextButtons = new ArrayList<SapphireAction>();
    this.rightContextButtons = new ArrayList<SapphireAction>();
    this.location = new Rectangle(0, 0, 0, 0);
  }
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

  public void handleEvent(Event event) {
    final Point pt = new Point(event.x, event.y);
    final TableItem item = _viewer.getTable().getItem(pt);   
    if (item != null) {
      for (int column = 0; column < _viewer.getTable().getColumnCount(); column++) {
        Rectangle rect = item.getBounds(column);
        if (rect.contains(pt)) {
          _doubleClick = true;
          _viewer.editElement(item.getData(), column);
          _doubleClick = false;
          return;
        }
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

    this.display = mainShell.getDisplay();
    minimized = ShellFactory.createShell(mainShell, SWT.ON_TOP);
    minimized.setText("Vuze"); //$NON-NLS-1$
    label = new Label(minimized, SWT.NULL);
    ImageLoader.getInstance().setLabelImage(label, "tray");
    final Rectangle bounds = label.getImage().getBounds();
    label.setSize(bounds.width, bounds.height);
    minimized.setSize(bounds.width + 2, bounds.height + 2);
    screen = display.getClientArea();
//NICO handle macosx and multiple monitors
    if (!Constants.isOSX) {
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

    boolean bImageBufferValid = imageBuffer != null && imageBuffer.length == drawWidth;

    Image image = (Image)infoObj.getData("PiecesImage");
    GC gcImage;
    boolean bImageChanged;
    Rectangle imageBounds;
    if (image == null || image.isDisposed()) {
      bImageChanged = true;
    } else {
      imageBounds = image.getBounds();
      bImageChanged = imageBounds.width != newWidth ||
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

      /*
       * Set default size and centers the shell if it's configuration does not exist yet
       */
      if (null == COConfigurationManager.getStringParameter(
          "options.rectangle", null)) {
        Rectangle shellBounds = shell.getMonitor().getBounds();
        Point size = new Point(shellBounds.width * 10 / 11,
            shellBounds.height * 10 / 11);
        if (size.x > 1400) {
          size.x = 1400;
        }
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

  public TestWindow(Display display) {
    super(display);   
   
    layout();
   
    Rectangle bounds = display.getClientArea();   
    x0 = bounds.x + bounds.width - 250;
    x1 = bounds.x + bounds.width;

    y0 = bounds.y + bounds.height;
    y1 = bounds.y + bounds.height - 150;
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

    //not be any smaller than 50 pixels.
    editor.horizontalAlignment = SWT.LEFT;
    editor.grabHorizontal = true;
    editor.minimumWidth = 50;

    Rectangle r = text.computeTrim(0, 0, 100, text.getLineHeight());
    editor.minimumHeight = r.height;


    // Open the text editor on the selected row.
    editor.setEditor (text, item);
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

  {
    if (!initialized || pem == null || comp == null
        || pem.getPiecePicker() == null || pem.getDiskManager() == null
        || !comp.isVisible())
      return;
    Rectangle rect = pieceDistCanvas.getBounds();
    if (rect.height <= 0 || rect.width <= 0)
      return;
   
    PiecePicker picker = pem.getPiecePicker();
   
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

              try {
               
                int w = Integer.parseInt(strings[1]);
                int h = Integer.parseInt(strings[2]);

                Rectangle computeTrim = shell.computeTrim(0, 0, w, h);
                shell.setSize(computeTrim.width, computeTrim.height);
               
              } catch (Exception e) {
              }
            }
View Full Code Here

Examples of org.eclipse.swt.graphics.Rectangle

          size.y += toolTipShell.getBorderWidth() * 2 + (f.marginHeight * 2);
        } catch (NoSuchFieldError e) {
          /* Ignore for Pre 3.0 SWT.. */
        }
        Point pt = table.toDisplay(event.x, event.y);
        Rectangle displayRect;
        try {
          displayRect = table.getMonitor().getClientArea();
        } catch (NoSuchMethodError e) {
          displayRect = table.getDisplay().getClientArea();
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.