I am dynamically adding a NSTextField to a window and am having issues with rendering. I am setting the background color to be black and the text color to be white. These both work but their is what appears to be a rectangle that is part of the text that is always white. Does anyone know what I might be doing wrong? How can I get rid of the white background that is just around the text? Code is as follows:
//Create rectangle to size text field
NSRect textFieldRect = NSMakeRect(300, 300, 300, 54);
//Instantiate text field and set defaults NSTextField* textField = [[NSTextField alloc] initWithFrame:textFieldRect];
[textField setFont:[NSFont fontWithName:@"Arial" size:48]];
[textField setTextColor:[NSColor whiteColor]];
[textField setStringValue:@"Some Text"];
[textField setBackgroundColor:[NSColor blackColor]];
[textField setDrawsBackground:YES];
[textField setBordered:NO];
[[window contentView] addSubview:textField];
Thanks,
JTC