Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 325443

Summary: No theming support for separator label
Product: [RT] RAP Reporter: Tillmann Seidel <tseidel>
Component: RWTAssignee: Project Inbox <rap-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P3    
Version: 1.3   
Target Milestone: 1.4 M3   
Hardware: All   
OS: All   
Whiteboard:

Description Tillmann Seidel CLA 2010-09-16 07:59:22 EDT
Build Identifier: RAP 1.3.0

Labels with style SWT.SEPARATOR set don't seem to be themeable.

Reproducible: Always

Steps to Reproduce:
1. Create a label (SWT.SEPARATOR)
2. Create a theme extension
3. Add to the extension css:

Label.separator {
  background-color: #9a9a9a;
}

4. Set theme variant "separator" to the label

The resulting separator has still a white background. When switching to a normal label (SWT.NONE), the theming works (it has a grey background).
Comment 1 Ivan Furnadjiev CLA 2010-09-23 04:21:28 EDT
Now it's possible to style the separator like this:
Label[SEPARATOR] {
  background-color: #9a9a9a;
}
Custom variants are supported too.
Fixed in CVS HEAD.
Comment 2 Ralf Sternberg CLA 2010-09-28 05:04:41 EDT
I think we should also be able to style the border of the separator line. This is *not* the border of the Label. You can test it in SWT with a Label with style SWT.SEPARATOR | SWT.BORDER - there are two different lines. I think it would make sense to introduce a sub-widget like "Label-SeparatorLine" for this. Since the separator line depends on the style flags SWT.SHADOW_*, I guess those should also be supported.

If we do so, the default theme (as well as our custom themes) would have to be extended with separator styling.
Comment 3 Ivan Furnadjiev CLA 2010-10-15 04:27:29 EDT
New subelement Label-SeparatorLine added. It supports the following properties:
border
border-radius
background-color
background-image
width
and styles:
SHADOW_IN
SHADOW_OUT
SHADOW_NONE