Buggy code:
public class Tree extends Composite { NSTableColumn firstColumn ; NSTableColumn checkColumn ; NSTextFieldCell dataCell ; NSButtonCell buttonCell ; NSTableHeaderView headerView ; TreeItem [ ] items ; int itemCount ; TreeColumn [ ] columns ; TreeColumn sortColumn ; int columnCount ; int sortDirection ; boolean ignoreExpand ; boolean ignoreSelect ; boolean ignoreRedraw ; boolean reloadPending ; Rectangle imageBounds ; static final int FIRST_COLUMN_MINIMUM_WIDTH = 5 ; static final int IMAGE_GAP = 3 ; static final int TEXT_GAP = 2 ; static final int CELL_GAP = 1 ; public Tree ( Composite parent , int style ) { } void _addListener ( int eventType , Listener listener ) { } TreeItem _getItem ( TreeItem parentItem , int index , boolean create ) { } int accessibilityAttributeValue ( int id , int sel , int arg0 ) { } public void addSelectionListener ( SelectionListener listener ) { } public void addTreeListener ( TreeListener listener ) { } int calculateWidth ( TreeItem [ ] items , int index , GC gc , boolean recurse ) { } NSSize cellSize ( int id , int sel ) { } boolean checkData ( TreeItem item ) { } static int checkStyle ( int style ) { } protected void checkSubclass ( ) { } void checkItems ( ) { } void clear ( TreeItem parentItem , int index , boolean all ) { } void clearAll ( TreeItem parentItem , boolean all ) { } public void clear ( int index , boolean all ) { } public void clearAll ( boolean all ) { } void clearCachedWidth ( TreeItem [ ] items ) { } public Point computeSize ( int wHint , int hHint , boolean changed ) { checkWidget ( ) ; int width = 0 ; int height = 0 ; if ( wHint == ( SWT . DEFAULT ) ) { if ( ( columnCount ) != 0 ) { for ( int i = 0 ; i < ( columnCount ) ; i ++ ) { <START_BUG> width += ( columns [ i ] . getWidth ( ) ) + ( Tree . CELL_GAP ) ; <END_BUG> } } else { GC gc = new GC ( this ) ; width = ( calculateWidth ( items , 0 , gc , true ) ) + ( Tree . CELL_GAP ) ; gc . dispose ( ) ; } if ( ( ( style ) & ( SWT . CHECK ) ) != 0 ) width += getCheckColumnWidth ( ) ; } else { width = wHint ; } if ( hHint == ( SWT . DEFAULT ) ) { height = ( ( ( int ) ( ( ( NSOutlineView ) ( view ) ) . numberOfRows ( ) ) ) * ( getItemHeight ( ) ) ) + ( getHeaderHeight ( ) ) ; } else { height = hHint ; } if ( width <= 0 ) width = DEFAULT_WIDTH ; if ( height <= 0 ) height = DEFAULT_HEIGHT ; Rectangle rect = computeTrim ( 0 , 0 , width , height ) ; return new Point ( rect . width , rect . height ) ; } void createColumn ( TreeItem item , int index ) { } void createHandle ( ) { } void createItem ( TreeColumn column , int index ) { } void createItem ( TreeItem item , TreeItem parentItem , int index ) { } void createWidget ( ) { } Color defaultBackground ( ) { } NSFont defaultNSFont ( ) { } Color defaultForeground ( ) { } public void deselectAll ( ) { } void deregister ( ) { } public void deselect ( TreeItem item ) { } void destroyItem ( TreeColumn column ) { } void destroyItem ( TreeItem item ) { } boolean dragDetect ( int x , int y , boolean filter , boolean [ ] consume ) { } void drawWithFrame_inView ( int id , int sel , int cellFrame , int view ) { } void drawInteriorWithFrame_inView ( int id , int sel , int cellFrame , int view ) { } Widget findTooltip ( NSPoint pt ) { } int getCheckColumnWidth ( ) { } public Rectangle getClientArea ( ) { } TreeColumn getColumn ( id id ) { } public TreeColumn getColumn ( int index ) { } public int getColumnCount ( ) { } public int [ ] getColumnOrder ( ) { } public TreeColumn [ ] getColumns ( ) { } public int getGridLineWidth ( ) { } public int getHeaderHeight ( ) { } public boolean getHeaderVisible ( ) { } public TreeItem getItem ( int index ) { } public TreeItem getItem ( Point point ) { } public int getItemCount ( ) { } int getItemCount ( TreeItem item ) { } public int getItemHeight ( ) { } public TreeItem [ ] getItems ( ) { } public boolean getLinesVisible ( ) { } public TreeItem getParentItem ( ) { } public TreeItem [ ] getSelection ( ) { } public int getSelectionCount ( ) { } public TreeColumn getSortColumn ( ) { } public int getSortDirection ( ) { } public TreeItem getTopItem ( ) { } void highlightSelectionInClipRect ( int id , int sel , int rect ) { } int hitTestForEvent ( int id , int sel , int event , NSRect rect , int controlView ) { } int image ( int id , int sel ) { } NSRect imageRectForBounds ( int id , int sel , NSRect cellFrame ) { } public int indexOf ( TreeColumn column ) { } public int indexOf ( TreeItem item ) { } boolean isTrim ( NSView view ) { } int menuForEvent ( int id , int sel , int theEvent ) { } int nextState ( int id , int sel ) { }

Fix:
width += columns [ i ] . getWidth ( ) ;