Commit Graph

20 Commits

Author SHA1 Message Date
berniev
75acacd1b7 Gui: Use auto and range-based for (#7481)
* On lines where the variable type is obvious from inspection, avoid repeating the type using auto. 
* When possible use a ranged for loop instead of begin() and end() iterators
2022-09-14 13:25:13 -05:00
berniev
656ef8961f Gui: redundant void 2 2022-08-08 10:21:44 +02:00
wmayer
e9890c0798 Gui/Mod: replace several reinterpret_cast with static_cast 2022-06-25 11:36:55 +02:00
wmayer
96adb98f46 Gui: modernize C++11
* use nullptr
2022-03-23 18:41:21 +01:00
Uwe
f706adc2c2 [Gui] ViewProviderDocument* etc.: remove unused includes 2022-03-06 00:01:37 +01:00
Uwe
bf07e0752e [Gui] ViewProviderDragger: add missing include 2022-02-17 04:35:10 +01:00
Uwe
fa08936b3a [Gui] ViewProviderDragger: remove unused includes
- also sort them
2022-02-17 04:13:53 +01:00
Uwe
c17f118976 [Gui] add context menu icon for Std_TransformManip
- the other context menu entries have icons and we use this icon already in the Edit menu

- also sort the includes
2022-02-17 03:49:02 +01:00
luz paz
4f886b2b8c Fix various typos and refinements 2022-01-06 20:22:34 +01:00
luz paz
74ab516494 Gui: Issue #0004473: Expose openCommand() to translation
Continuing the work to expose the undo/redo functionality to translation. This commit does so for the src/Gui code.  
Ticket: https://tracker.freecadweb.org/view.php?id=4473
2020-12-01 14:53:35 +01:00
luz paz
298c677873 Gui: Fix header uniformity, whitespace, and doxygen fixes 2020-11-26 10:14:56 +01:00
wmayer
31ff1921ce Gui: [skip ci] add method extensionSetupContextMenu to extension view provider 2020-11-08 13:36:31 +01:00
Zheng, Lei
1cbec1a60d Gui: fix Std_Transform tool
The problem is caused by tracking of editing object placement
introduced in 719c11e714.

After this commit, any editing object can disable placement tracking by
calling Gui::Document::setEditingTransform() inside either
ViewProvider::startEditing() or setEditingViewProvider().
2019-12-21 15:17:48 +01:00
luz.paz
0f67e8ddfa Fix typos in src/Gio 2019-08-17 15:32:49 +02:00
Zheng, Lei
00bcef0619 Gui: support in-place editing
The link support means that an object can now appear in more than one
places, and even inside a document different from its own. This patch
adds support for in-place editing, meaning that the object can be edited
at correct place regardless where it is.

See [here](https://git.io/fjPIk) for more info about the relavent APIs.

This patch includes two example of modifications to support in-place
editing. One is the ViewProviderDragger, which simply adds the dragger
node to editing root node by calling
View3DInventorViewer::setupEditingRoot(dragger). The other much more
complex one is ViewProviderSketch which calls setupEditingRoot(0) to
transfer all its children node into editing root. ViewProviderSketch
also includes various modifications to command invocation, because we
can no longer assume the active document is the owner of the editing
object.

This patch also includes necessary modification of the 'Show' module to
support in-place editing.
2019-08-17 15:08:32 +02:00
wmayer
4b468ebed1 call updateData of base class for ViewProviderDragger and ViewProviderGeometryObject 2019-07-02 12:08:23 +02:00
wmayer
8f3a53c24c move check for grabbed node and releasing it from ViewProviderDragger::unsetEditViewer to View3DInventorViewer::resetEditingViewProvider 2018-09-11 17:27:17 +02:00
wmayer
fd2befe7a7 when leaving dragger edit mode make sure to release the grabbed node 2018-09-06 12:42:08 +02:00
wmayer
f3f857fc8d fix possible crash with draggers in transform edit mode of a view provider 2018-03-18 10:11:35 +01:00
wmayer
0973dd5e7b add class ViewProviderDragger
derive ViewProviderGeometryObject from ViewProviderDragger
derive ViewProviderPart from ViewProviderDragger
2017-11-26 15:42:57 +01:00