mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-03-02 22:57:32 -05:00
Default locale in options dialog is broken #5023
Labels
No labels
Accessibility
AppImage
Bounty
Build system
CI
Can't reproduce
Code cleanup
Confirmed bug
Confirmed bug
Core
Crash
Data loss
Discussion
Docker
Documentation
Duplicate
Feature
Feature request
Feature request
Feature request
Filters
Flatpak
GUI
Has workaround
I2P
Invalid
Libtorrent
Look and feel
Meta
NSIS
Network
Not an issue
OS: *BSD
OS: Linux
OS: Windows
OS: macOS
PPA
Performance
Project management
Proxy/VPN
Qt bugs
Qt6 compat
RSS
Search engine
Security
Temp folder
Themes
Translations
Triggers
Waiting diagnosis
Waiting info
Waiting upstream
Waiting web implementation
Watched folders
WebAPI
WebUI
autoCloseOldIssue
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/qBittorrent#5023
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @zeule on GitHub (Dec 20, 2016).
When I start qBt with a fresh profile and open the options dialogue, qBt finds that locale is unset and tries to select the default one (English). And it fails, at least on my system. The problem is the following: qBt thinks that default locale is "en" and looks for one defined by
QLocale("en").name(). But there is no locale named "en"!QLocale("en").name()return "en_US" (correct locale name), yet there is no such locale in the qBt localisation list. Instead there is "en". AFAICT, "en" translation file has to be renamed into "en_US", and the call inOptionsDialog::setLocale()shall use "en_US" as the fallback.@sledgehammer999 commented on GitHub (Dec 22, 2016):
The supposed sequence(from my memory) is:
So what do you mean it "fails on my system"? What language do you get?
@zeule commented on GitHub (Dec 22, 2016):
I get an assert in line 1317 of optionsflg.cpp (and no language selected if asserts are disabled).
That's is the problem. There is no locale with name "en", and Qt transforms the name to "en_US", but the translation file is named "en" and as such there is no entry "en_US" in
m_ui->comboI18n.