-
Notifications
You must be signed in to change notification settings - Fork 31
feat: add unit system setting in gui tab #680
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Tomas Fabrizio Orsi <[email protected]>
Signed-off-by: Tomas Fabrizio Orsi <[email protected]>
…unit setting in gui tab Signed-off-by: Tomas Fabrizio Orsi <[email protected]>
Signed-off-by: Tomas Fabrizio Orsi <[email protected]>
…leUnitDistance Signed-off-by: Tomas Fabrizio Orsi <[email protected]>
Some additional notes:
Thanks in advance! Have a nice week 😊 |
Thank you for you patch. As usual, I have to ask, what is the motivation? The units are automatically selected according to the settings in the OS. What is the motivation to have this setting different from the user's preferred settings in the OS? |
Hi Foldynl! My main motivation is that, when I opened QLog, it was using Imperial units and I wasn't able to change them. I wasn't able to find an easy way to change my system's With this patch, I was able to display the distance using the metric system without having to go into the Linux rabbit hole of "how do I change my system's QLocale without messing up the rest of my system". As an added bonus, having this setting could serve useful when speaking with another ham that uses a different unit system. Hope that explains my reasoning. Cheers! 😊 PS: I'm more than willing to tune this PR with any modifications you see fit. |
Measurement unit is controlled by an environment variable I made an exception for the date and time but I wouldn’t want to replicate settings that are handled elsewhere in the operating system. |
Oh I see! I was not aware of that env variable, I'll let you know if that works on my system. Thanks ^_^ |
Hi @foldynl. I did manage to change the Although, I do get the following warning:
Tbh, I don't think I'm the biggest fan of having to change the Regardless, thanks for the help! Cheers 😊 |
Update: It did mess up with some utilities, so customization of the Context btw:
This was raised by Gentoo's So I'd say changing that env variable is a no-go. Have you ever modified it successfully? |
If I run I'm not a Gentoo expert, but on Ubuntu, you need to have the required locale installed. |
Oh I see, I passed |
AFAIK, one's system's QLocale setting determines the unit system in which distances are displayed, i.e. Metric or Imperial.
This patch adds a new setting in the GUI tab to set a QLog specific preference, without having to modify the unit system used system-wide.
The current implementation looks like this:

Would love to get some feedback on this!
PS: QLog is awesome, thanks for all the work.