diff options
| author | Stanislaw Halik <sthalik@misaki.pl> | 2019-08-01 10:44:01 +0200 | 
|---|---|---|
| committer | Stanislaw Halik <sthalik@misaki.pl> | 2019-08-01 10:45:13 +0200 | 
| commit | 8fbcdf775660a0cc1857e8bedee7ac2351292aa6 (patch) | |
| tree | 359200fc5b57fc5ca33ba80bc1218060b42dcc92 | |
| parent | 9b07c79a0d732695e22bae69f7821bd0e88416ff (diff) | |
spline: don't use faulty devicePixelRatioF()
| -rw-r--r-- | spline/spline-widget.cpp | 4 | 
1 files changed, 2 insertions, 2 deletions
diff --git a/spline/spline-widget.cpp b/spline/spline-widget.cpp index fd07bf78..0dfac0e9 100644 --- a/spline/spline-widget.cpp +++ b/spline/spline-widget.cpp @@ -185,8 +185,8 @@ void spline_widget::drawFunction()      painter.setPen(QPen(color_, 2, Qt::SolidLine, Qt::FlatCap)); -    const double dpr = devicePixelRatioF(); -    const double line_length_pixels = std::fmax(1, 2 * dpr); +    const double dpr = screen_dpi(); +    const double line_length_pixels = std::fmax(1, dpr);      const double step = std::fmax(.1, line_length_pixels / c.x());      const double maxx = config->max_input();  | 
