Review Request 127570: take advantage of "orientability" of arcs to solve a couple of longstanding problems for arcs by 3 points subject to change of concavity

Maurizio Paolini paolini at dmf.unicatt.it
Sun Apr 10 14:49:29 UTC 2016


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/127570/
-----------------------------------------------------------

(Updated April 10, 2016, 2:49 p.m.)


Status
------

This change has been marked as submitted.


Review request for KDE Edu and David Narváez.


Repository: kig


Description
-------

ArcBTPType can change concavity upon moving the defining points.  In such a situation the construction of the firstEndPoint and secondEndPoint properties get swapped and can lead to subsequent constructions that change abruptly.

Similarly the getPoint and getParam methods (that transform parameter t in [0,1] to a point in the arc and viceversa) is
not defined smoothly upon change of concavity.
A consequence of this is e.g. the sudden change of position of labels attached to an arc when the arc changes concavity.

The first problem is addressed by a test in the firstEndPoint and secondEndPoint methods.

The second problem is addressed by changing t in 1-t in both getParam and getPoint methods when mradius < 0.


Diffs
-----

  objects/other_imp.cc 7bc143e 

Diff: https://git.reviewboard.kde.org/r/127570/diff/


Testing
-------

The first problem can be made apparent with the following construction:

1. Construct an arc by three points (say A, P, B)
2. Hide points A and B
3. Right-click on the arc and select Construct->First End Point
4. Move point P so that the the arc becomes a segment and then changes its concavity

Without the proposed patch observe the sudden jump of the newly created point

Similarly, the second problem becomes apparent with the further step:

5. Right-click on the arc (in a position near an end-point) and select "Add Text Label->(any choice)"
6. Move point P as before


File Attachments
----------------

kig construction showing the problem
  https://git.reviewboard.kde.org/media/uploaded/files/2016/04/04/0d3f9dc5-06eb-4ec1-8b54-57ffc0c97b10__arc_param.kig
snapshot of the kig file construction
  https://git.reviewboard.kde.org/media/uploaded/files/2016/04/04/b8532477-262c-4d0a-9c19-a1b3ce0e98a3__arc_param.png


Thanks,

Maurizio Paolini

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-edu/attachments/20160410/0b9046a9/attachment.html>


More information about the kde-edu mailing list