darktable icon indicating copy to clipboard operation
darktable copied to clipboard

Adhere to the system colouration.

Open RokeJulianLockhart opened this issue 1 year ago • 22 comments

Is your feature request related to a problem? Please describe.

Darktable looks utterly different to every application on my OS. It's jarring, and I can't think of any advantage of its custom appearance. Specifically, I sometimes have my OS set to a high contrast theme which Darktable can't match, and even when I don't, the inconsistency makes using the application unintuitive.

Describe the solution you'd like

Utilize the colouration applied by the OS/DE:

  • On Windows, utilize https://learn.microsoft.com/en-us/uwp/api/windows.ui.viewmanagement.uisettings.getcolorvalue?view=winrt-26100 (as https://stackoverflow.com/revisions/69815666/2 describes).
  • On GNOME or KDE, use the values in the gtkrc (or better yet, on KDE, adhere to the current .color file's INI-formatted values).

Alternatives

Utilize a GUI toolkit which automatically does so (like Qt). This is surely infeasible.

Additional context

  • ~~The current status-quo appears to cause issues at times, like unix.stackexchange.com/revisions/65088/1.~~
  • I'm not whatsoever suggesting CSD like https://github.com/darktable-org/darktable/issues/13555#issue-1573410812 does. Adherence to the DE's appearance in any manner except colouration is outside the purview of this issue. I also happen to not be fond of non-SSD.

RokeJulianLockhart avatar Aug 26 '24 20:08 RokeJulianLockhart

darktables themes are designed to avoid false color perception - so i doubt there’s a benefit in using arbitrary color schemes not designed with image color perception in scope …

Using an alternative gui toolkit isn’t a realistic solution - too much effort that doesn’t pay in into the core functionality of darktable…

MStraeten avatar Aug 26 '24 20:08 MStraeten

It's jarring, and I can't think of any advantage of its custom appearance.

While it's not that common in FLOSS applications, having custom colors is a very common practice in multimedia programs (as mentioned by @MStraeten to try to avoid color perception problems on edit sessions).

pitbuster avatar Aug 27 '24 01:08 pitbuster

Look at Da Vinci Resolve for example - it has its own dark color theme as well. If custom GUI colors cause some issues (like the one about file dialog, but it’s very old), those are to be fixed, not the color theme. So either specify what problems are there, or close this issue.

parafin avatar Aug 27 '24 04:08 parafin

If custom GUI colors cause some issues (like the one about file dialog, but it’s very old), those are to be fixed, not the color theme. So either specify what problems are there, or close this issue.

@parafin, the problems are those which I've listed in the relevant heading's contents, which I've now elaborated on. The "additional information" is merely as described, though I'm thankful for the correction.

https://github.com/darktable-org/darktable/issues/17378#issuecomment-2311393424

@pitbuster, I do in that case understand the default perhaps being a custom colour scheme, but I don't utilize Darktable for modifications much, and certainly not to the extent that colour perception is of enough consequence that I would want my high contrast theme overridden. I primarily use Darktable to import into applications.

https://github.com/darktable-org/darktable/issues/17378#issuecomment-2311044276

@MStraeten, you needn't concern yourself with that - it was noted solely because the template requested it, and I explicitly listed it in the issue as infeasible.

RokeJulianLockhart avatar Aug 28 '24 14:08 RokeJulianLockhart

I think high contrast theme was recently added to darktable, if that’s the problem you’re having. Just using default colors will probably look very ugly, because GUI is designed with custom colors. There isn’t really any value in supporting native DE theme, what problem will that solve?

parafin avatar Aug 28 '24 15:08 parafin

I think high contrast theme was recently added to darktable, if that’s the problem you’re having.

@parafin, each user theme, especially each high contrast theme, differs, because different people shall find different colours easier to parse. Even Windows allows you to customise solely the HC themes for this reason, despite their hostility to user theming.

There isn’t really any value in supporting native DE theme, what problem will that solve?

I've already provided rationale, so I don't understand the question. Would repeating it summarily or more concisely be of use, perhaps?

This might be more useful - as an example of what I request being implemented:

  1. GIMP recently switched from GTK2 with custom themes to GTK3, which adheres to the system colours via the gtkrc on KDE 5/6, and directly on GNOME 30/40.

  2. KdenLive allows the user to choose a theme, but also provides a "Default" option, which adheres to the system's colour theme (and widget style, in its case):

    Screenshot_20240828_162734

RokeJulianLockhart avatar Aug 28 '24 15:08 RokeJulianLockhart

So it is about high contrast theme? Well, as I said, just using default colors will most likely look ugly. Your best bet is to write your own theme, there is a text field for that in the preferences.

parafin avatar Aug 28 '24 15:08 parafin

Your best bet is to write your own theme, there is a text field for that in the preferences.

@parafin, even if I did, that would merely affect me, which isn't acceptable. If I have this problem, others do.

So it is about high contrast theme?

The scope of this issue encompasses all that I've aforementioned, which includes more than merely HC themes. ...that is, non-HC themes too.

Well, as I said, just using default colors will most likely look ugly.

Why? They don't for the rest of my OS.

RokeJulianLockhart avatar Aug 28 '24 15:08 RokeJulianLockhart

darktable never used default colors, so noone ever checked or cared how it will look with them when designing the GUI. I can’t imagine this process producing good results with default DE theme.

parafin avatar Aug 28 '24 15:08 parafin

High contrast theme is about accessibility. This is a valid topic, and, as I mentioned, high contrast theme was recently added. Sure, it’s not much, but there aren’t many people working on darkable as a whole. GIMP and kdenlive you mentioned surely have much larger development teams.

As for non-HC themes - you’ve already been given explanation and example of why custom colors are needed for applications like darktable. Just because you’re using it just as a file format converter (if I understood correctly) doesn’t mean it should be designed for that purpose. One application can’t and shouldn’t try to fit all use-cases.

parafin avatar Aug 28 '24 15:08 parafin

But maybe some darktable developer will take time and effort to try your idea of using default colors. It’s just that I don’t think that quality of the results will be acceptable for inclusion in main codebase… Just my opinion.

parafin avatar Aug 28 '24 15:08 parafin

As for non-HC themes - you’ve already given explanation and example of why custom colors are needed for applications like darktable. Just because you’re using it just as a file format converter (if I understood correctly) doesn’t mean it should be designed for that purpose. One application can’t and shouldn’t try to fit all use-cases.

@parafin, I believe that I've aforestated that I would consider this to apply irrespectively, because I don't ever perform modifications so minor that colour misperception would be of significant enough consequence to justify a custom theme (and if it were, I would apply one to my entire DE, so that the effect would not be reduced when switching between applications side-by-side).

darktable never used default colors, so noone ever checked or cared how it will look with them when designing the GUI. I can’t imagine this process producing good results with default DE theme.

As an example, /usr/share/color-schemes/BreezeDark.colors contains the undermentioned RGB values:

[ColorEffects:Disabled]
Color=56,56,56
ColorAmount=0
ColorEffect=0
ContrastAmount=0.65
ContrastEffect=1
IntensityAmount=0.1
IntensityEffect=2

[ColorEffects:Inactive]
ChangeSelectionColor=true
Color=112,111,110
ColorAmount=0.025
ColorEffect=2
ContrastAmount=0.1
ContrastEffect=2
Enable=false
IntensityAmount=0
IntensityEffect=0

[Colors:Button]
BackgroundAlternate=30,87,116
BackgroundNormal=49,54,59
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=161,169,177
ForegroundLink=29,153,243
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=252,252,252
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Complementary]
BackgroundAlternate=30,87,116
BackgroundNormal=42,46,50
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=161,169,177
ForegroundLink=29,153,243
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=252,252,252
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Header]
BackgroundAlternate=42,46,50
BackgroundNormal=49,54,59
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=161,169,177
ForegroundLink=29,153,243
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=252,252,252
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Header][Inactive]
BackgroundAlternate=49,54,59
BackgroundNormal=42,46,50
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=161,169,177
ForegroundLink=29,153,243
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=252,252,252
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Selection]
BackgroundAlternate=30,87,116
BackgroundNormal=61,174,233
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=252,252,252
ForegroundInactive=161,169,177
ForegroundLink=253,188,75
ForegroundNegative=176,55,69
ForegroundNeutral=198,92,0
ForegroundNormal=252,252,252
ForegroundPositive=23,104,57
ForegroundVisited=155,89,182

