diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2015-07-01 11:17:08 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2015-07-01 13:01:20 +0200 |
commit | ed92ea867bfedef890ce48b26a00bad0bfc79caf (patch) | |
tree | 377a352c9117b4b5726dbe6d0f2ab381fed1219e /qfunctionconfigurator/qfunctionconfigurator.cpp | |
parent | 891f5d68a5bc8bdd565f13cd38160948d8a7fb6a (diff) |
qfc: always draw line to last point
Diffstat (limited to 'qfunctionconfigurator/qfunctionconfigurator.cpp')
-rw-r--r-- | qfunctionconfigurator/qfunctionconfigurator.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/qfunctionconfigurator/qfunctionconfigurator.cpp b/qfunctionconfigurator/qfunctionconfigurator.cpp index b230cfb1..e1c40396 100644 --- a/qfunctionconfigurator/qfunctionconfigurator.cpp +++ b/qfunctionconfigurator/qfunctionconfigurator.cpp @@ -141,6 +141,11 @@ void QFunctionConfigurator::drawFunction() drawLine(&painter, prev, cur, pen); prev = cur; } + if (points.size()) + { + auto last = point_to_pixel(points[points.size()-1]); + drawLine(&painter, prev, last, pen); + } } void QFunctionConfigurator::paintEvent(QPaintEvent *e) |