piroor / treestyletab

Tree Style Tab, Show tabs like a tree.
http://piro.sakura.ne.jp/xul/treestyletab/
Other
3.51k stars 279 forks source link

Contrast of diving line between tabs regressed with Photon theme between 115esr and 128esr #3619

Closed theres-waldo closed 2 months ago

theres-waldo commented 3 months ago

Abstract

When upgrading a Firefox installation from 115esr to 128esr, I noticed that the contrast of the dividing line between tabs in the Tree Style Tab sidebar (relative to the background of the tabs) has regressed with the "Photon" theme.

This can be seen in the following screenshots. Before:

tst-contrast-before

After:

tst-contrast-after

I used mozregression to find the regression window where the contrast changed, the window is the following:

https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=9867c50c335041a02e09cfe626f359dda31d1bae&tochange=3fe8b7d8b3f7f163eafd11115c59e2f18f20cbfc

The bugs in the regression range are all of the form "Make deprecated system color [blah] same as css-color-4 system color [blah]". They all landed in the same push to the integration branch so mozregression cannot tell me which specific commit is the cause.

It's not clear me whether this should be considered a Firefox bug, or if this is an expected sort of Firefox change that Tree Style Tab should perhaps consider adapting to (to maintain a better contrast between tabs).

Steps to reproduce

  1. Start Firefox with clean profile.
  2. Install TST.
  3. In TST preferences, change "Theme" to "Photon".
  4. Open several tabs
  5. Observe the contrast between the color of the tab background, and the color of the dividing line between the tabs

Expected result

The contrast is high (it's easy to see where one tab ends and the next tab begins).

Actual result

The contrast is low (the tabs kind of blend together visually).

Environment

piroor commented 2 months ago

Thanks, I've introduced some changes to simulate deprecated system colors.

mika commented 2 months ago

Note: I'm not entirely sure, whether this is the same issue (since I'm using the same Firefox version but only different TST versions), sorry for the noise if this should be the same issue.

With Firefox v130.0 and TST v4.0.22 (2024.8.9), the Photon theme looks as expected:

screenshot 2024-09-16T23-27-24

Whereas with Firefox v130.0 and TST v4.0.23 (2024.9.11), the Photon theme looks strange:

screenshot 2024-09-16T23-27-31

Thanks for TST, I'm loving it! :)

theres-waldo commented 2 months ago

@mika I would suggest trying TST v4.0.22 with Firefox 115esr (or any version earlier than 124; mozregression is a convenient way to test different Firefox versions).

I suspect it may look like the second screenshot (and so TST v4.0.23 is fixing an appearance regression introduced in Firefox 124).

theres-waldo commented 2 months ago

I suspect it may look like the second screenshot (and so TST v4.0.23 is fixing an appearance regression introduced in Firefox 124).

Hmm, actually that's not quite true, at least on my machine: the dividing lines are darker in TST v4.0.23 than they were in v4.0.22 even in older Firefox versions. (I'm in a Wayland session right now and can't take screenshots, but I can upload some later if that would be helpful.)

piroor commented 2 months ago

New colors on TST 4.0.23 are defined with CSS color-mix as: https://github.com/piroor/treestyletab/blob/0a2e63058f05f1103ebee39e0309210f9814bb83/webextensions/resources/ui-color.css#L126-L131 Deprecated system colors were depend on the theme color of the platform (GNOME theme and so on) so new colors simulated by color-mix may be different from deprecated system colors. You can override them with a user style sheet like following, if you hope to apply colors exact same to the platform:

:root {
  --ThreeDShadow: rgb(xxx, xxx, xxx);
  --ThreeDHighlight: hsl(xxx, xxx, xxx);
  --MenuText: #RRGGBB;
  --Menu: #RGB;
}
mika commented 2 months ago

Thanks for your feedback!

FTR: I've got the same problem also with Firefox v115.15.0esr and TST v4.0.23, so it seems to be unrelated to the Firefox version, at least for me.

I don't have any desktop environment but am running only a minimal tiling window manager (i3) on Debian.

But what indeed works around the behavior for me is adjusting the user style sheet with this:

:root {
  --ThreeDShadow: #FFFFFF;
  --ThreeDHighlight: #9E9E9E9B;
}
piroor commented 2 months ago

@mika Run i3-config-wizard and open the file ~/.config/i3/config, if you have not prepared it. The generated file should contain color definitions of default color scheme.

mika commented 2 months ago

@mika Run i3-config-wizard and open the file ~/.config/i3/config, if you have not prepared it. The generated file should contain color definitions of default color scheme.

Ah interesting, thanks for the hint! Though I don't get any color definitions generated, maybe my i3 version is too old. :)

github-actions[bot] commented 2 months ago

This issue has been closed due to no response within 14 days after labeled as "fixed", 7 days after last reopened, and 7 days after last commented.