Point selectionPosition; int itemHeight = getItemHeight();
GC gc = event.gc; Color selectionColor = getDisplay().getSystemColor(SWT.COLOR_LIST_SELECTION); Point fullSelectionExtent; int paintXPosition; int paintYPosition;
TableItem paintItems(Event event, int topPaintIndex, int bottomPaintIndex, Vector paintColumns) {	Enumeration columns;	TableColumn column;	TableItem paintItem;	TableItem focusItem = null;	Point selectionExtent;	Point selectionPosition;	int itemHeight = getItemHeight();	topPaintIndex += getTopIndex();	bottomPaintIndex += getTopIndex();	for (int i = topPaintIndex; i <= bottomPaintIndex; i++) {		paintItem = (TableItem) getVisibleItem(i);		selectionExtent = paintItem.getSelectionExtent();		if (selectionExtent != null) {			selectionPosition = new Point(paintItem.getSelectionX(), getRedrawY(paintItem));			drawSelection(paintItem, event.gc, selectionPosition, selectionExtent);		}		columns = paintColumns.elements();		while (columns.hasMoreElements() == true) {			column = (TableColumn) columns.nextElement();			paintSubItem(event, paintItem, column, i * itemHeight);		}		if (hasFocus(paintItem)) {			focusItem = paintItem;		}	}	return focusItem;}