Reputation: 617
I'm trying to turn color of my readonly combo to white as a non-readonly combo
My code for the readonly Combo
Combo myCombo = new Combo(sessionProperties, SWT.SINGLE | SWT.BORDER | SWT.READ_ONLY, "");
I also try to set background and foreground, but it not this thing.
Upvotes: 3
Views: 1801
Reputation: 21025
The background color is a hint. On some platforms, some controls cannot change their background color.
The SWT CCombo
is a custom control that emulates the behavior of a combo box by using a text input field, a button, and a list.
Setting the background to white changes the text and list background color only. Not sure if that is what you were looking for.
If you think it's worth the effort you can still use the CCombo
widget as a template to build your own all-white combo box.
Upvotes: 5