Commit Graph

22703 Commits

Author SHA1 Message Date
Abdullah Tahiri
05ccc95cde App/Gui: New restoreError Document status and Gui pop-up
========================================================

If the restore of Document.xml results in invalid Document.xml (because unhandled exceptions occurred), the
document status Document::restoreError is set. The GUI or Mod/Web if a link was clicked, show a pop-up indicating
this situation.

This commit also shows an appropriate pop-up for the partialRestore when opening from the menu, that before only
appeared when opening by clicking a link.
2021-01-24 16:43:20 +01:00
wmayer
e2c4d5f86e Fem: [skip ci] fix FemMesh::addGroup() for smesh 9 2021-01-24 15:29:56 +01:00
Zheng, Lei
aa88c10465 App: auto create Origin in OriginGroup if copied without dependency 2021-01-24 11:56:10 +01:00
bitacovir
1aa0e6d62b Add SVG icon for Std Windows command 2021-01-23 19:44:40 +01:00
Abdullah Tahiri
0ecddc5e33 Sketcher: Invalid Sketch geometry color in preferences 2021-01-23 07:53:28 +01:00
Abdullah Tahiri
6e30d05a12 Sketcher: New geometry color to indicate invalid sketch 2021-01-23 07:53:28 +01:00
Abdullah Tahiri
b9640eec63 GCS: convenience diagnosis functions 2021-01-23 07:53:28 +01:00
Abdullah Tahiri
e87c01590f GCS/Sketcher: Add equal length line constraint using the new single constraint 2021-01-23 07:53:28 +01:00
Abdullah Tahiri
1c2e7d74b5 GCS: New Constraint for equal size lines, avoiding to use an extra parameter
============================================================================

This specific constraint removes the free parameter of the previous implementation. This solves:
https://tracker.freecadweb.org/view.php?id=4501

fixes #4501

However, this implementation of equal size produces zero gradients when coordinates of lines are aligned,
e.g. vertical or horizontal. These zero gradients, which are mathematically right ruin the diagnosis, which
regards corresponding elements as fully constraint (because they are locked from a solver point of view), when
they are simply locked, but are movable and constrainable. For this, when the rightful gradient is small enough
(<1e-10) it is substituted by a surrogate gradient of 1e-10, which solves the problem with the diagnose, which
treats as zero only values under 1e-13 (pivot threshold used in QR decomposition).

This special behaviour fixes the wrong detection here:
https://forum.freecadweb.org/viewtopic.php?f=8&t=53466&start=40#p464168

