Commit Graph

2036 Commits

Author SHA1 Message Date
wmayer
7acc67ea43 PD: fix crash in TaskRevolutionParameters::addAxisToCombo
and some warnings reported by GH actions
2022-11-09 18:56:11 +01:00
wmayer
1911fe50ff PD: [skip ci] improve the exception text 2022-11-09 17:46:46 +01:00
Uwe
2aa232bef9 [PD] TaskDlgRevolutionParameters: fix some CI warnings
- reported here: https://github.com/FreeCAD/FreeCAD/pull/7667/commits/f0a0e563
- and here: https://github.com/FreeCAD/FreeCAD/pull/7719/commits/8f3f17f8
2022-11-09 17:33:33 +01:00
Uwe
e31cd499b0 [PD] Helix: assure source Sketch is visible when in selection mode
- same as https://github.com/FreeCAD/FreeCAD/commit/18781bcf6 but for Helices (fixes #7629 also for helices)
- also modernize Qt connection
2022-11-06 12:48:11 +01:00
wmayer
a76dc0ade2 PD: use Base::StateLocker to simplify handling of blockUpdate and make it exception-safe 2022-11-05 19:29:20 +01:00
wmayer
18781bcf63 PD: fixes #7629: Keep sketch visible during revolution tasks 2022-11-05 19:09:54 +01:00
wmayer
63e74c848f PD: unit test to check offset of sub-shape binder (PR #7445) 2022-11-05 16:58:51 +01:00
Paddle
22f2cae70d PartDesign: Remove unusable 'Leave sketch' 'viewSketch' commands from menu.
Add 'EditSketch' 'MergeSketches' and 'mirrorSketch' usable commands to menu.
Add 'ValidateSketch' to toolbar.
2022-11-04 16:18:41 -05:00
wmayer
af0a014cf2 Qt6 port:
* QApplication::setFallbackSessionManagementEnabled has been removed
* QString::medRef() has been removed. Use QString::mid() again.
* QTextStream::setCodec has been removed
* Use operator QVariant of the QFont class to make code Qt5 and Qt6 compatible
* Signature of QTreeWidget::mimeData() has changed in Qt6. Remove TreeWidget::mimeData() because it doesn't change the implementation
* QLayout::setMargin() is deprecated in Qt5 and has been removed in Qt6. Use QLayout::setContentsMargins()
* QDateTime::toTime_t() is deprecated in Qt5 and has been removed in Qt6. Use QDateTime::toSecsSinceEpoch()
* QDesktopWidget is deprecated in Qt5 and has been removed in Qt6. Use QScreen
2022-11-01 16:55:40 +01:00
Flachy Joe
b2eb67e806 [PartDesign] Improve Helix calculation for straight shape (#7674) 2022-10-31 23:26:10 +01:00
Chris Hennes
2f7be9e782 cMake: Add support for compiling against Qt6 (#7647)
Removes the BUILD_QT5 flag and adds a new FREECAD_QT_VERSION option,
which can be set to either "Auto" (default), 5, or 6. Auto detects which
version of Qt is installed on the system and chooses it. If both version
are installed, Qt5 is used.

Note that this DOES NOT implement compiling against Qt6, it only adds
the necessary cMake infrastructure to begin work on the source code
changes that will be required.
2022-10-31 09:24:09 -05:00
Uwe
978642d03e [PD] remove deprecated holes
- as discussed in https://github.com/FreeCAD/FreeCAD/pull/7642 the backwards compatibility for deprecated holes was already lost since FC 0.19
- this PR removes the deprecated types and transform holes created with FC 0.19 or 0.20 to the corresponding countersinks/counterbores.

- also add Counterdrill for translations
2022-10-27 14:24:32 +02:00
Uwe
f1c03bc233 [PD] FeatureHole.cpp: sort counterdrill
- will be necessary to push deprecated entries to the end of the combobox in the dialog (in a coming PR)
- also fix too long code line
2022-10-25 01:09:37 +02:00
wmayer
c98545b6ca PD: [skip ci] disable undo/redo for the tmp. document created by the SubShapeBinder 2022-10-24 16:50:50 +02:00
Stefan Klug
60d7b1d834 PartDesign: Add HoleCuteType "Counterdrill" 2022-10-24 15:19:24 +02:00
Stefan Klug
c7f64b12bd PartDesign: Refactor geometry creation of counersink/counterbore
The counterbore is basically a special case of the countersink
with a countersink angle of 180 degrees and applied depth.
Handling it that way elimintaes some duplicate code and adds the ability to
combine countersinks and counterbore to form a counterdrill.

The sanity check on countersinkAngle can be safely dropped as it is ensured
by a constraint on the property itself.
2022-10-24 03:42:02 +02:00
Stefan Klug
7ed0c36aa3 PartDesign: Remove duplicate comment 2022-10-23 09:15:17 -05:00
Stefan Klug
cbd1963142 [Bugfix] PartDesign: Fix HoleCutDepth not being recalculated correctly
HoleCutDepth is reset to 0 to force a recalculation of te depth when
HoleCutType is set to a new value.
But the line
	pcHole->HoleCutCustomValues.setValue(false)
also forces a recalculation. So the depth was recalculated with the old
value in HoleCutType which was not expected behaviour.
2022-10-23 04:10:18 +02:00
Yorik van Havre
d8d55a0e88 Merged crowdin translations 2022-10-17 15:12:16 +02:00
Uwe
a96a3a505f use explicit prefix std:: for vectors
- also add potentially missing include
- this commit is an attempt to fix #7585
2022-10-11 01:44:24 +02:00
Yorik van Havre
fce72e46c8 Merged crowdin translations 2022-10-10 11:06:08 +02:00
Yorik van Havre
df52f32c87 Updated ts files 2022-10-10 10:19:30 +02:00
wmayer
82866db0ca Mod: replace QRegExp with QRegularExpression 2022-10-07 14:03:53 +02:00
Yorik van Havre
8b7c61277a Merged crowdin translations 2022-10-06 12:48:05 +02:00
Yorik van Havre
d87fd4d97e Updated ts files 2022-10-06 12:16:32 +02:00
Uwe
78cc184d50 [Part/PD] few clang formatting fixes 2022-09-18 13:33:41 +02:00
Uwe
884c11b4e9 Revert "[PD] simplify code for wedges"
This reverts commit dd574d5c68.

On MSVC this compiled and works. I have no clue why not also with Clang. Reverting for now.
2022-09-18 13:31:09 +02:00
Uwe
dd574d5c68 [PD] simplify code for wedges 2022-09-18 12:32:14 +02:00
Ethan Chappel
e4259cd851 Gui: Add format parameter for wedgeXmin 2022-09-18 12:06:39 +02:00
0penBrain
4bfc6a082a PartDesign: improve offset handling of SubShapeBinder 2022-09-11 21:17:22 +02:00
wmayer
6d4f95650c PD: modernize C++: replace 'typedef' with 'using' 2022-08-29 22:20:49 +02:00
berniev
6953310116 Mod: Single arg ctors must be explicit 2022-08-24 16:55:20 +02:00
Jonas Bähr
a1776d3e74 Fix build on MacOS-X 10.14: missing Xerces include dir
This undoes most of the Xerces related part of the commits listed below.
The issue resolved here is that the Xerces include dir *is* set in the
CMakeLists.txt of src/Base, but it got removed from various App and Gui
dirs in src/Mod. If those now include a header from src/Base, which
itself includes xercesc, the build fails using Apple clang version 11.0.0
(clang-1100.0.33.17) on Mojave, configured using cmake 3.22.1, with
errors like the following:

In file included from .../src/Mod/Part/App/FeaturePartBoolean.cpp:34:
In file included from .../src/App/Application.h:33:
.../src/Base/Parameter.h:54:10: fatal error: 'xercesc/util/XercesDefs.hpp' file not found
 #include <xercesc/util/XercesDefs.hpp>
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

Finally, a full list of the commits that introduced this spurious include
dir optimization for reference:
- Drawing: commit 96ad045b91
- Image: commit dde71a21d5
- Import: commit c9d28b542f
- Inspection: commit d41f55f382
- Mesh: commit 19072b0538
- Part: commit fe213a48f0
- PartDesign: commit b037d8e240
- Path: commit f23fa31f42
- Points: commit bec723ba17
- Raytracing: commit 08d4ac63a3
- ReverseEnginering: commit 5ca787cb0e
- Robot: commit bad4809a1c
- Sketcher: commit 3c96daf105
- Spreadsheet: commit 66e8a2bef3
- Start: commit c9dee5e70a
- Surface: commit 6b04215be6
- TechDraw: commit 5e6699e48d
- Test: commit ea5b45b92c
- Web: commit ee6d631531
2022-08-24 07:40:04 +02:00
luz paz
1a7ddfdc24 Fix typos and whitespace
Found via `codespell -q 3 -L aci,ake,aline,alle,alledges,alocation,als,ang,anid,anormal,apoints,ba,beginn,behaviour,bloaded,bottome,byteorder,calculater,cancelled,cancelling,cas,cascade,centimetre,childrens,childs,colour,colours,commen,connexion,currenty,dof,doubleclick,dum,eiter,elemente,ende,feld,finde,findf,freez,hist,iff,indicies,initialisation,initialise,initialised,initialises,initialisiert,inout,ist,itsel,kilometre,lod,mantatory,methode,metres,millimetre,modell,nd,noe,normale,normaly,nto,numer,oce,oder,ontop,orgin,orginx,orginy,ot,pard,parm,parms,pres,programm,que,rady,recurrance,ro,rougly,seperator,serie,sinc,siz,strack,substraction,te,technic,thist,thru,tread,uint,unter,uptodate,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,./src/Base/StackWalker.cpp,./build/doc/SourceDocu`
2022-08-23 18:49:47 +02:00
wmayer
145c3bf7c5 PD: [skip ci] fix UTF-8 handling in Hole feature 2022-08-21 11:07:15 +02:00
wmayer
2062f9ce87 clang: fix warnings [-Winconsistent-missing-override] 2022-08-09 17:36:25 +02:00
berniev
ddafb98813 Mod: Use override etc 2 2022-08-09 12:52:26 +02:00
berniev
915369d8a2 Mod: Redundant_string_initialization 2022-08-08 16:52:42 +02:00
berniev
da9ebc572f Mod: redundant void 2 2022-08-08 10:27:50 +02:00
berniev
b796a0d376 Mod: use empty 2022-08-06 19:30:13 +02:00
berniev
2d4c5a4cfb Mod: use emplace_back 2022-08-05 10:36:16 +02:00
Uwe
0788b2c0a2 [PD] remove unnecessary Python check
we only support Python 3
2022-07-31 05:27:45 +02:00
luz paz
69a4a49f3d PD: Remove unnecessary semicolons in FeatureHole.py
Discovered through github action check.  
[skip ci]
2022-07-30 13:17:18 +02:00
luzpaz
82cdbebe97 PD: Fix 'testing inequality to None' syntax (#7279)
* PD: Fix 'testing inequality to None' syntax

- Substitute `is not None` for `!= None`
- Fix trailing whitespace
2022-07-30 04:01:40 +02:00
Uwe
d7074f88b4 [PD] AppPartDesignGui: sort includes 2022-07-25 23:36:39 +02:00
wmayer
88accdb421 PD: [skip ci] Fix several clazy issues:
* Maybe you meant to call base method instead [-Wclazy-skipped-base-method]
* Missing reference in range-for with non trivial type [-Wclazy-range-loop-reference]
* Mixing iterators with const_iterators [-Wclazy-strict-iterators]
* Unused QByteArray [-Wclazy-unused-non-trivial-variable]
* C++11 range-loop might detach Qt container (QList) [-Wclazy-range-loop-detach]
2022-07-25 13:40:19 +02:00
Uwe
1819aa9c0c [PD] TaskExtrudeParameters: add missing simplification
forgot this change in commit 98dae1b2
2022-07-20 11:35:46 +02:00
Uwe
98dae1b217 [PD] TaskExtrudeParameters: simplify code
to avoid several time the same translatable string
2022-07-20 03:16:56 +02:00
adrianinsaval
0e22ada9dd [PD Pad/Pocket] Fix bug with midplane usage in TwoLengths mode (#7216)
* [PD Pad/Pocket] Fix bug with midplane usage in TwoLengths mode
2022-07-20 03:13:01 +02:00
Uwe
43f289f27a [PD] [skip CI] FeatureExtrude.cpp: fix a comment 2022-07-19 03:30:48 +02:00