Bug 549916 - [CSS] [Forms] Add possibilities to style ExpandableComposite, Section
Summary: [CSS] [Forms] Add possibilities to style ExpandableComposite, Section
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.12   Edit
Hardware: PC Windows 10
: P3 normal (vote)
Target Milestone: 4.14 M1   Edit
Assignee: Benedikt Kuntz CLA
QA Contact:
URL:
Whiteboard:
Keywords: noteworthy
Depends on: 559154
Blocks: 551494 551532
  Show dependency tree
 
Reported: 2019-08-09 04:15 EDT by Benedikt Kuntz CLA
Modified: 2020-01-14 08:02 EST (History)
2 users (show)

See Also:


Attachments
Screenshot (131.42 KB, image/png)
2019-09-25 16:10 EDT, Lars Vogel CLA
no flags Details
MANIFEST.MF Editor styled (46.83 KB, image/png)
2019-09-26 04:28 EDT, Benedikt Kuntz CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Benedikt Kuntz CLA 2019-08-09 04:15:05 EDT
Currently, only ExpandableComposite may have its title bar styled via css (swt-titlebar-color property). Section's title bar foreground cannot be changed, although Section is derived from ExpandableComposite.
Also, I would like to style the toggle color (and hover color) of ExpandableComposites (and Sections) as there is currently no possibility to style them via CSS.

I'll try to provide a Gerrit for this bug.
Comment 1 Eclipse Genie CLA 2019-08-09 04:35:25 EDT
New Gerrit change created: https://git.eclipse.org/r/147354
Comment 2 Ralph Gerbig CLA 2019-08-20 03:35:42 EDT
Is your change also addressing https://bugs.eclipse.org/bugs/show_bug.cgi?id=531532 ?

Especially, the case when the heading becomes so dark that it is not possible to read it anymore?
Comment 3 Benedikt Kuntz CLA 2019-08-20 04:11:51 EDT
I th(In reply to Ralph Gerbig from comment #2)
> Is your change also addressing
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=531532 ?
> 
> Especially, the case when the heading becomes so dark that it is not
> possible to read it anymore?

The patch adds css stylings (swt-titlebar-color for Sections and tb-toggle-color,tb-toggle-hover-color for Sections and ExpandableComposites). So I think one could use this to adapt the dark mode css colors.
Comment 4 Eclipse Genie CLA 2019-08-20 06:38:14 EDT
New Gerrit change created: https://git.eclipse.org/r/147980
Comment 5 Lars Vogel CLA 2019-09-25 16:10:38 EDT
Created attachment 280036 [details]
Screenshot

Benedikt, can this be used to get rid of the uglynes of the MANIFEST.MF editor in the dark theme?
Comment 6 Benedikt Kuntz CLA 2019-09-26 04:28:51 EDT
Created attachment 280040 [details]
MANIFEST.MF Editor styled

Added this to e4-dark_win.css:

Section { 
	swt-titlebar-color: #0000FF;
	tb-toggle-color: #00FF00; 
	tb-toggle-hover-color: #FF0000; 
	background-color-gradient-titlebar: #00FF00; 
	background-color-titlebar: #0000FF;
	border-color-titlebar: #00FF00;
}

ExpandableComposite { 
	swt-titlebar-color: #FF0000; 
	tb-toggle-color: #FF0000; 
	tb-toggle-hover-color: #00FF00;
}

Result see attachment....
Is this what you meant, Lars?
Comment 7 Lars Vogel CLA 2019-09-26 13:50:40 EDT
(In reply to Benedikt Kuntz from comment #6)

> Is this what you meant, Lars?

Cool. Opened follow-up Bug 551532 to use that in our default themes. Could you provide a Gerrit for that, Benedikt?
Comment 9 Lars Vogel CLA 2019-09-26 16:14:22 EDT
Thanks, Benedikt. 

Could you add an entry to the N&N for 4.14? You find the repo here https://git.eclipse.org/r/#/admin/projects/www.eclipse.org/eclipse/news here existing 4.14 entries for examples.
Comment 10 Eclipse Genie CLA 2019-09-27 09:47:00 EDT
New Gerrit change created: https://git.eclipse.org/r/150250