Skip to content

Commit

Permalink
Merge pull request #2847 from abhibeckert/master
Browse files Browse the repository at this point in the history
#2753 make it more obvious that a colored tab is inactive
  • Loading branch information
abhibeckert committed Aug 4, 2017
2 parents b920062 + 08e3de5 commit e59f679
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.m
Expand Up @@ -630,6 +630,9 @@ - (NSColor *)fillColorForCell:(PSMTabBarCell *)cell
if([cell backgroundColor]) {
//should be a slightly darker variant of the color
fillColor = [[cell backgroundColor] shadowWithLevel:0.15];

// also desaturate the color
fillColor = [NSColor colorWithCalibratedHue:fillColor.hueComponent saturation:fillColor.saturationComponent * 0.4 brightness:fillColor.brightnessComponent alpha:1.0f];
}
}
} else {
Expand All @@ -651,7 +654,7 @@ - (NSColor *)fillColorForCell:(PSMTabBarCell *)cell
//make it dark first, then desaturate
if (cell.backgroundColor) {
NSColor *dark = [[cell backgroundColor] shadowWithLevel:0.15];
fillColor = [NSColor colorWithCalibratedHue:dark.hueComponent saturation:dark.saturationComponent brightness:(dark.brightnessComponent * 1.28) alpha:1.0f];
fillColor = [NSColor colorWithCalibratedHue:dark.hueComponent saturation:dark.saturationComponent * 0.15 brightness:(dark.brightnessComponent * 1.28) alpha:1.0f];
}
}
}
Expand Down

0 comments on commit e59f679

Please sign in to comment.