Control child = children[spec.childIndex];
void calculateGridDimensions(Composite composite, boolean flushCache) {	int maxWidth, childWidth, maxHeight, childHeight;		//	Control[] children = composite.getChildren();	Point[] childSizes = new Point[children.length];	pixelColumnWidths = new int[numColumns];	pixelRowHeights = new int[grid.size()];		// Loop through the grid by column to get the width that each column needs to be.	// Each column will be as wide as its widest widget.	for (int column = 0; column < numColumns; column++) {		maxWidth = 0;		for (int row = 0; row < grid.size(); row++) {			GridData spec = ((GridData[]) grid.elementAt(row))[column];			if (spec.isItemData()) {				Control child = children[spec.childIndex];				childSizes[spec.childIndex] = child.computeSize(spec.widthHint, spec.heightHint, flushCache);				childWidth = childSizes[spec.childIndex].x + spec.horizontalIndent;				if (spec.horizontalSpan == 1) {					maxWidth = Math.max(maxWidth, childWidth);				}			}		}		// Cache the values for later use.		pixelColumnWidths[column] = maxWidth;	}	// 	if (makeColumnsEqualWidth) {		maxWidth = 0;		// Find the largest column size that is necessary and make each column that size.		for (int i = 0; i < numColumns; i++) {			maxWidth = Math.max(maxWidth, pixelColumnWidths[i]);		}		for (int i = 0; i < numColumns; i++) {			pixelColumnWidths[i] = maxWidth;		}	}	// Loop through the grid by row to get the height that each row needs to be.	// Each row will be as high as its tallest widget.	for (int row = 0; row < grid.size(); row++) {		maxHeight = 0;		for (int column = 0; column < numColumns; column++) {			GridData spec = ((GridData[]) grid.elementAt(row))[column];			if (spec.isItemData()) {				Control child = children[spec.childIndex];				childHeight = childSizes[spec.childIndex].y;				if (spec.verticalSpan == 1) {					maxHeight = Math.max(maxHeight, childHeight);				}			}		}		// Cache the values for later use.		pixelRowHeights[row] = maxHeight;	}}