Is it possible to create read only fields with scout? In SWT there is the Property SWT.READ_ONLY which changes for example the Text Fields behavier to show the text and makes it possible to do copy it into another app, but the user is not able to change it.
Example in SWT:
Text textField = new Text(parent, SWT.READ_ONLY | SWT.BORDER);
textField.setText("This is a read only field");
Ok, this is correct. But the controls do not look like Read Only Controls. SWT Read Only controls do have the text painted black, disabled controls do have painted the text gray, which is realy hard do read.
The Scout Model is also a simplified view of the UI Widget. I assume that the people who designed scout didn't want to have "Editable" and "Enabled" properties in the Scout Field to keep the API simple.
I think the design choice still holds today.
For your use case, it is solved in SWT UI with the UiDecorationExtensionPoint. In the SWT plugin of your application, you can use:
Urs Beeli Messages: 426 Registered: October 2012 Location: Bern, Switzerland
And just to keep you from stumbling across the same rock that I hit when I first tried this: The property contains the word "forground" instead of "foreground". Even though Eclipse flagged the line with a warning when I spellt the property name "correctly" I didn't notice that this was the problem and spent about an hour wondering why setting the colour didn't work