src/share/classes/java/awt/GridBagLayout.java
Print this page
*** 1,7 ****
/*
! * Copyright (c) 1995, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
--- 1,7 ----
/*
! * Copyright (c) 1995, 2014, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
*** 979,991 ****
/**
* This method is obsolete and supplied for backwards
* compatibility only; new code should call {@link
* #getLayoutInfo(java.awt.Container, int) getLayoutInfo} instead.
! * This method is the same as <code>getLayoutInfo</code>;
! * refer to <code>getLayoutInfo</code> for details on parameters
! * and return value.
*/
protected GridBagLayoutInfo GetLayoutInfo(Container parent, int sizeflag) {
synchronized (parent.getTreeLock()) {
GridBagLayoutInfo r;
Component comp;
--- 979,997 ----
/**
* This method is obsolete and supplied for backwards
* compatibility only; new code should call {@link
* #getLayoutInfo(java.awt.Container, int) getLayoutInfo} instead.
! *
! * Fills in an instance of {@code GridBagLayoutInfo} for the
! * current set of managed children. This method is the same
! * as {@code getLayoutInfo}; refer to {@code getLayoutInfo}
! * description for details.
! *
! * @param parent the layout container
! * @param sizeflag either {@code PREFERREDSIZE} or {@code MINSIZE}
! * @return the {@code GridBagLayoutInfo} for the set of children
*/
protected GridBagLayoutInfo GetLayoutInfo(Container parent, int sizeflag) {
synchronized (parent.getTreeLock()) {
GridBagLayoutInfo r;
Component comp;
*** 1609,1625 ****
Rectangle r) {
AdjustForGravity(constraints, r);
}
/**
* This method is obsolete and supplied for backwards
* compatibility only; new code should call {@link
* #adjustForGravity(java.awt.GridBagConstraints, java.awt.Rectangle)
* adjustForGravity} instead.
! * This method is the same as <code>adjustForGravity</code>;
! * refer to <code>adjustForGravity</code> for details
! * on parameters.
*/
protected void AdjustForGravity(GridBagConstraints constraints,
Rectangle r) {
int diffx, diffy;
int cellY = r.y;
--- 1615,1635 ----
Rectangle r) {
AdjustForGravity(constraints, r);
}
/**
+ * Adjusts the x, y, width, and height fields to the correct
+ * values depending on the constraint geometry and pads.
+ * <p>
* This method is obsolete and supplied for backwards
* compatibility only; new code should call {@link
* #adjustForGravity(java.awt.GridBagConstraints, java.awt.Rectangle)
* adjustForGravity} instead.
! * This method is the same as <code>adjustForGravity</code>
! *
! * @param constraints the constraints to be applied
! * @param r the {@code Rectangle} to be adjusted
*/
protected void AdjustForGravity(GridBagConstraints constraints,
Rectangle r) {
int diffx, diffy;
int cellY = r.y;
*** 1993,2005 ****
/**
* This method is obsolete and supplied for backwards
* compatibility only; new code should call {@link
* #getMinSize(java.awt.Container, GridBagLayoutInfo) getMinSize} instead.
! * This method is the same as <code>getMinSize</code>;
! * refer to <code>getMinSize</code> for details on parameters
! * and return value.
*/
protected Dimension GetMinSize(Container parent, GridBagLayoutInfo info) {
Dimension d = new Dimension();
int i, t;
Insets insets = parent.getInsets();
--- 2003,2018 ----
/**
* This method is obsolete and supplied for backwards
* compatibility only; new code should call {@link
* #getMinSize(java.awt.Container, GridBagLayoutInfo) getMinSize} instead.
! * This method is the same as <code>getMinSize</code>
! *
! * @param parent the layout container
! * @param info the layout info for this parent
! * @return a <code>Dimension</code> object containing the
! * minimum size
*/
protected Dimension GetMinSize(Container parent, GridBagLayoutInfo info) {
Dimension d = new Dimension();
int i, t;
Insets insets = parent.getInsets();
*** 2033,2045 ****
/**
* This method is obsolete and supplied for backwards
* compatibility only; new code should call {@link
* #arrangeGrid(Container) arrangeGrid} instead.
! * This method is the same as <code>arrangeGrid</code>;
! * refer to <code>arrangeGrid</code> for details on the
! * parameter.
*/
protected void ArrangeGrid(Container parent) {
Component comp;
int compindex;
GridBagConstraints constraints;
--- 2046,2058 ----
/**
* This method is obsolete and supplied for backwards
* compatibility only; new code should call {@link
* #arrangeGrid(Container) arrangeGrid} instead.
! * This method is the same as <code>arrangeGrid</code>
! *
! * @param parent the layout container
*/
protected void ArrangeGrid(Container parent) {
Component comp;
int compindex;
GridBagConstraints constraints;