[Colors:Tooltip]
BackgroundAlternate=42,46,50
BackgroundNormal=49,54,59
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=161,169,177
ForegroundLink=29,153,243
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=252,252,252
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:View]
BackgroundAlternate=35,38,41
BackgroundNormal=27,30,32
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=161,169,177
ForegroundLink=29,153,243
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=252,252,252
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Window]
BackgroundAlternate=49,54,59
BackgroundNormal=42,46,50
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=161,169,177
ForegroundLink=29,153,243
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=252,252,252
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[General]
ColorScheme=BreezeDark
Name=Breeze Dark
Name[ar]=نسيم داكن
Name[az]=Breeze - Tünd
Name[bg]=Breeze Тъмен
Name[bs]=Breeze tamna
Name[ca]=Brisa fosca
Name[ca@valencia]=Brisa fosca
Name[cs]=Breeze Tmavé
Name[da]=Breeze Dark
Name[de]=Breeze Dunkel
Name[el]=Breeze σκούρο
Name[en_GB]=Breeze Dark
Name[eo]=Breeze Dark
Name[es]=Brisa oscuro
Name[et]=Breeze tume
Name[eu]=Breeze iluna
Name[fi]=Tumma Breeze
Name[fr]=Brise sombre
Name[gl]=Brisa escura
Name[he]=בריזה כהה
Name[hi]=ब्रीज़ गहरा
Name[hu]=Breeze Dark
Name[ia]=Brisa obscure
Name[id]=Breeze Gelap
Name[is]=Breeze dökkt
Name[it]=Brezza scuro
Name[ja]=Breeze ダーク
Name[ka]=Breeze მუქი
Name[ko]=어두운 Breeze
Name[lt]=Breeze tamsus
Name[lv]=Breeze Dark
Name[nb]=Breeze mørk
Name[nl]=Breeze Dark
Name[nn]=Breeze mørk
Name[pa]=ਬਰੀਜ਼ ਗੂੜ੍ਹਾ
Name[pl]=Ciemna Bryza
Name[pt]=Brisa Escura
Name[pt_BR]=Breeze Dark
Name[ro]=Briză, întunecat
Name[ru]=Breeze, тёмный вариант
Name[sk]=Tmavý vánok
Name[sl]=Sapica, temna
Name[sr]=Поветарац тамни
Name[sr@ijekavian]=Поветарац тамни
Name[sr@ijekavianlatin]=Povetarac tamni
Name[sr@latin]=Povetarac tamni
Name[sv]=Breeze mörk
Name[tg]=Насими торик
Name[tr]=Esinti Koyu
Name[uk]=Темна Breeze
Name[x-test]=xxBreeze Darkxx
Name[zh_CN]=Breeze 微风深色
Name[zh_TW]=Breeze Dark
shadeSortColumn=true

