Summary: | [PATCH] MPa and PSI aren't marked as common units | ||
---|---|---|---|
Product: | [Frameworks and Libraries] frameworks-kunitconversion | Reporter: | Nate Graham <nate> |
Component: | general | Assignee: | John Layt <jlayt> |
Status: | RESOLVED FIXED | ||
Severity: | wishlist | CC: | kde, kdelibs-bugs, nate |
Priority: | NOR | ||
Version: | 5.33.0 | ||
Target Milestone: | --- | ||
Platform: | openSUSE | ||
OS: | Linux | ||
Latest Commit: | https://commits.kde.org/kunitconversion/11a8590d0e83a474d76aa6f2d90b0d4b5fadaebc | Version Fixed In: | |
Sentry Crash Report: | |||
Attachments: |
Patch
Patch |
Description
Nate Graham
2017-04-24 18:33:20 UTC
Re-assigning to KUnitconversion framework which the units runner uses, it just asks it "what are the common units for 'pressure'" and then it returns these, and while it knows MPa and psi they're not flagged as "common" in there. Btw if you want to give it a go, you can find the definitions for pressure in kunitconversion/src/pressure.cpp, note the addUnit vs addCommonUnit Ok great, I can submit a patch for that! Thanks for your help! Created attachment 105176 [details]
Patch
Hektopascal certainly is a very common unit in meteorology (at least here in Germany). Created attachment 106772 [details]
Patch
Here's a new patch that doesn't change anything for HPa, and just marks MPa and PSI as common.
Thanks for your patch. Please upload it to phabricator.kde.org for developers to review it - patches on Bugzilla get easily overlooked. Thanks. Here you go: https://phabricator.kde.org/D6808 Git commit 11a8590d0e83a474d76aa6f2d90b0d4b5fadaebc by Albert Astals Cid, on behalf of Nathaniel Graham. Committed on 22/07/2017 at 07:51. Pushed by aacid into branch 'master'. Mark MPa and PSI as common units Differential Revision: https://phabricator.kde.org/D6808 M +2 -2 src/pressure.cpp https://commits.kde.org/kunitconversion/11a8590d0e83a474d76aa6f2d90b0d4b5fadaebc |