It also fixes this one:
https://forum.freecadweb.org/viewtopic.php?p=468585#p468587
2021-01-23 07:53:28 +01:00
Abdullah Tahiri
57a4f3e47c Sketcher: Update solver partially redundant constraint information in the solver messages 2021-01-23 07:53:28 +01:00
Abdullah Tahiri
436a807c87 Sketcher: command to select partially redundant constraints 2021-01-23 07:53:28 +01:00
Abdullah Tahiri
5a5ed565a8 Sketcher: SketchObject partially redundant status 2021-01-23 07:53:28 +01:00
Abdullah Tahiri
dd0fb0c791 Sketcher: Sketch retrieve partially redundant constraints 2021-01-23 07:53:28 +01:00
Abdullah Tahiri
567c80fb67 GCS: report partially redundant constraints 2021-01-23 07:53:28 +01:00
marioalexis
875c0d8612 Draft: Prevent Draft_Wire from setting a single-edge wire as closed 2021-01-22 01:16:40 -03:00
sliptonic
a7d371b8a5 Merge pull request #4284 from sliptonic/bug/fixturetemplate
[Path] fix persistence of fixtures, split, and orderby to templates
2021-01-21 17:12:56 -06:00
wmayer
4fca6cdb81 Gui: [skip ci] drop the hard limit of 50 allowed workbenches 2021-01-21 16:42:04 +01:00
Yorik van Havre
1ea0275102 Merge pull request #4285 from bitacovir/OpensCAD_Icon_replacement
[UI] Replacement of 2 SVG icons for OpenSCAD commands
2021-01-21 13:34:30 +01:00
Yorik van Havre
33c719a382 Merge pull request #4287 from bitacovir/PartDesign_Icons
[UI] Add SVG icons for three PartDesign commands
2021-01-21 13:33:41 +01:00
Yorik van Havre
9de4841d0f Merge pull request #4291 from aapo-aapo/TD-US-MultiValueSchema-fix
[TD] Fix Dimension unit printing problem for US building units …
2021-01-21 13:32:48 +01:00
Yorik van Havre
6ded863f7d Merge pull request #4292 from aapo-aapo/TD-MDIViewPage-papersizes
[TD] MDIViewPage: Add support for Qt5 automatic paper size handling …
2021-01-21 13:21:56 +01:00
wmayer
50a6c5ec9e FEM: make FemMesh::getVolumesByFace() working for SMESH >= 7 2021-01-21 13:00:31 +01:00
Yorik van Havre
3a0a989d08 Merge pull request #4298 from Roy-043/ArchRoof_FixSelfRefRelProfile
ArchRoof.py: Fix for self referencing relative profile issue
2021-01-21 12:51:27 +01:00
wmayer
b431987ea3 smesh: port to version 9.6 2021-01-20 19:49:56 +01:00
Roy-043
b31667dbc7 Update ArchRoof.py
A relative profile can now be used if it references itself. This fixes a compatibility issue with the V0.18 version of ArchRoof, where the first profile initially always references itself.
2021-01-20 19:17:30 +01:00
bitacovir
67f6353046 Add SVG icons for two Part commands 2021-01-19 19:26:10 +01:00
donovaly
691eaa6e8f [TD] make pointers to the UI std::unique_ptr
as noted in https://github.com/FreeCAD/FreeCAD/pull/4271#discussion_r554673632
the pointer to the UI should be a unique pointer.

This PR does this for all TD dialogs that don't already use a unique_ptr.
2021-01-19 19:24:27 +01:00
wmayer
73f10fab47 Gui: [skip ci] update standard cursors of 3d view when device pixel ratio changes (e.g. by moving between standard and high DPI monitor) 2021-01-19 19:19:30 +01:00
wmayer
49f4454ed3 Mesh: [skip ci] fix hot spot of mesh selection cursor 2021-01-19 19:17:54 +01:00
Aapo
ff18dec065 [TD] MDIViewPage: Support printing/exporting arbitrary custom paper sizes for Qt5. 2021-01-19 11:03:24 +02:00
Aapo
7339646638 [TD] MDIViewPage: Add support for Qt5 automatic paper size handling with many new paper sizes possible. 2021-01-19 00:49:57 +02:00
Aapo
691051e1df [TD] Fix Dimension unit printing problem for US building units and other multivalueschema. 2021-01-18 21:52:35 +02:00
marioalexis
b263c2aa87 Part: Crash when calling SubShapes of empty shape from Python 2021-01-18 19:47:35 +01:00
marioalexis
e4535762db Gui: Prevent crash when trying to access sub-objects of a deleted object from a SelectionObject 2021-01-18 19:46:03 +01:00
David Österberg
e6e77c7698 Update src/Mod/PartDesign/App/FeaturePipe.h
Co-authored-by: Benjamin Nauck <benjamin@nauck.se>
2021-01-18 17:38:15 +01:00
David Osterberg
de5c8574d3 PartDesign: Fix small bugs in the Pipe feature
- Previously a subtractive pipe on a body with no solids would create a solid. Now Pipe will generate an error.
- Fix incorrect property header. Previously Pipe was identifying itself as Pad (copy paste error)
2021-01-18 17:38:15 +01:00
wmayer
8924bd4734 Gui: [skip ci] must set device pixel ratio to QBitmaps on Windows when using for cursor as otherwise garbage is shown 2021-01-18 15:20:57 +01:00
bitacovir
154d510183 [UI] Add SVG icons for three PartDesign commands 2021-01-18 11:04:32 -03:00
Yorik van Havre
bbfb76cd45 Merge pull request #4271 from donovaly/TD-dimension-dialog
[TD] add dialog to modify some dimension settings
2021-01-18 15:00:48 +01:00
Yorik van Havre
68c1e7bcc0 Merge pull request #4283 from paullee0/ArchComponent_02
[ArchComponent] Fix Link Of Window Hosts if empty got error as Wall Child
2021-01-18 15:00:10 +01:00
Abdullah Tahiri
a2af4ce8e2 Sketcher: increase relative size of the subindices of the constraints
=====================================================================

