Commit Graph

23901 Commits

Author SHA1 Message Date
luz paz
d064cdc215 Arch: Fix LGTM warning of missing param for translate() in ArchPanel.py
Even though this is ignored per the docs[1], LGTM complains[2] about it. This commit adds the superfluous param. Note: there is precedent in ArchReference.py[3] and ArchWall.py[4].
 
 [1]https://github.com/FreeCAD/FreeCAD/blob/master/src/Mod/Draft/draftutils/translate.py#L73-L78  
[2] 17db14c970/files/src/Mod/Arch/ArchPanel.py (L32)  
[3] 45dd1a7f60/src/Mod/Arch/ArchReference.py (L39)  
[4] 45dd1a7f60/src/Mod/Arch/ArchWall.py (L42)
2021-02-03 10:28:21 -05:00
donovaly
45dd1a7f60 fix issue reported by @chennes
also fix annoying variable naming - different variables representing different types should not have the same name

also update a comment according to depending PRs
2021-02-03 16:24:01 +01:00
donovaly
1c58c3b677 [PD] hole fix custom cut handling
This PR is based on PR #4344 and a spin-off of PR #4337. It fixes:

We have normed screw head cuts. These values can be overridden but we must store the info about the overriding. Why? - because when you have e.g. made a custom change to a normed countersink and then change to another countersink norm, you would either not get the values defined in the norm or you get these values but loose e.g. your depth settings
2021-02-03 16:23:28 +01:00
donovaly
c676c07316 [PD] fix UTS clearance holes
This PR is based on PR #4343 and a spin-off of PR #4337. It fixes:

- the bug that we did not use the normed clearance hole diameters for UTS holes
- missing recompute when changing existing hole from Metric to UTS type
2021-02-03 16:19:24 +01:00
donovaly
7eb9b5ed42 [PD] hole dialog UI fixes
This PR is the first in a series of probably 3 PRs to fix known hole dialog bugs.

This one fixes:

- the .ui file issues
- readonly status issues of some widgets/properties (e.g. when the hole is through all, disable drill point settings)
- the bug that updateHoleCutParams() overwrote the previously correctly determined hole diameter
- just a trifle: change a function name to fit into the naming scheme
2021-02-03 16:14:36 +01:00
wmayer
3ebd7d119b Part: [skip ci] rename methods in TopoShape that override non-virtual functions of base class 2021-02-03 16:10:38 +01:00
donovaly
cc3a30a221 [PD] fix typo in iso7046.json
This mistake was introduced by me in commit 4ab3c955
2021-02-03 15:08:30 +01:00
donovaly
400b25c0d0 [TD] fix color change for dimensions
This PR fixes issue C reported here: https://forum.freecadweb.org/viewtopic.php?f=35&t=55008#p472939
- the changed color must also be applied to the dimension line and arrows
2021-02-03 14:11:44 +01:00
luz paz
45eea3d9e7 Fix various typos [skip ci]
Found via codespell v2.1.dev0  
```
codespell -q 3 -L aci,ake,aline,alle,alledges,alocation,als,ang,anid,apoints,ba,beginn,behaviour,bloaded,byteorder,calculater,cancelled,cancelling,cas,cascade,centimetre,childs,colour,colours,commen,connexion,currenty,dof,doubleclick,dum,eiter,elemente,ende,feld,finde,findf,freez,hist,iff,indicies,initialisation,initialise,initialised,initialises,initialisiert,ist,kilometre,lod,mantatory,methode,metres,millimetre,modell,nd,noe,normale,normaly,nto,numer,oder,orgin,orginx,orginy,ot,pard,pres,programm,que,recurrance,rougly,seperator,serie,sinc,strack,substraction,te,thist,thru,tread,uint,unter,vertexes,wallthickness,whitespaces -S ./.git,*.po,*.ts,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig*,./src/Mod/Robot/App/kdl_cp,./src/Mod/Import/App/SCL,./src/WindowsInstaller,./src/Doc/FreeCAD.uml,./build/doc/SourceDocu
```
2021-02-03 14:08:57 +01:00
wmayer
7a83853535 Part: offer all supported STEP schemes by OCC in a combo box 2021-02-02 21:51:11 +01:00
Yorik van Havre
078160ea70 TechDraw: Exposed GeomHatch functionality to Python in TechDraw.makeGeomHatch() 2021-02-02 17:49:44 +01:00
Yorik van Havre
d02a0d558e Merge pull request #4331 from chennes/openSCADFix
[Draft] OpenSCAD/DXF error: fix DXF import with no layers
2021-02-02 14:01:43 +01:00
Yorik van Havre
253ef2a99a Merge pull request #4346 from chennes/validateStartHTMLWithW3C
[Start] Modify generated HTML to comply with W3C Validator Recommendations
2021-02-02 13:59:09 +01:00
Yorik van Havre
bdc07a1d22 Merge pull request #4351 from chennes/fixSurfaceDeleteShortcuts
[Surface] Fix task panel Delete shortcut use to use Widget context
2021-02-02 11:52:36 +01:00
Chris Hennes
612eba1b1a Fix Surface task panel shortcut use to use Widget context
The Delete key shortcut of the three different panels in the
Surface Workbench TaskFilling sidebar conflicted between
the panels if multiple were showing. This is resolved by
making the QAction's context the widget, rather than the window.
2021-02-01 19:40:33 -06:00
Chris Hennes
5e07d708db Remove extraneous lines from export
Corrects a merge issue from an earlier PR: the removed lines are
redundant.
2021-02-01 13:38:21 +01:00
Chris Hennes
1958e30f84 Modify Start HTML to be valid HTML
Using the W3C validator, a number of minor issues were found with the Start page
HTML. Those items were:
* Missing language setting on the body of the document
* Deprecated attributes set for the style and script tags
* Image tags require alt text
* List tags can only contain list items
* All file:/// URLs must not contain backslashes, even on Windows
2021-01-31 22:13:47 -06:00
Chris Hennes
7b9c9d4f5e Add tests for Start Page HTML validity
This test is in two parts: first the generated HTML is sanitized to remove any
potentially sensitive information (e.g. filenames, authors, document info, etc.)
and is then sent to the W3C Validator service at https://validator.w3.org/nu.
The results are interrogated and if any errors or warnings are returned, the
test fails. If the site cannot be reached this is NOT treated as a test failure.

