Package org.eclipse.swt.graphics

Examples of org.eclipse.swt.graphics.Rectangle.intersects()


          int y = top.y+top.height;
          int height = bot.y-y;
          int left = Math.max(top.x, bot.x);
          int right = Math.min(top.x+top.width, bot.x+bot.width);
          Rectangle gap = new Rectangle(left, y, right-left, height);
          if (gap.intersects(rect))
            return true;
        }
      }
    }
    return false;
View Full Code Here


                    int y = top.y+top.height;
                    int height = bot.y-y;
                    int left = Math.max(top.x, bot.x);
                    int right = Math.min(top.x+top.width, bot.x+bot.width);
                    Rectangle gap = new Rectangle(left, y, right-left, height);
                    if (gap.intersects(rect))
                        return true;
                }
            }
        }
        return false;
View Full Code Here

          int y = top.y+top.height;
          int height = bot.y-y;
          int left = Math.max(top.x, bot.x);
          int right = Math.min(top.x+top.width, bot.x+bot.width);
          Rectangle gap = new Rectangle(left, y, right-left, height);
          if (gap.intersects(rect))
            return true;
        }
      }
    }
    return false;
View Full Code Here

                    text.setText(item.getText(i));
                    text.selectAll();
                    text.setFocus();
                    return;
                }
                if (!visible && rect.intersects(clientArea)) {
                    visible = true;
                }
            }
            if (!visible) {
                return;
View Full Code Here

            + PopupDialog.POPUP_HORIZONTALSPACING, parentBounds.y
            + PopupDialog.POPUP_VERTICALSPACING,
            parentBounds.width, parentBounds.height);
        rightProposedBounds = getConstrainedShellBounds(rightProposedBounds);
        // If it won't fit on the right, try the left
        if (rightProposedBounds.intersects(parentBounds)) {
          Rectangle leftProposedBounds = new Rectangle(parentBounds.x
              - parentBounds.width - POPUP_HORIZONTALSPACING - 1,
              parentBounds.y, parentBounds.width,
              parentBounds.height);
          leftProposedBounds = getConstrainedShellBounds(leftProposedBounds);
View Full Code Here

              parentBounds.y, parentBounds.width,
              parentBounds.height);
          leftProposedBounds = getConstrainedShellBounds(leftProposedBounds);
          // If it won't fit on the left, choose the proposed bounds
          // that fits the best
          if (leftProposedBounds.intersects(parentBounds)) {
            if (rightProposedBounds.x - parentBounds.x >= parentBounds.x
                - leftProposedBounds.x) {
              rightProposedBounds.x = parentBounds.x
                  + parentBounds.width
                  + PopupDialog.POPUP_HORIZONTALSPACING;
View Full Code Here

            if (rect.contains(pt)) {
              rowIdx = index;
              colIdx = i;
              break;
            }
            if (!visible && rect.intersects(clientArea)) {
              visible = true;
            }
          }
          if (!visible)
            break;
View Full Code Here

                            text.selectAll ();
                            text.setFocus ();

                            return;
                        }
                        if (!visible && rect.intersects (clientArea)) {
                            visible = true;
                        }
                    //}
                    if (!visible) return;
                    index++;
View Full Code Here

                                        Plugin.getProperties().setProperty(item.getText(0), dialogResult);
                                        Plugin.saveConfig();
                                    }
                                //}
                            }
                            if (!visible && rect.intersects (clientArea)) {
                                visible = true;
                            }
                       
                    }
                    if (!visible) return;
View Full Code Here

                    text.setText(item.getText(i));
                    text.selectAll();
                    text.setFocus();
                    return;
                  }
                  if (!visible && rect.intersects(clientArea)) {
                    visible = true;
                  }
                }
                if (!visible)
                  return;
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.