[KDE]
contrast=4

[WM]
activeBackground=49,54,59
activeBlend=252,252,252
activeForeground=252,252,252
inactiveBackground=42,46,50
inactiveBlend=161,169,177
inactiveForeground=161,169,177

...which renders as the undermentioned depicts:

image

I don't see how this fundamentally differs to your embedded "darktable" theme:

Screenshot_20240828_165257

Were I to customise those values such that they retained the current luminosity but were monochromatic (instead of grey-blue), there would be so little difference that few would notice.

RokeJulianLockhart avatar Aug 28 '24 15:08 RokeJulianLockhart

If it’s that easy, I wonder why nobody has done it so far?.. Maybe you should try it yourself?

parafin avatar Aug 28 '24 16:08 parafin

If it’s that easy, I wonder why nobody has done it so far?

@parafin, I've not deliberately communicated that implementing it would be trivial. I doubt that speculation as to why it's not been done yet would be of much practical use, but I presume that it is a combination of:

  1. Your and the other respondents' aforementioned opinions that colour perception matters to you all more than theme consistency; and:
  2. Difficulty implementing a cross-platform feature that necessarily consumes DE and OS-specific configuration values.

Maybe you should try it yourself?

Your codebase is primarily C. That's not my purview. Unfortunately, my skillset is QtWidgets 6 with Python 3.12, or CLI PowerShell Core 7+. The former already adheres to such preferences by default, and the latter doesn't apply in any respect here. Thanks for the suggestion, though.