Second, the actual (unsanitized) filenames are checked for validity: the HTML
standard prohibits backslashes in URLs, even if the URL refers to a local file
on a system that uses backslashes as a path separator (e.g. Windows). This
would have been caught by the W3C Validator if we had not sanitized the filenames.
2021-01-31 21:49:17 -06:00
Zheng, Lei
bead9bb938 Gui: sync recent action file list from external modification 2021-01-31 18:14:18 +01:00
wmayer
93a956e70d [PD] [skip ci] fix alignment in pad dialog
just a minor UI issue: when you decrease the width of the pad dialog (e.g. because you have a small screen), the alignment of the widgets is lost. This fixes it by grouping the widgets in a grid.
2021-01-31 16:26:22 +01:00
donovaly
b50838c7a5 [PD] fix alignment in pocket dialog
just a minor UI issue: when you decrease the width of the pocket dialog (e.g. because you have a small screen), the alignment of the widgets is lost. This PR fixes this by grouping the widgets in a grid.
2021-01-31 16:03:57 +01:00
Aapo
4ea0784341 [TD] Dimensions: donovaly's minor fixes for TheoreticalExact dimensions. 2021-01-31 15:17:46 +01:00
Aapo
e802179cf4 [TD] Improve arbitrary tolerance and unit handling for Equal Tolerances. 2021-01-31 15:17:46 +01:00
Aapo
660710c26e [TD] Add under- and overtolerances for Dimension Task layout, fixes for Dimension tolerance refresh and behavior. 2021-01-31 15:17:46 +01:00
Aapo
a2f060e36e [TD] Fix degree sign processing for equilateral angular plusminus dimensions. 2021-01-31 15:17:46 +01:00
Aapo
d26b6542ca [TD] Fix regression in Dimensions: Setting arbitrary under tolerance was somehow lost. 2021-01-31 15:17:46 +01:00
donovaly
4ab3c95552 [PD] correct hole cut definitions
I was able to get the norms and could update the definitions accordingly.
For example in the ISO 10462, sizes smaller than M3 are not defined and your definition files should only contain what is really defined.
2021-01-31 13:45:57 +01:00
Chris Hennes
eb6167ff89 Enable LGTM to analyze some C++ source code
FreeCAD as a whole is too large for LGTM to analyze the entire codebase, the operation
times out after three hours. By focusing only on the core code, this patch allows the
automated testing framework there to analyze our C++ code, in addition to the Python
and JavaScript analsis it was already doing.
2021-01-30 17:30:22 +01:00
wmayer
096e538c9e App: [skip ci] use better deprecation warning as used in PR 4335 2021-01-30 17:27:08 +01:00
wmayer
b896bb4f2a Part: [skip ci] fix path of attachment icon 2021-01-30 17:22:54 +01:00
wmayer
756654c46e App: [skip ci] print deprecation warning if addExtension() has two arguments 2021-01-30 17:20:43 +01:00
Stefan Tröger
446ce21517 Remove ExtensionProxy and rely on default Python proxy for extensions. fixes #0004534 2021-01-30 16:00:48 +01:00
Benjamin Nauck
37952a5949 Spreadsheet: Add test for undo alias issue 2021-01-30 14:04:57 +01:00
Benjamin Nauck
f4c2539765 Spreadsheet: Allow alias removed by undo to be reused
Fixes issue descripted in the forum post:
https://forum.freecadweb.org/viewtopic.php?f=3&t=54009
2021-01-30 14:04:57 +01:00
Kurt Kremitzki
497ecbe0eb Merge pull request #4134 from donovaly/PD-Hole-DrillPoint
[PD] improve blind hole depth handling
2021-01-30 05:14:52 -06:00
Kurt Kremitzki
ca346b9099 Merge pull request #4165 from chennes/addImportExportRecentFilesPrefs
[App] Add prefs for import/export in Recent Files
2021-01-30 05:14:36 -06:00
Benjamin Nauck
1f77dc2af8 [MeshPart] Fix copy-paste error
It doesn't make sense to check minLen and then call SetMinSize to maxLen
so this must be a copy-paste error.