Increase the size of the subindices as per request:
https://forum.freecadweb.org/viewtopic.php?p=468144#p468144
2021-01-18 14:25:30 +01:00
bitacovir
c455fd9ec0 [UI] Replace of 2 SVG icons for OpenSCAD commands 2021-01-17 22:00:57 -03:00
Bernd Hahnebach
fdb89678ac FEM: mesh tools, add a comment 2021-01-17 23:46:49 +01:00
Bernd Hahnebach
5fb28bdc96 FEM: utils, fix clipping FemMesh without Shape 2021-01-17 23:46:41 +01:00
sliptonic
00b57ec232 fix persistence of fixtures, split, and orderby to templates 2021-01-17 15:28:24 -06:00
paul lee
66807c7437 [ArchComponent] Fix Link Of Window Hosts if empty got error as Wall Child 2021-01-18 02:08:39 +08:00
Abdullah Tahiri
e191391384 Sketcher: Compensate for Coin not taking the dpi of the monitor into account in font pixel setting
==================================================================================================

Coin documentation indicates the size of a font is:

SoSFFloat SoFont::size        Size of font. Defaults to 10.0.
For 2D rendered bitmap fonts (like for SoText2), this value is the height of a character in screen pixels. For 3D text, this value is the world-space coordinates height of a character in the current units setting (see documentation for SoUnits node).

However, with hdpi monitors, the coin font labels do not respect the size passed in pixels:
https://forum.freecadweb.org/viewtopic.php?f=3&t=54347&p=467610#p467610
https://forum.freecadweb.org/viewtopic.php?f=10&t=49972&start=40#p467471

Because I (abdullah) have  96 dpi logical, 82 dpi physical, and I see a 35px font setting for a "1" in a datum label as 34px,
and I see kilsore and Elyas screenshots showing 41px and 61px in higher resolution monitors for the same configuration, I think
that coin pixel size has to be corrected by the logical dpi of the monitor. The rationale is that: a) it obviously needs dpi
correction, b) with physical dpi, the ratio of representation between kilsore and me is too far away.

This means that the following correction does not have a documented basis, but appears necessary so that the Sketcher is usable in
HDPI monitors.
2021-01-16 08:00:30 +01:00
Abdullah Tahiri
952f75f979 Sketcher: fix horizontal distance constraint on external edge
=============================================================

Fixes:
https://forum.freecadweb.org/viewtopic.php?f=3&t=54348#p467107
2021-01-15 14:38:48 +01:00
donovaly
1a296a4006 [TD] add dialog to modify some dimension settings
also fix issue that tolerance could be set despite theoretically exact is true under some circumstances

also some wording improvements

also a minor fix to use 0.0 instead of DBL_MIN
2021-01-15 05:21:49 +01:00
Abdullah Tahiri
e9c22f93fd Sketcher: Migrate old construction points as construction
=========================================================

Fix that construction points, which did not have the construction flag before, as construction flag was
reserved for internal alignment points, are migrated as construction points.

Fixes:
https://forum.freecadweb.org/viewtopic.php?f=8&t=53466&start=40#p467176
https://forum.freecadweb.org/viewtopic.php?p=467160#p467160
2021-01-14 19:22:15 +01:00