If snapping was off, and after clicking the first point of a new line (for example), the cursor would be a default arrow instead of the intended cross-shaped cursor.
Note that the arrow cursor is still displayed for a fraction of a second after this fix.
May also fix#16559.
* Draft: implement DraftLabelGuiTools
TODO:
1- support for custom StraightDirection with any number of points
2- fix EditNode positions when the label is inside a Part
* Draft: enable Draft Edit for Draft Label object
TODO:
Make the edition possible also with double-click in the tree view
* Draft: Trigger Edit on double click on Label in the tree view
Fix part 1/2 of comment https://github.com/FreeCAD/FreeCAD/pull/13445#issuecomment-2079672899
* Draft: Edit Label: enable to move one or move both nodes
The following apply to both edit points of the straight segment:
- If a point is moved exactly on the direction of the straight segment (set the WP to the Label object and use Shift key while moving the node), then it's length is changed without moving the other point.
- If a point is moved in any other direction, both points are moved and the straight segment's length is unchanged
Part 2/2 of https://github.com/FreeCAD/FreeCAD/pull/13445#issuecomment-2079672899
* Add custom template path support for WebGL export
- Extract hardcoded template into separate file and store in Mod/BIM/Resources/templates
- Remove hardcoded template from code
- Add new section to Import-Export Preference page ("WebGL"). This introduces two new parameters
- Make export() return bool to indicate success or failure for controlled headless export
- Add new unit tests for WebGL export to ensure functionality
- Update CMakeLists.txt to include the new template resource
* Apply suggestions from code review
Changes to literals, suggested after DWG review
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
* Removed unused import
* Removed unused import
---------
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
Co-authored-by: Yorik van Havre <yorik.vanhavre@gmail.com>
* Import: DXF importer, block and inserts overhaul
Implement support for blocks as definitions and inserts
as instances.
A BLOCK definition becomes a hidden master object in a
_BlockDefinitions group (currently a Part::Compound).
An INSERT becomes a visible App::Link that points to
that master definition.
* Import: DXF parser/importer add debug print statements
* Import: DXF importer, various improvements
- Add more code comments
- Correctly increase object count
- Improve readability of anonymous block checks
* Import: DXF (all) report anonymous blocks separately
* Import: DXF importer (App + GUI) add nested inserts support
* Import: DXF importer (GUI) fix preserving colors for inserts
* Import: DXF importer, make primitives naming more specific
* Import: DXF parser/importer remove debug print statements
* Import: DXF parser, work around DXF color index 7
* Import: DXF importer GUI, temporary debug print to show layer color data
* Import: DXF importer, fix nested inserts hierarchy
* Import: DXF importer, prefix and suffix underscores to names
To work around mangling from FreeCAD's unique name generator.
* Import: DXF importer, implement flattening blocks on import
* Revert "Import: DXF importer GUI, temporary debug print to show layer color data"
This reverts commit b6ece395c9d2b8a1e0796d6f7b0d58842a2f3686.
* Import: DXF importer, fix imported text orientation
The DXF file provides the text rotation angle in degrees.
The used rotZ function expects the angle in radians,
thus the conversion needs to be made.
Fixes: #21548
* Import: DXF importer, honour the preference to not import layouts
* Import: DXF importer, move unreferenced blocks to separate group
This provides better classification, but it has a performance hit:
we import all blocks as before, we sort them and we reparent them
to the correct group. The reparentipart with Grou.setValues()
appears to be an expensive call. Probably because internally the
FreeCAD dependency graph is modified.
* Import: DXF importer, count compound children in the report
* Import: DXF importer, cleanup defined blocks group if empty
* Draft: Remove main QGroupBox from Circular Array tool
* Draft: Remove main QGroupBox from Polar Array tool
* Draft: Remove main QGroupBox from Ortho Array tool
* Draft: Remove AxisMode QGroup from Ortho Array tool
* Draft: Remove main QGroup from ShapeString tool
Now for unsupported features we report on line numbers and on the entity
handle, in case that unsupported feature is a DXF entity. To avoid
flooding the output, only a maximum of 5 instances are reported with
details. The rest simply add up to the global count and are ellipsized
in the report.
Report output is now in sentence case.
Draft Label ViewObject.Justification property was overriden by Object.StraightDistance property. The Justification in the 3D view was reset after recompute. This commit fixes the problem by setting Object.StraightDistance automatically when ViewObject.Justification is changed and vice versa. Also fixes the frame position when Justification is Center.
* Fix#19422 SVG: use tag create wrong size object
Fix#19072 SVG: import <defs> keyword as object without <use>
and Fix bug that not reported, <symbol> keyword as object without <use>
and Fix bug that not reported, nested use tag not import correctly.
To do this. I make preprocessor that replace use tag to it's referenced object.
and remove symbol tag and defs tag from loaded svg.
there is a subeffect, name of imported object that related to symbol tag is changed.
* Fix incorrect import when use tag nesting context.
* fix error when use tag not exist.
* rebased aprospero PR20293.
fix several bugs.
1,x and y attribute of use tag is not processed under certain condition.
2,Doesn't finish importing when referenced ID is not exist.
3,Doesn't finish importing when use tag use href instead of xlink:href
* Refactor: Use data.get() for cleaner dictionary key handling
* Refactored code for simplicity following suggested changes.
* Add <a> tag support.( <a>tag is almost same with <g> tag at visual effect )
* Correct mistakes in the if condition handling href and xlink:href
* Modify the code to retain the original namespace definitions, as removing all namespaces may cause incorrect importing process.
* Draft: Introduce 1-axis mode for ortho array
As the title says - the 1 axis mode allows to switch between all of the
axises mode and allows to modify only 1 axis at the time that user can
select with the checkbox.
* Draft: Rename to Linear Mode and remove redundant comments
* Draft: Display only one interval for the selected axis
* Draft: Cache selected variables in user.cfg - axis mode, intervals, etc...
* Draft: Make sure the checkboxes in OrthoArray are exclusively selected
* Draft: Apply review comments
Changed a couple of things according to review:
* linear mode is now being used as default during first startup (it
wasn't before)
* applied Roy's comments about coding style, etc.
* grouped everything into separate QGroupBox which is dedicated for
Linear Mode and has it's own labels, although spinboxes are shared so
during mode switch we reparent them now
* removed Orthogonal Array's icon
* in the QGroup applied naming suggested in the review, X Intervals ->
interval, etc.
* changed to radio buttons since we want exclusivity in selection