| 411 | } |
| 412 | |
| 413 | QString ModulatorCell::doubleToString(double value) |
| 414 | { |
| 415 | // Return a value as a string with 3 maximum characters after the decimal separator |
| 416 | QString txt = QLocale::system().toString(value, 'f', 3); |
| 417 | while (txt.size() > 1 && (txt.endsWith("0"))) |
| 418 | txt = txt.left(txt.size() - 1); |
| 419 | if (txt.size() > 1 && (txt.endsWith(".") || txt.endsWith(","))) |
| 420 | txt = txt.left(txt.size() - 1); |
| 421 | return txt; |
| 422 | } |