;      NSImage* im = [[NSImage alloc] initWithSize:NSMakeSize(iBitmap.getwidth(), iBitmap.getheight())];     [im addRepresentation:bitmap];      //NSImage* im = [[NSImage alloc] initByReferencingFile:@"./Contents/Resources/curve.jpg"];      NSRect rect = NSMakeRect(0, 0, windowRect.size.width,windowRect.size.height-TITLEBAR_HEIGHT);     [imageView setFrame:rect];     [imageView setImageScaling:NSScaleToFit];     [imageView setImage:im];     [imageView display];  }