FreeCAD / FreeCAD/FreeCAD

Draft: Use relative coordinates for changing dimension text position

Open
#5,631 0 comments 0 reactions 0 assignees View on GitHub
Mod: Draft Topic: User Interface Type: Feature
Dominant language
C++
Stars
33.6k
Forks
6k
Avg merge
3d 17h
Merged PRs (30d)
196

Description

Issue imported from https://tracker.freecad.org/view.php?id=2190

* **Reporter:** triplus
* **Date submitted:** 7/10/2015
* **FreeCAD version:**
* **Category:** Feature
* **Status:** assigned
* **Tags:**

# Original report text

When user tries to change dimension text position global coordinates are used instead of relative coordinates.

1.) Use relative coordinates by default.
2.) Use global coordinates but therefore default values for X,Y,Z text position property should not be set at 0 but at global coordinate values.

# Additional information

http://forum.freecadweb.org/viewtopic.php?f=3&t=11733&p=94386#p94386

# Other bug information

* **Priority:** normal
* **Severity:** minor
* **Category:** Feature
* **OS: Ubuntu 14.04**
* **Platform:** Linux
* **Updated:** 2/6/2021

# Discussion from Mantis ticket

### Comment by yorik 2015-09-10 19:39
relative coordinates don't exist anymore once the object has been created.

---

### Comment by triplus 2015-09-19 21:02
If Text Position X Y Z property is set to 0 dimension text will always be centered and slightly above dimension line. Regardless of the changes made to X Y Z Dimline Property.

Therefore if user changes for example Text Position Y property from 0 to 0,5 i am guessing the user expects the result where dimension text is moved by 0,5 in Y direction from that original position (centered and slightly above dimension line). Instead dimension text is moved away from dimension line to global 0,5 in Y direction.

---

### Comment by yorik 2015-09-20 16:38
Hmm I don't like that, because if the dimension changes, the text position will change too, which is not what I want.

---

### Comment by triplus 2015-09-20 21:37
That already happen if X Y Z property is set to 0. Dimension text is tied to dimension and should move with it and therefore respect relative changes in X Y Z direction set by the user.

Positioning the dimension text individually in the global coordinate system makes less sense compared to positioning the dimension text relative to the dimension itself. I am not against having an option for both as probably there could be use case for everything. As for positioning text in global coordinate system Draft Text tool makes more sense.

---

### Comment by triplus 2015-09-22 16:14
Alternative solution could be to have "auto" and "manual" mode.

-Default mode would be "auto" and it would do the same as current 0,0,0 setting.
-If changed to "manual" mode global coordinates could be set (as now) with one difference and that is X,Y,Z value would be pre-filled with current dimension text global coordinates.

---

### Comment by steelman 2017-07-02 14:51
There need to be "relative" positioning too, to move the text around the "auto" (centre of the line) position, for example to the other side of the line. When changes are small, chances are that such "relatively" positioned text is still in acceptable position. Those chances are smaller when position is global.

---

### Comment by carlopav 2020-06-14 20:28
yorik, are you still of the same idea about relative coordinates of the text position vector?

---

### Comment by yorik 2020-06-15 08:14
No not really... indeed it would make sense.

---

### Comment by carlopav 2020-06-15 11:13
I can have a look at it, it doesn't seem something complicated to address... Do you think we should provide some kind of backward compatibility or just change it?

---

### Comment by yorik 2020-06-16 10:42
Maybe we can change the property name? So there is a clear "before" and "after"... But also I don't think this feature is used much, so it might be overkill and we could just do it and see (and maybe provide a method that users can do manually to fix things)

---

### Comment by yorik 2020-06-16 12:59
Looking at https://forum.freecadweb.org/viewtopic.php?f=8&t=47677&p=408935#p408935
That property could even become a full placement.

---

### Comment by Kunda1 2020-10-23 02:53
carlopav any progress on this ?

---

### Comment by carlopav 2020-10-23 11:53
Kunda1 , sorry not much time to dedicate to Freecad at the moment, i'll be back soon I hope. :)

Contributor guide

Open the contributing guide

Research direction

No source file or test is named. Start by reviewing the dimension text position property and the linked forum discussion; resolve whether positioning should be relative, global, or use an auto/manual mode, including backward compatibility. Done means the chosen behavior is implemented and dimension text positioning remains usable.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
computer-graphics, design, desktop-dev
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.