Introduced in f681b86abd

Found with Coverity.
2021-01-30 11:47:06 +01:00
Kurt Kremitzki
046aa8a287 Merge branch 'master' into PD-Hole-DrillPoint 2021-01-29 19:02:34 -06:00
Kurt Kremitzki
ce8b96bada Merge branch 'master' into addImportExportRecentFilesPrefs 2021-01-29 19:02:21 -06:00
Chris Hennes
77d666a48b Fix DXF import with no layers
As discussed in https://forum.freecadweb.org/viewtopic.php?f=3&t=54842, if OpenSCAD creates a DXF with no layers in it, the code that is supposed to handle that in FreeCAD has a minor type error in it that prevents the import from working.
2021-01-29 17:01:22 -06:00
sliptonic
4db83a41ca Merge pull request #4325 from machste/fix_simple_copy
Path: Fix creating simple copy
2021-01-28 14:14:02 -06:00
Stefan Brüns
569817d87a Fix ODR violation, correct Ui_TaskSketcherGeneral namespace
The generated ui_TaskSketcherGeneral.h defines the class in the
SketcherGui namespace.

Fixes #4529
2021-01-28 17:43:10 +01:00
Zheng, Lei
1dddcd0b18 Part: fix ViewProviderExt::updateVisual() on incomplete mesh 2021-01-28 17:38:49 +01:00
wmayer
aa45875a2b Gui: modernize C++ 2021-01-28 16:22:40 +01:00
vosk
b49c523a54 [Part] - Fix View3DInventor.setCamera leaking SoCamera* 2021-01-28 16:17:33 +01:00
vosk
4bd5c2669d [Part] - Fix memory leaks 2021-01-28 15:45:00 +01:00
Aapo
92846ad0f1 [TD] Avoid changing default open/save dir to templateDir when opening a Page template. 2021-01-28 14:54:59 +01:00
Benjamin Nauck
6870b02210 [Gui] Make inventor markers symmetric
These changes makes the round markers symmetric horizontally, vertically
and on the diagonal.
2021-01-28 14:54:05 +01:00
Yorik van Havre
0f3cdfea33 Merge pull request #4317 from Roy-043/fix_gui_snapper_center_face
[Draft] Fix snap to center of faces of solids
2021-01-28 14:36:15 +01:00
Yorik van Havre
8396c34d61 Merge pull request #4318 from bitacovir/Surface_WB_icons
[UI] Replace SVG icons for Surface WB commands
2021-01-28 14:33:45 +01:00