Dark mode for Qt6#1488
Open
TheForgotten69 wants to merge 21 commits into
Open
Conversation
9b5f76b to
8e22038
Compare
dxqb
added a commit
to dxqb/OneTrainer
that referenced
this pull request
Jun 3, 2026
SetProcessDpiAwareness was intended for CustomTkinter only; Qt handles DPI natively and the call is not needed here. Suggested by PR Nerogar#1488. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Collaborator
|
this PR is empty now, because it was based on "preview" and "preview" is now updated to include your PR. |
factory.register() now detects whether its second argument is a type (direct call form for loops) or an enum key (decorator form), allowing implementations to declare themselves with @factory.register() directly on the class definition instead of imperative calls at the bottom of the file. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… Qt6) into preview
…d "Text Caching") into preview
…-component) into preview
…ng) into preview
Qt's dark mode support on Windows is broken (tabs render with no contrast). apply_theme() applies explicit palette and QSS fixes on Windows only, using palette() references so it adapts to the system light/dark preference. Linux/macOS are left to Qt's native handling. Replaces the previous force-light-mode workaround in train_ui_qt.py.
55b7283 to
81dfba6
Compare
Contributor
Author
|
dark mode is scoped only on window, no custom styles either as the hardcoded white theme is handled |
Collaborator
|
thanks! will mark this waiting and come back to it when the Qt branch has merged |
ce63c57 to
3c96784
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fix various small issues that occured on Windows:
preference. Linux/macOS keep Qt's native theming untouched.
(QTabWidget::pane / QTabBar contrast fixes + an adaptive progressbar) plus a white text-box fix for light mode — since
Qt's dark mode renders tabs with no contrast on Windows.
The important gist is that the preferred mode is now respected and both light and dark are usable.
Test plan
pre-commit run --all-filespassesAI assistance