Resolve relative UI theme paths#24514
Conversation
@TurboTheTurtle |
Fair point. I updated my PRs to remove those blocks and made a note to avoid them in the future |
|
Windows proof for latest head I tested the PR-head Windows CI artifact on a real Windows 11 machine:
The test theme file was intentionally not a valid Qt resource, so successful path resolution should still produce a load warning that names the resolved file. The app was launched from the isolated profile, allowed to initialize, then stopped after the proof line was written. Observed qBittorrent log line: Proof checks from the harness: {
"marker": "PR24514-WINDOWS-RELATIVE-THEME-20260614",
"configuredRelativeTheme": "themes/pr24514-relative.qbtheme",
"logContainsAppDirThemePath": true,
"logContainsRawRelativeOnly": false
}This confirms the Windows GUI artifact resolves a relative custom UI theme path against |
| if (themePath.isAbsolute()) | ||
| return themePath; | ||
|
|
||
| return (Path(QCoreApplication::applicationDirPath()) / themePath); |
There was a problem hiding this comment.
Shouldn't you use the profile folder path instead of app dir path?
a464881 to
dcebf9f
Compare
dcebf9f to
8edf92d
Compare
|
Adjusted this so the stored preference and Options field stay as entered, and relative theme paths are resolved only when the theme manager loads them. The resolution now goes through the existing profile path conversion instead of the application directory. |



Closes #24489.
Resolves relative custom UI theme paths against the application directory while preserving existing absolute path behavior.
Proof
Validated on Windows using the PR-head CI artifact.
themes/pr24514-relative.qbtheme