Commit Graph

82 Commits

Author SHA1 Message Date
Ladislav Michl
9683cf1e4f Base: rename Exception's PascalCase methods to camelCase 2025-05-05 23:50:01 +02:00
Kacper Donat
c05ade50ae PartDesign: Use freecad_cast whenever possible 2025-04-26 14:23:25 +02:00
Benjamin Bræstrup Sayoc
e2f018ceeb PartDesign: Use QStringLiteral 2025-02-10 18:34:57 +01:00
tritao
551c2e48fb Gui: Reorganize the selection files into a top Selection folder. 2025-02-03 17:56:57 +01:00
Benjamin Nauck
6f535f19fb Prefer to use BaseClass's isDerivedFrom<T> over non template or Base::Type's
Regex based changes, manually verified
2025-01-27 16:08:18 +01:00
wmayer
e56b85f6e1 Gui: Use bitmask instead of three booleans in setTemporaryVisibility to improve readability 2024-12-31 13:29:01 +01:00
PaddleStroke
b2f965c06e ViewProviderOrigin: Renamed to ViewProviderCoordinateSystem 2024-11-27 12:15:53 +01:00
wmayer
2b4b8e4479 PD: Cleanup code of TaskRevolutionParameters 2024-11-22 11:59:21 -05:00
mwganson
4fd0e2c89d [PartDesign Groove/Revolution] minor dialog improvements, addresses issue #13298 2024-10-27 12:12:36 +01:00
wmayer
010a36df30 PD: Add template helper functions to safely access feature or view provider
In subclasses of TaskFeatureParameters use the new helper functions and check for null pointer. This fixes #15453
2024-07-18 13:40:08 +02:00
wmayer
01d1e2b374 PD: Make blockUpdate private class member 2024-07-17 20:09:53 +02:00
Ajinkya Dahale
f9a71ae096 [PD] Fix reference axis selection in revolve/groove
Fixes #11713.
2024-01-08 14:19:57 -03:00
Ajinkya Dahale
518b48ffaf [PD] Set up-to-face when opening revolution/grove task box 2023-12-04 13:40:31 -03:00
Ajinkya Dahale
48a1db8a76 [PD] Fix wrong mode options when opening existing revolution
Only the "Dimension" options showed regardless of what mode was selected.
2023-12-04 13:40:31 -03:00
Ajinkya Dahale
8113f12337 [PD] Set revolution taskview items based on method 2023-11-14 00:20:20 +05:30
Ajinkya Dahale
c7101d7ced [PD] Support two-angle/up-to-face groove
Elements copied from revolution and pocket feature.
2023-11-14 00:20:20 +05:30
Ajinkya Dahale
796727fcd3 [PD] Use enum class for revolution method 2023-11-14 00:20:20 +05:30
Ajinkya Dahale
5a51a490a8 [PartDesign] Some more dummy functionality for revolution
[PD] Some more setup

[PD] Some refactor in `TaskRevolutionParameters`
2023-11-14 00:20:19 +05:30
Ajinkya Dahale
82b5e16cd1 [PartDesign] Add some dummy options for revolution
These options correspond to "up to face" and "2 angles". They are expected to do
nothing right now. However there is also some experimental code for "up to face"
in this commit, whose behavior is not confirmed.
2023-11-14 00:20:19 +05:30
Uwe
b74425b441 [PD] revolve: remove unused code
- also come code style unification
2023-03-22 17:46:03 +01:00
wmayer
05959a2beb PD: fix crash in TaskRevolutionParameters::fillAxisCombo
* Replacing the static_cast with a dynamic_cast in 668adaacdf is a regression because it cannot be guaranteed that the linked object is a sketch.
  In fact it can also be a shape binder which is explicitly allowed.
  Forum: https://forum.freecadweb.org/viewtopic.php?f=19&t=74939