RokeJulianLockhart avatar Aug 28 '24 18:08 RokeJulianLockhart

Theming right now (in GTK3) is done almost exclusively through CSS (meaning available darktable themes are .css files). So no C coding skills are required to create a new theme. There are also some helper tools like gtk-inspector, which ease this task. So trying it may be simpler than you think;)

parafin avatar Aug 28 '24 18:08 parafin

https://github.com/darktable-org/darktable/issues/17378#issuecomment-2316028945

@parafin, that wouldn't resolve this issue, because the theme would still be static. CSS3 is a stylisation language doesn't possess the functionality to dynamically acquire OS information - that would be the purview of the underlying language, which would then provide the toolkit with those values. Thanks, though.

RokeJulianLockhart avatar Aug 28 '24 19:08 RokeJulianLockhart

This issue has been marked as stale due to inactivity for the last 60 days. It will be automatically closed in 300 days if no update occurs. Please check if the master branch has fixed it and report again or close the issue.

github-actions[bot] avatar Oct 28 '24 00:10 github-actions[bot]

darktables themes are designed to avoid false color perception

It seems to me that there is room for improvement in this part:

Image

Foreground: #939393 Background: #6A6A6A Contrast ratio: 1.761:1 1.4.3 Contrast (Minimum) (AA) ❌ Fail for large and regular text 1.4.6 Contrast (Enhanced) (AAA) ❌ Fail for large and regular text

Foreground: #F1F1F1 Background: #919191 Contrast ratio: 2.79:1 1.4.3 Contrast (Minimum) (AA) ❌ Fail for large and regular text 1.4.6 Contrast (Enhanced) (AAA) ❌ Fail for large and regular text

Foreground: #B4B4B4 Background: #6A6A6A Contrast ratio: 2.609:1 1.4.11 Non-text Contrast (AA) ❌ Fail for UI components and graphical objects

Web Content Accessibility Guidelines (WCAG) 2.2


darktable 5.0.1 Microsoft Windows 10.0.19045.5555

Korb avatar Feb 27 '25 15:02 Korb

This issue has been marked as stale due to inactivity for the last 60 days. It will be automatically closed in 300 days if no update occurs. Please check if the master branch has fixed it and report again or close the issue.

github-actions[bot] avatar Apr 29 '25 00:04 github-actions[bot]

https://github.com/darktable-org/darktable/issues/17378#issuecomment-2316077010

@parafin, I've since ascertained that I was incorrect about the CSS3 standard not supporting it:

  1. color-scheme: light dark; enables a parser to explicitly adhere to the org.freedesktop.appearance color-scheme preference.

  2. accent-color: auto; enables a parser to explicitly adhere to the org.freedesktop.appearance accent-color preference.

RokeJulianLockhart avatar Apr 29 '25 07:04 RokeJulianLockhart

This issue has been marked as stale due to inactivity for the last 60 days. It will be automatically closed in 300 days if no update occurs. Please check if the master branch has fixed it and report again or close the issue.

github-actions[bot] avatar Jun 29 '25 00:06 github-actions[bot]

https://github.com/darktable-org/darktable/issues/17378#issuecomment-3016184629

I believe that this should remain open, but have nothing else to add.

RokeJulianLockhart avatar Jun 29 '25 00:06 RokeJulianLockhart

This issue has been marked as stale due to inactivity for the last 60 days. It will be automatically closed in 300 days if no update occurs. Please check if the master branch has fixed it and report again or close the issue.

github-actions[bot] avatar Aug 30 '25 00:08 github-actions[bot]

https://github.com/darktable-org/darktable/issues/17378#issuecomment-3238755933

I have rewritten the issue to provide some actionable programmatic improvements.

RokeJulianLockhart avatar Aug 30 '25 09:08 RokeJulianLockhart

This issue has been marked as stale due to inactivity for the last 60 days. It will be automatically closed in 300 days if no update occurs. Please check if the master branch has fixed it and report again or close the issue.

github-actions[bot] avatar Oct 31 '25 00:10 github-actions[bot]