Buggy code:
; static final float [ ] LINE_DASHDOTDOT_ZERO = new float [ ] { 9 , 3 , 3 , 3 , 3 , 3 } ; GC ( ) { } public GC ( Drawable drawable ) { } public GC ( Drawable drawable , int style ) { } static int checkStyle ( int style ) { } public static GC cocoa_new ( Drawable drawable , GCData data ) { } int applierFunc ( int info , int elementPtr ) { } NSAutoreleasePool checkGC ( int mask ) { } public void copyArea ( Image image , int x , int y ) { } void copyArea ( Image image , int x , int y , int srcImage ) { } public void copyArea ( int srcX , int srcY , int width , int height , int destX , int destY ) { } public void copyArea ( int srcX , int srcY , int width , int height , int destX , int destY , boolean paint ) { } static int createCGPathRef ( NSBezierPath nsPath ) { } NSBezierPath createNSBezierPath ( int cgPath ) { } NSAttributedString createString ( String string , int flags , boolean draw ) { } void destroy ( ) { } public void drawArc ( int x , int y , int width , int height , int startAngle , int arcAngle ) { } public void drawFocus ( int x , int y , int width , int height ) { } public void drawImage ( Image image , int x , int y ) { } public void drawImage ( Image image , int srcX , int srcY , int srcWidth , int srcHeight , int destX , int destY , int destWidth , int destHeight ) { } void drawImage ( Image srcImage , int srcX , int srcY , int srcWidth , int srcHeight , int destX , int destY , int destWidth , int destHeight , boolean simple ) { NSImage imageHandle = srcImage . handle ; NSSize size = imageHandle . size ( ) ; int imgWidth = ( ( int ) ( size . width ) ) ; int imgHeight = ( ( int ) ( size . height ) ) ; if ( simple ) { srcWidth = destWidth = imgWidth ; srcHeight = destHeight = imgHeight ; } else { simple = ( ( ( ( ( srcX == 0 ) && ( srcY == 0 ) ) && ( srcWidth == destWidth ) ) && ( destWidth == imgWidth ) ) && ( srcHeight == destHeight ) ) && ( destHeight == imgHeight ) ; if ( ( ( srcX + srcWidth ) > imgWidth ) || ( ( srcY + srcHeight ) > imgHeight ) ) { SWT . error ( ERROR_INVALID_ARGUMENT ) ; } } NSAutoreleasePool pool = checkGC ( ( ( GC . CLIPPING ) | ( GC . TRANSFORM ) ) ) ; try { if ( ( srcImage . memGC ) != null ) { srcImage . createAlpha ( ) ; } handle . saveGraphicsState ( ) ; NSAffineTransform transform = NSAffineTransform . transform ( ) ; transform . scaleXBy ( 1 , ( - 1 ) ) ; transform . translateXBy ( 0 , ( - ( destHeight + ( 2 * destY ) ) ) ) ; transform . concat ( ) ; NSRect srcRect = new NSRect ( ) ; srcRect . x = srcX ; srcRect . y = imgHeight - ( srcY + srcHeight ) ; srcRect . width = srcWidth ; srcRect . height = srcHeight ; NSRect destRect = new NSRect ( ) ; destRect . x = destX ; destRect . y = destY ; destRect . width = destWidth ; destRect . height = destHeight ; <START_BUG> imageHandle . drawInRect ( destRect , srcRect , NSCompositeSourceOver , 1 ) ; <END_BUG> handle . restoreGraphicsState ( ) ; } finally { uncheckGC ( pool ) ; } } public void drawLine ( int x1 , int y1 , int x2 , int y2 ) { } public void drawOval ( int x , int y , int width , int height ) { } public void drawPath ( Path path ) { } public void drawPoint ( int x , int y ) { } public void drawPolygon ( int [ ] pointArray ) { } public void drawPolyline ( int [ ] pointArray ) { } public void drawRectangle ( int x , int y , int width , int height ) { } public void drawRectangle ( Rectangle rect ) { } public void drawRoundRectangle ( int x , int y , int width , int height , int arcWidth , int arcHeight ) { } public void drawString ( String string , int x , int y ) { } public void drawString ( String string , int x , int y , boolean isTransparent ) { } public void drawText ( String string , int x , int y ) { } public void drawText ( String string , int x , int y , boolean isTransparent ) { } public void drawText ( String string , int x , int y , int flags ) { } public boolean equals ( Object object ) { } public void fillArc ( int x , int y , int width , int height , int startAngle , int arcAngle ) { } public void fillGradientRectangle ( int x , int y , int width , int height , boolean vertical ) { } public void fillOval ( int x , int y , int width , int height ) { } void fillPattern ( NSBezierPath path , Pattern pattern ) { } public void fillPath ( Path path ) { } public void fillPolygon ( int [ ] pointArray ) { }

Fix:
imageHandle . drawInRect ( destRect , srcRect , NSCompositeSourceOver , ( ( data . alpha ) // 255.0F ) ) ;