Summary: | Sliders using RDoubleNumInput are not precise | ||
---|---|---|---|
Product: | [Unmaintained] kdelibs | Reporter: | Julien Narboux <Julien> |
Component: | kdeui | Assignee: | kdelibs bugs <kdelibs-bugs> |
Status: | RESOLVED DUPLICATE | ||
Severity: | normal | CC: | caulier.gilles, cfeck |
Priority: | NOR | ||
Version: | SVN | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Julien Narboux
2009-11-29 12:03:38 UTC
We use this widget : http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKDoubleNumInput.html from libkdcraw : http://lxr.kde.org/source/KDE/kdegraphics/libs/libkdcraw/libkdcraw/rnuminput.cpp#163 Try to look if an option is not missing somewhere to setup KDoubleNumInput. Note : problem is reproducible with trunk code If there is no option missing, it's a problem with KDELibs Gilles Caulier As far as I know, it is a KDElibs issue Some remarks, which may, or may not be obvious. 1. A slider cannot generate more distinct values than the number of pixels it has, so the precision depends on the range of values that you want to set. For example, if your slider has a range of 0 ... 1000, but is only 200 pixels wide, you can only change values in steps of 5 units. If the behavior of KDoubleNumInput is worse, please attach a testcase. 2. From looking at rnuminput.cpp, the slider does not use the exponential slider feature (setExponentRatio), which is especially suited for gamma values (e.g. changing in the range of 0.5 ... 2.0, where 1.0 is the center value). You could try, if this helps. Hi, Thanks for your answers. 1 - Yes it is worse than that in our test case, it is as if there were some kind of "snap to grid". The slider can be put only at 10 positions whereas it is clearly longer than 10 pixels. 2 - I discovered the setExponetnRatio today, you are right it should be used in Digikam for many sliders. Julien *** This bug has been marked as a duplicate of bug 168022 *** |