Summary: | KIntNumInput handles keyboard input incorrectly when suffixes are enabled | ||
---|---|---|---|
Product: | [Unmaintained] kdelibs | Reporter: | albert <alberthilbert> |
Component: | kdeui | Assignee: | kdelibs bugs <kdelibs-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | aacid, sven.burmeister |
Priority: | NOR | ||
Version: | SVN | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | Quick patch that seems to fix the problem |
Description
albert
2008-03-13 13:49:15 UTC
Nothing fancy in the way we use that standard KDE widget. The problem seems related to the usage of a suffix for the spinbox. Commenting out its usage by the opacity spinbox in Okular makes it working normally. KMail has the same problem, it uses "bytes" as suffix, and keyboard input does not work correctly. Basically KIntSpinBox::textFromValue and KIntSpinBox::valueFromText ignore the fact that the text can have a suffix so it does not work, using the QSpinBox variants is not possible there because we have the very useful base setting that probably noone uses but breaks the 99% used code :-/ Created attachment 23888 [details]
Quick patch that seems to fix the problem
I was about to commit it, but i'd want some comments first
SVN commit 785377 by aacid: chop the suffix before doing the int conversion BUG: 159239 M +3 -1 knuminput.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=785377 |