Package javax.swing

Examples of javax.swing.JViewport.scrollRectToVisible()


            }

            Rectangle rectangle = new Rectangle((int) x, (int) y, 1, 1);

            // Scroll the area into view.
            viewport.scrollRectToVisible(rectangle);
        }
    }

    /**
     * Rebuilds view for the new object selection.
View Full Code Here


            centerY = -centerY;
        }
        rect.translate(centerX, centerY);

        // Scroll the area into view.
        viewport.scrollRectToVisible(rect);
    }
}
View Full Code Here

    // to the view, assuming the northwest corner of the
    // view is (0,0)
    rect.setLocation(rect.x - pt.x, rect.y - pt.y);
   
    // Scroll the area into view
    viewport.scrollRectToVisible(rect);
  }
}
View Full Code Here

      int y = (pos.getY() - AUTOSCROLL_EXTRA) * cell.height - view.y;
      int width = cell.width * (AUTOSCROLL_EXTRA) * 2;
      int height = cell.height * (AUTOSCROLL_EXTRA) * 2;

      Rectangle rect = new Rectangle(x, y, width, height);
      scroll.scrollRectToVisible(rect);
    }
  }


  /*
 
View Full Code Here

    // to the view, assuming the northwest corner of the
    // view is (0,0)
    rect.setLocation(rect.x - pt.x, rect.y - pt.y);
   
    // Scroll the area into view
    viewport.scrollRectToVisible(rect);
  }
}
View Full Code Here

            }

            Rectangle rectangle = new Rectangle((int) x, (int) y, 1, 1);

            // Scroll the area into view.
            viewport.scrollRectToVisible(rectangle);
        }
    }
   
    /**
     * Rebuilds view for the new object selection.
View Full Code Here

                return;
            JViewport viewport = (JViewport) getParent();
            Rectangle rect = getCellRect(row, col, true);
            Point pt = viewport.getViewPosition();
            rect.setLocation(rect.x - pt.x, rect.y - pt.y);
            viewport.scrollRectToVisible(rect);
        }
    }

    /**
     * Creates a {@link ShowHideLayerAction} for <code>layer</code> in the
View Full Code Here

                return;
            JViewport viewport = (JViewport) getParent();
            Rectangle rect = getCellRect(row, col, true);
            Point pt = viewport.getViewPosition();
            rect.setLocation(rect.x - pt.x, rect.y - pt.y);
            viewport.scrollRectToVisible(rect);
        }
    }

    @Override
    public void showNotify() {
View Full Code Here

                  // Translate the cell location so that it is relative
                  // to the view, assuming the northwest corner of the
                  // view is (0,0)
                  rect.setLocation(rect.x - pt.x, rect.y - pt.y);
                  // Scroll the area into view
                  viewport.scrollRectToVisible(rect);

                  return true;
               }
            }
         }
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.