* Move initialization of some variables into the if-statement
2023-01-02 09:49:27 +01:00
wmayer
7b67ff7ea0 PD: fix crash in TaskRevolutionParameters::addAxisToCombo
and some warnings reported by GH actions
2022-11-09 18:56:11 +01:00
wmayer
a6be2a28bc PD: [skip ci] improve the exception text 2022-11-09 17:46:46 +01:00
Uwe
17730a12cb [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
wmayer
93ab955873 PD: use Base::StateLocker to simplify handling of blockUpdate and make it exception-safe 2022-11-05 19:29:20 +01:00
wmayer
b5bd12a069 PD: fixes #7629: Keep sketch visible during revolution tasks 2022-11-05 19:09:54 +01:00
berniev
f4ffd15864 Mod: redundant void 2 2022-08-08 10:27:50 +02:00
Uwe
16b25c5dab [PD] remove superfluous nullptr checks 2022-07-17 18:12:41 +02:00
wmayer
d1d4b996e7 PD: modernize C++11
* use nullptr
2022-03-23 19:26:14 +01:00
wmayer
8f786ea6ef Gui: Optimize includes to reduce compile time 2022-03-07 20:29:18 +01:00
Uwe
037b2796b3 [PD] Hole, Pipe and Revolution: remove unused includes 2022-02-19 18:47:26 +01:00
wmayer
90db4c885b PD: eliminate the boolean argument from TaskSketchBasedParameters::onSelectReference 2021-12-07 11:04:22 +01:00
wmayer
b165947625 PD: cleanup the mess with boolean arguments and replace them with a bitmask 2021-12-03 14:46:19 +01:00
wmayer
70ca3580a1 PD: improve task panel for revolution/groove:
* set range Angle property to spin box
* connect signals after initializing widgets to avoid superfluous recomputes
2021-03-03 15:42:48 +01:00
wmayer
6364a4cb7d PD: [skip ci] set value range to angle spin box 2021-03-03 15:22:53 +01:00
David Osterberg
c862ec458c PartDesign: Allow use of circle edge as axis in ProfileBased 2021-03-01 14:48:24 +01:00
donovaly
b483fc0518 [PD] make pointers to the UI std::unique_ptr
Same as PR #4293, just for PartDesign

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 PartDesign dialogs that don't already use a unique_ptr.
2021-02-05 18:01:57 +01:00
luz paz
a65b3788c6 PartDesign: Issue #0004473: Expose openCommand() to translation
Continuing the work to expose the undo/redo functionality to translation. This commit does so for the PartDesign Wb.  
Ticket: https://tracker.freecadweb.org/view.php?id=4473
2020-12-01 14:53:35 +01:00
wmayer
ad48dd2538 PartDesign: [skip ci] Improve revolution function
+ Fix hard crash when selecting an edge or face of the created feature before selecting option to choose a reference.
+ In ProfileBased::getAxis() convert OCCT into FreeCAD exception to simplify handling of calling instances.
+ Change return value of getReferencedSelection() from void to bool to mkae it easier for calling instance to detect if the selection failed.
  This is needed to avoid to add invalid items to the combo box of the revolution task panel
2020-10-14 15:20:52 +02:00
Zheng, Lei
cd2b7e297c PartDesign changes
* Mostly for supporting in-place editing

* Add new SubShapeBinder that support cross coordinate system,
  external, and sub-object binding
2019-08-17 15:15:47 +02:00
wmayer
1d26a2d930 various fixes:
+ fix invalid cast
+ some minor optimizations
+ improve exception handling
2017-10-18 12:33:41 +02:00
wmayer
c526c18b94 fix scan coverity issues: uncaught exception 2017-04-11 14:03:08 +02:00
wmayer
4dcb8d64d8 fix crash when cancelling revolution task panel 2017-01-23 23:24:40 +01:00
wmayer
dd7c91ddcf fix -Wextra in PartDesign 2016-09-22 18:34:56 +02:00
Stefan Tröger
ae9dac71d7 PartDesign: Modeling features work with faces
-Rename Sketchbased to ProfileBased to show new behavior
-Adopt ProfileBased to make the relevant helper functions work with faces too
-Adopt features for unified use of helper functions
-Adopt commands to allow face selection
2016-04-12 18:12:22 +02:00
Stefan Tröger
463070b1f6 Fix crash on aborted pattern external axis 2016-04-12 18:12:22 +02:00
Alexander Golubev
e8b323ba20 PartDesignGui: small rework to sketch-based task parameters
This done mostly for thurther unification them with other task
parameters/dialogs.
2016-04-12 18:12:21 +02:00
Alexander Golubev
27667cf5e6 Fix warnings introduced in new PartDesign
Mostly unused wariables and compare of signed & unsigned
2016-04-12 18:12:21 +02:00
Alexander Golubev
3ed51ac4bd PartDesign: add Origin to the Body and unstrap the module from the Parts 2016-04-12 18:12:18 +02:00
Alexander Golubev
d72a919384 OriginGroup: add new abstraction layer between the Part and the GeoFeatureGroup 2016-04-12 18:12:18 +02:00