diff options
-rw-r--r-- | src/gmdocument.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/gmdocument.c b/src/gmdocument.c index f0ffb34c..209ebe71 100644 --- a/src/gmdocument.c +++ b/src/gmdocument.c | |||
@@ -1201,7 +1201,7 @@ void setThemeSeed_GmDocument(iGmDocument *d, const iBlock *seed) { | |||
1201 | (theme == gray_GmDocumentTheme && isDark_ColorTheme(colorTheme_App()))) { | 1201 | (theme == gray_GmDocumentTheme && isDark_ColorTheme(colorTheme_App()))) { |
1202 | const float primHue = hues[primIndex]; | 1202 | const float primHue = hues[primIndex]; |
1203 | const iHSLColor primBright = { primHue, 1, 0.6f, 1 }; | 1203 | const iHSLColor primBright = { primHue, 1, 0.6f, 1 }; |
1204 | const iHSLColor primDim = { primHue, 1, normLum[primIndex] + (theme == gray_GmDocumentTheme ? 0.0f : -0.3f), 1}; | 1204 | const iHSLColor primDim = { primHue, 1, normLum[primIndex] + (theme == gray_GmDocumentTheme ? 0.0f : -0.25f), 1}; |
1205 | const iHSLColor altBright = { altHue, 1, normLum[altIndex[0]] + (theme == gray_GmDocumentTheme ? 0.1f : 0.0f), 1 }; | 1205 | const iHSLColor altBright = { altHue, 1, normLum[altIndex[0]] + (theme == gray_GmDocumentTheme ? 0.1f : 0.0f), 1 }; |
1206 | setHsl_Color(tmQuote_ColorId, altBright); | 1206 | setHsl_Color(tmQuote_ColorId, altBright); |
1207 | setHsl_Color(tmPreformatted_ColorId, altBright); | 1207 | setHsl_Color(tmPreformatted_ColorId, altBright); |
@@ -1225,8 +1225,15 @@ void setThemeSeed_GmDocument(iGmDocument *d, const iBlock *seed) { | |||
1225 | /* Tone down the link colors a bit because bold white is quite strong to look at. */ | 1225 | /* Tone down the link colors a bit because bold white is quite strong to look at. */ |
1226 | if (isDark_GmDocumentTheme(theme) || theme == white_GmDocumentTheme) { | 1226 | if (isDark_GmDocumentTheme(theme) || theme == white_GmDocumentTheme) { |
1227 | iHSLColor base = { hues[primIndex], 1.0f, normLum[primIndex], 1.0f }; | 1227 | iHSLColor base = { hues[primIndex], 1.0f, normLum[primIndex], 1.0f }; |
1228 | set_Color(tmLinkText_ColorId, mix_Color(get_Color(tmLinkText_ColorId), | 1228 | if (theme == black_GmDocumentTheme || theme == gray_GmDocumentTheme) { |
1229 | rgb_HSLColor(base), 0.25f)); | 1229 | setHsl_Color(tmLinkText_ColorId, |
1230 | addSatLum_HSLColor(get_HSLColor(tmLinkText_ColorId), 0.0f, -0.15f)); | ||
1231 | } | ||
1232 | else { | ||
1233 | /* Tinted with base color. */ | ||
1234 | set_Color(tmLinkText_ColorId, mix_Color(get_Color(tmLinkText_ColorId), | ||
1235 | rgb_HSLColor(base), 0.25f)); | ||
1236 | } | ||
1230 | set_Color(tmHypertextLinkText_ColorId, get_Color(tmLinkText_ColorId)); | 1237 | set_Color(tmHypertextLinkText_ColorId, get_Color(tmLinkText_ColorId)); |
1231 | set_Color(tmGopherLinkText_ColorId, get_Color(tmLinkText_ColorId)); | 1238 | set_Color(tmGopherLinkText_ColorId, get_Color(tmLinkText_ColorId)); |
1232 | } | 1239 | } |