Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Advanced digitizing - circle intersection #9569

Merged
merged 4 commits into from
Jan 22, 2025
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1765,6 +1765,21 @@ At the top of the :guilabel:`Digitizing panel`, you find the following buttons:
(more at :ref:`parallel_or_perpendicular`)
* |cadPerpendicular| :sup:`Perpendicular` to draw a line perpendicular to an
existing one (more at :ref:`parallel_or_perpendicular`)
* |extractVertices| :sup:`Construction Tools` provides a couple of options that
constrain the vertices placement based on extrapolated coordinates of
existing elements:

* |unchecked| :guilabel:`Line Extension`: hover over a segment and you get
a purple dotted line extending the segment across the map canvas.
You can snap the vertex anywhere on this virtual line.
* |unchecked| :guilabel:`X/Y Point`: hover over a vertex and you get
a purple dotted line along its X or Y coordinate, across the map canvas.
You can snap the vertex anywhere on this virtual line.
It is even possible to hover over two different vertices, generating virtual
coordinate lines for both, and snap to their intersection.
* |circleIntersection| :sup:`2-circle Point Intersection`: allows you to
digitize a point or vertex at the intersection of two circles.
(more at :ref:`circle_intersection`).
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be indented

Suggested change
* |circleIntersection| :sup:`2-circle Point Intersection`: allows you to
digitize a point or vertex at the intersection of two circles.
(more at :ref:`circle_intersection`).
* |circlesIntersection| :sup:`2-circle Point Intersection`: allows you to
digitize a point or vertex at the intersection of two circles.
(more at :ref:`circle_intersection`).

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I don’t understand why it needs to be indented, as it’s in line with the other items. If we indent it, I’m afraid it might look like it belongs to the construction tools...
image

Copy link
Collaborator Author

@selmaVH1 selmaVH1 Jan 22, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nirvn @DelazJ Sorry, my mistake. So, the tool from which we get the (drop-down) 2-circle point intersection does not have a tooltip in the GUI, but we can call it 'construction tools'? We describe it that way, but I'm not sure now...
image

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So, the tool from which we get the (drop-down) 2-circle point intersection does not have a tooltip in the GUI

Indeed. I asked for a name at qgis/QGIS#57648 (comment). Let's expect we get something...

but we can call it 'construction tools'? We describe it that way, but I'm not sure now...

No "Construction tools" is the one on the left so can't be used. Let's remove that mention in the meantime (and ignore the drop-down)

* |settings| :sup:`Snap to common angles`: when moving the cursor,
displays a virtual line that you can snap to to add the next vertex.
The snapping line is defined by the last added vertex
Expand Down Expand Up @@ -1795,18 +1810,6 @@ At the top of the :guilabel:`Digitizing panel`, you find the following buttons:
* :guilabel:`Show bearing/azimuth`
* :guilabel:`Show common snapping angle`

* |extractVertices| :sup:`Construction Tools` provides a couple of options that
constrain the vertices placement based on extrapolated coordinates of
existing elements:

* |unchecked| :guilabel:`Line Extension`: hover over a segment and you get
a purple dotted line extending the segment across the map canvas.
You can snap the vertex anywhere on this virtual line.
* |unchecked| :guilabel:`X/Y Point`: hover over a vertex and you get
a purple dotted line along its X or Y coordinate, across the map canvas.
You can snap the vertex anywhere on this virtual line.
It is even possible to hover over two different vertices, generating virtual
coordinate lines for both, and snap to their intersection.

Below the toolbar, you will find a number of text boxes whose value reflects
by default the position or movement of the cursor in the map canvas.
Expand Down Expand Up @@ -2001,6 +2004,29 @@ These two tools just find the right angle of the perpendicular and
parallel angle and lock this parameter during your editing.
Unlock the angle parameter to cancel their use in the middle of the process.

.. _circle_intersection:

2-circle point intersection
---------------------------

To add a vertex at the intersection of two circles, follow these steps:

#. Click the |circleIntersection| :sup:`2-circle Point Intersection` icon in the
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
#. Click the |circleIntersection| :sup:`2-circle Point Intersection` icon in the
#. Click the |circlesIntersection| :sup:`2-circle Point Intersection` icon in the

|extractVertices| :sup:`Construction Tools` drop-down menu.
#. A dialog will open where you can define the parameters for
:guilabel:`Circle #1` and :guilabel:`Circle #2`.
#. Click on the map canvas, and the tool will automatically calculate the
:guilabel:`X` and :guilabel:`Y` coordinates for the centers of both circles.
#. Enter the distance :guilabel:`d` for each circle.
#. The tool will calculate and display the two intersection points of the circles.
#. Click one of the intersection points to add the new vertex.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Click one of them to add the new vertex.

And maybe the above should be as steps..

.. figure:: img/circles_intersection.png
:align: center

2-circle Point Intersection


.. _construction_mode:

Construction mode
Expand Down Expand Up @@ -2156,6 +2182,8 @@ To edit features in-place:
:width: 1.5em
.. |circleCenterPoint| image:: /static/common/mActionCircleCenterPoint.png
:width: 1.5em
.. |circleIntersection| image:: /static/common/circlesintersection.png
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
.. |circleIntersection| image:: /static/common/circlesintersection.png
.. |circlesIntersection| image:: /static/common/circlesintersection.png

:width: 1.5em
.. |circularStringRadius| image:: /static/common/mActionCircularStringRadius.png
:width: 1.5em
.. |dataDefine| image:: /static/common/mIconDataDefine.png
Expand Down
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not willing to nitpick but can you add the dialog with more buttons enabled. The perpendicular and parallel buttons should at least be clearly identifiable.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need the advanced digitizing panel, here? I find the two other elements enough complementary, and we would avoid adding "unnecessary" elements that may look outdated in a few releases, e.g. because of new tools/options in GUI.
But if we do, can it be placed on the left of the circles, to get a more landscaped image and less blank part in a higher image, in docs? Thanks.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/common/circlesintersection.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions substitutions.txt
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,8 @@
:width: 1.5em
.. |circleCenterPoint| image:: /static/common/mActionCircleCenterPoint.png
:width: 1.5em
.. |circleIntersection| image:: /static/common/circlesintersection.png
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be |circlesintersection|, given the filename. Or we rename the icon in code repo for consistency with others...

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I follow the docs guidelines: "The replacement text should be derived from the file name and written in camelCase."

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed. I'm mixing requirements of my long time plan of automatizing substitutions addition process with actual rules. Sorry.
Then it should be circlesIntersection, here.

Suggested change
.. |circleIntersection| image:: /static/common/circlesintersection.png
.. |circlesIntersection| image:: /static/common/circlesintersection.png

:width: 1.5em
.. |circularStringCurvePoint| image:: /static/common/mActionCircularStringCurvePoint.png
:width: 1.5em
.. |circularStringRadius| image:: /static/common/mActionCircularStringRadius.png
Expand Down
Loading