Bug 484820 - Unreadable text in QML Dialog breadcrumb bar
Summary: Unreadable text in QML Dialog breadcrumb bar
Status: RESOLVED NOT A BUG
Alias: None
Product: frameworks-qqc2-desktop-style
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: 6.0.0
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: kdelibs bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-31 14:46 UTC by neobrain
Modified: 2024-09-05 11:13 UTC (History)
5 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Dialog with unreadable breadcrumb bar (47.12 KB, image/png)
2024-03-31 14:46 UTC, neobrain
Details

Note You need to log in before you can comment on or make changes to this bug.
Description neobrain 2024-03-31 14:46:33 UTC
Created attachment 167987 [details]
Dialog with unreadable breadcrumb bar

SUMMARY
The non-native QML fallbacks for FileDialog and FolderDialog are customized by qqc2-desktop-style, but their breadcrumb bars don't seem to be. When Plasma is configured to use the Breeze Dark color scheme, this makes the folder names in the breadcrumb bar unreadable, since they're rendered in the same color as the background (both white).

```
import QtQuick
import QtQuick.Controls
import QtQuick.Dialogs

Item {
    width: 800
    height: 600

    Button {
        text: "Open dialog"
        onClicked: theDialog.open()
    }

    FolderDialog {
        id: theDialog
        options: FolderDialog.DontUseNativeDialog
    }
}
```

STEPS TO REPRODUCE
1. Copy-paste the above QML source to a file
2. Set up Breeze Dark color theme
3. Run `qml6 file.qml`

OBSERVED RESULT
The individual folder names in the breadcrumb bar are unreadable

EXPECTED RESULT
The folder names should either be rendered as black-on-white or as white-on-black text.

SOFTWARE/OS VERSIONS
Linux 
KDE Plasma Version: 6.0.3
KDE Frameworks Version: 6.0.0
Qt Version: 6.6.3

ADDITIONAL INFORMATION
qqc2-breeze-style also appears to be affected by this.
Comment 1 Nate Graham 2024-09-04 03:31:37 UTC
This is a Qt bug... sort of. More like an incompatibility between how they do colors and how we do colors. It's for this reason that we override the default dialogs with our own. Intentionally breaking that is not supported.
Comment 2 neobrain 2024-09-05 09:42:54 UTC
That's a bummer. I'm not sure I can use the native dialogs, since I'm using QQuickRenderControl to render a QML file into a manually managed window. Maybe I just need to dig deeper into the Qt documentation to find a way to enable native dialogs either way though.

Thanks for the explanation!
Comment 3 Nate Graham 2024-09-05 11:13:31 UTC
You're welcome! Hope you find something that works out.