Bug 204957 - [Presentations] Insufficient color contrast in file tabs when Eclipse not focused
Summary: [Presentations] Insufficient color contrast in file tabs when Eclipse not foc...
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.4   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform UI Triaged CLA
QA Contact:
URL:
Whiteboard:
Keywords: needinfo
Depends on:
Blocks:
 
Reported: 2007-09-28 16:50 EDT by Tomas Andrle CLA
Modified: 2019-09-06 15:35 EDT (History)
2 users (show)

See Also:


Attachments
Screenshot - Windows XP, Zune Theme, Eclipse not focused (14.44 KB, image/x-png)
2007-09-28 16:50 EDT, Tomas Andrle CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tomas Andrle CLA 2007-09-28 16:50:59 EDT
Created attachment 79428 [details]
Screenshot - Windows XP, Zune Theme, Eclipse not focused

Build ID: I20070621-1340

Steps To Reproduce:
1. Install Zune theme into Windows XP from go.microsoft.com/fwlink/?LinkID=75078 and apply it using Desktop properties
2. Open a file in Eclipse
3. Open another small window over Eclipse. The text on the tab of the file opened in Eclipse is now very hard to read.


More information:
This happens when the Zune theme is installed in Windows XP. Also likely to happen with the black-based theme in the Media Center edition of Windows XP. Please note that the Zune theme is an official theme from MS.
Comment 1 Kevin McGuire CLA 2007-10-02 13:15:51 EDT
Can you please describe more about your configuration?
Specifically, I see your screen shot has square tabs... did you just change the tab style, or a different Presentation?

I've downloaded the Zune theme and have tried the three presentations in 3.4 M2 and am not seeing what you're seeing.
Comment 2 Kevin McGuire CLA 2007-10-02 13:25:59 EDT
I notice in your snap the title bar text is a medium gray, but I'm getting white both when the workbench is in focus and when it is behind another window. Did you change the title foreground color in Eclipse? Or tweak your theme?  This seems the source of why I'm not getting the same results.

This reduced contrast seems the source of the problem because we assume there is a fair bit of contrast between the title foreground and background.  We assume that because its needed for accessibility.  We use title foreground for tab folder title text, and we soften the title background color by adding some white.  In your case the title of the window itself is already slightly unreadable against the background and so us making the background lighter reduces the contrast even further.
Comment 3 Kevin McGuire CLA 2007-10-04 12:55:41 EDT
Adding Kelvin to CC.

Kelvin, regardless of the answer from Tomas (whether this is the straight Zune theme or modified) we need some extra smarts in the color algorithm to ensure there is enough contrast between the background and text.  

How do we compute the minimum required contrast?

I am upgrading the severity because unreadable tabs are a loss of function.
Comment 4 Kevin McGuire CLA 2007-10-04 13:07:49 EDT
Note our tab color algorithm currently only takes into account the TITLE_BACKGROUND, not in conjunction with TITLE_FOREGROUND.  See bug #180415.
Comment 5 Kevin McGuire CLA 2007-10-04 14:38:24 EDT
Note the offending case is Active (Nofocus).  I'm not sure why we only use the color factory for the background start.  The LightColorFactory returns:

		return ColorUtil.blend(white, base, 40);

ie. we just always add 40 white to the background end.  So we either need to be smarter about it (add white based on percentage) or we should just use COLOR_TITLE_INACTIVE_BACKGROUND_GRADIENT, with the net being the tab will just look the same as the title bar.

The XML is as follows from org.eclipse.ui looks like:

<!-- Active (Nofocus) Tab Colors -->
      <colorDefinition
            label="%Color.activeNofocusTabText"
            categoryId="org.eclipse.ui.presentation.default"
            value="COLOR_TITLE_INACTIVE_FOREGROUND"
            id="org.eclipse.ui.workbench.ACTIVE_NOFOCUS_TAB_TEXT_COLOR">
         <description>
            %Color.activeNofocusTabTextDesc
         </description>
      </colorDefinition>
      <colorDefinition
            label="%Color.activeNofocusTabBGEnd"
            categoryId="org.eclipse.ui.presentation.default"
            value="COLOR_TITLE_INACTIVE_BACKGROUND"
            id="org.eclipse.ui.workbench.ACTIVE_NOFOCUS_TAB_BG_END">
         <description>
            %Color.activeNofocusTabBGEndDesc
         </description>
      </colorDefinition>
      <colorDefinition
            label="%Color.activeNofocusTabBGStart"
            categoryId="org.eclipse.ui.presentation.default"
            id="org.eclipse.ui.workbench.ACTIVE_NOFOCUS_TAB_BG_START">
         <description>
            %Color.activeNofocusTabBGStartDesc
         </description>
         <colorFactory
               class="org.eclipse.ui.internal.themes.LightColorFactory"
               plugin="org.eclipse.ui">
          <parameter
                  name="base" value="COLOR_TITLE_INACTIVE_BACKGROUND">
          </parameter>
          <parameter
                  name="definitionId" value="org.eclipse.ui.workbench.ACTIVE_NOFOCUS_TAB_BG_START">
          </parameter>
         </colorFactory>
      </colorDefinition>    
Comment 6 Eclipse Webmaster CLA 2019-09-06 15:35:14 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.