Buggy code:
public class Tree extends Composite { TreeItem [ ] items ; TreeColumn [ ] columns ; ImageList imageList ; ImageList headerImageList ; TreeItem currentItem ; TreeColumn sortColumn ; int hwndParent ; int hwndHeader ; int hAnchor ; int hInsert ; int lastID ; int hFirstIndexOf ; int hLastIndexOf ; int lastIndexOf ; int sortDirection ; boolean dragStarted ; boolean gestureCompleted ; boolean insertAfter ; boolean shrink ; boolean ignoreSelect ; boolean ignoreExpand ; boolean ignoreDeselect ; boolean ignoreResize ; boolean lockSelection ; boolean oldSelected ; boolean newSelected ; boolean cancelMove ; boolean linesVisible ; boolean customDraw ; boolean printClient ; static final int INSET = 3 ; static final int GRID_WIDTH = 1 ; static final int SORT_WIDTH = 10 ; static final int HEADER_MARGIN = 10 ; static final int TreeProc ; static final TCHAR TreeClass = new TCHAR ( 0 , OS . WC_TREEVIEW , true ) ; static final char [ ] BUTTON = new char [ ] { 'B' , 'U' , 'T' , 'T' , 'O' , 'N' , 0 } ; public Tree ( Composite parent , int style ) { } static int checkStyle ( int style ) { } int _getBackgroundPixel ( ) { } void _setBackgroundPixel ( int pixel ) { } public void addSelectionListener ( SelectionListener listener ) { } public void addTreeListener ( TreeListener listener ) { } int borderHandle ( ) { } int callWindowProc ( int hwnd , int msg , int wParam , int lParam ) { } boolean checkData ( TreeItem item , boolean redraw ) { } boolean checkHandle ( int hwnd ) { } boolean checkScroll ( int hItem ) { } protected void checkSubclass ( ) { } void clear ( int index , boolean all ) { } void clear ( TreeItem parentItem , int index , boolean all ) { } void clearAll ( boolean all ) { } public Point computeSize ( int wHint , int hHint , boolean changed ) { } void createHandle ( ) { super . createHandle ( ) ; <START_BUG> state &= ~ ( CANVAS ) ; <END_BUG> if ( ! ( OS . IsWinCE ) ) { if ( ( OS . COMCTL32_MAJOR ) < 6 ) { OS . SendMessage ( handle , CCM_SETVERSION , 5 , 0 ) ; } } if ( ( ( style ) & ( SWT . CHECK ) ) != 0 ) setCheckboxImageList ( ) ; int hFont = OS . GetStockObject ( SYSTEM_FONT ) ; OS . SendMessage ( handle , WM_SETFONT , hFont , 0 ) ; } void createItem ( TreeColumn column , int index ) { } void createItem ( TreeItem item , int hParent , int hInsertAfter ) { } void createParent ( ) { } void createWidget ( ) { } int defaultBackground ( ) { } void deregister ( ) { } public void deselectAll ( ) { } void destroyItem ( TreeColumn column ) { } void destroyItem ( TreeItem item ) { } void enableWidget ( boolean enabled ) { } int findIndex ( int hFirstItem , int hItem ) { } Widget findItem ( int id ) { } int findItem ( int hFirstItem , int index ) { } int getBackgroundPixel ( ) { } int getForegroundPixel ( ) { } public int getGridLineWidth ( ) { } public int getHeaderHeight ( ) { } public boolean getHeaderVisible ( ) { } Point getImageSize ( ) { } public TreeColumn getColumn ( int index ) { } public int getColumnCount ( ) { } int [ ] getColumnOrder ( ) { } public TreeColumn [ ] getColumns ( ) { } public TreeItem getItem ( int index ) { } public TreeItem getItem ( Point point ) { } public int getItemCount ( ) { } int getItemCount ( int hItem ) { } public int getItemHeight ( ) { } public TreeItem [ ] getItems ( ) { } TreeItem [ ] getItems ( int hTreeItem ) { } public boolean getLinesVisible ( ) { } public TreeItem getParentItem ( ) { } public TreeItem [ ] getSelection ( ) { } public int getSelectionCount ( ) { } public TreeColumn getSortColumn ( ) { } public int getSortDirection ( ) { } public TreeItem getTopItem ( ) { } int imageIndex ( Image image ) { } int imageIndexHeader ( Image image ) { } public int indexOf ( TreeColumn column ) { } public int indexOf ( TreeItem item ) { } void register ( ) { } boolean releaseItem ( TreeItem item , TVITEM tvItem ) { } void releaseItems ( TreeItem [ ] nodes , TVITEM tvItem ) { } void releaseHandle ( ) { } void releaseWidget ( ) { } public void removeAll ( ) { } public void removeSelectionListener ( SelectionListener listener ) { } public void removeTreeListener ( TreeListener listener ) { } public void setInsertMark ( TreeItem item , boolean before ) { } void setItemCount ( int count ) { } void setItemCount ( int count , int hItem , TreeItem parent ) { } public void setLinesVisible ( boolean show ) { } int scrolledHandle ( ) { } public void selectAll ( ) { } void setBackgroundPixel ( int pixel ) { } void setBounds ( int x , int y , int width , int height , int flags ) { } void setCursor ( ) { } void setColumnOrder ( int [ ] order ) { } void setCheckboxImageList ( ) { } void setForegroundPixel ( int pixel ) { } public void setHeaderVisible ( boolean show ) { } public void setRedraw ( boolean redraw ) { } void setScrollWidth ( ) { } public void setSelection ( TreeItem [ ] items ) { } public void setSortColumn ( TreeColumn column ) { } public void setSortDirection ( int direction ) { }

Fix:
state &= ~ ( ( CANVAS ) | ( TRANSPARENT ) ) ;