[Solved] 0.19pre PartWB, Attachment >Apply, donnot work

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
openBrain
Posts: 3979
Joined: Fri Nov 09, 2018 5:38 pm

Re: 0.19pre PartWB, Attachment >Apply, donnot work

Post by openBrain » Mon Mar 23, 2020 4:28 pm

wmayer wrote:
Mon Mar 23, 2020 4:23 pm
git commit bd0f5ca5c
:+1:
wmayer
Site Admin
Posts: 15753
Joined: Thu Feb 19, 2009 10:32 am

Re: 0.19pre PartWB, Attachment >Apply, donnot work

Post by wmayer » Mon Mar 23, 2020 4:33 pm

wmayer wrote:
Mon Mar 23, 2020 4:23 pm
However, I still encounter a weird problem: undo & redo works exactly 5 times and after doing undo the 6th time the placement of the object is not set correctly any more.
Doing a bit more testing it looks like that only the C++ version of the attachment dialog suffers from this problem while with the Python version I don't get it.
User avatar
DeepSOIC
Posts: 7600
Joined: Fri Aug 29, 2014 12:45 am
Location: Saint-Petersburg, Russia

Re: 0.19pre PartWB, Attachment >Apply, donnot work

Post by DeepSOIC » Mon Mar 23, 2020 7:38 pm

wmayer wrote:
Mon Mar 23, 2020 4:33 pm
Doing a bit more testing it looks like that only the C++ version of the attachment dialog suffers from this problem while with the Python version I don't get it.
Could it be that attachment reacts to changes to individual properties (onChanged) during the transaction unrolling/rerolling?
wmayer
Site Admin
Posts: 15753
Joined: Thu Feb 19, 2009 10:32 am

Re: 0.19pre PartWB, Attachment >Apply, donnot work

Post by wmayer » Mon Mar 23, 2020 8:37 pm

DeepSOIC wrote:
Mon Mar 23, 2020 7:38 pm
Could it be that attachment reacts to changes to individual properties (onChanged) during the transaction unrolling/rerolling?
If that was the case it would be really bad because it would mean that the whole transaction mechanism is flawed now.
wmayer
Site Admin
Posts: 15753
Joined: Thu Feb 19, 2009 10:32 am

Re: 0.19pre PartWB, Attachment >Apply, donnot work

Post by wmayer » Wed Mar 25, 2020 7:01 pm

openBrain wrote:
Mon Mar 23, 2020 9:59 am
While native Attachment editor (through Property Editor / MapMode) is now fully expression aware, the one from Part menu isn't at all.
git commit 3a0d9e8c5
User avatar
DeepSOIC
Posts: 7600
Joined: Fri Aug 29, 2014 12:45 am
Location: Saint-Petersburg, Russia

Re: 0.19pre PartWB, Attachment >Apply, donnot work

Post by DeepSOIC » Wed Mar 25, 2020 7:17 pm

wmayer wrote:
Wed Mar 25, 2020 7:01 pm
git commit 3a0d9e8c5
Ah, that's how it's done [expression support in python task dialogs]! good to know, thanks!!
fc_tofu
Posts: 519
Joined: Sun Jan 05, 2020 4:56 pm

Re: 0.19pre PartWB, Attachment >Apply, donnot work

Post by fc_tofu » Wed Mar 25, 2020 9:08 pm

wmayer wrote:
Wed Mar 25, 2020 7:01 pm
...
git commit 3a0d9e8c5
@wmayer, your new fix doesnot work on my machine. Please give a check.
fsc_2020-03-26_050322.jpg
fsc_2020-03-26_050322.jpg (25.85 KiB) Viewed 93 times
OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.20052 (Git)
Build type: Release
Branch: master
Hash: 6291921e9abe737e4440ff5814ca58547defadef
Python version: 3.8.2
Qt version: 5.12.5
Coin version: 4.0.0
OCC version: 7.4.0
Locale: Chinese/China (zh_CN)
wmayer
Site Admin
Posts: 15753
Joined: Thu Feb 19, 2009 10:32 am

Re: [PR] 0.19pre PartWB, Attachment >Apply, donnot work

Post by wmayer » Thu Mar 26, 2020 7:14 am

The actual binding was implemented with git commit ce3eadf289b
It's not possible to only override TaskAttachmentEditor.py without having rebuilt the FreeCADGui.dll.
wmayer
Site Admin
Posts: 15753
Joined: Thu Feb 19, 2009 10:32 am

Re: 0.19pre PartWB, Attachment >Apply, donnot work

Post by wmayer » Thu Mar 26, 2020 7:33 am

DeepSOIC wrote:
Wed Mar 25, 2020 7:17 pm
wmayer wrote:
Wed Mar 25, 2020 7:01 pm
git commit 3a0d9e8c5
Ah, that's how it's done [expression support in python task dialogs]! good to know, thanks!!
For the sake of completeness: the binding has been implemented only one day before with git commit ce3eadf289b

Afterwards I stumbled across the function https://github.com/FreeCAD/FreeCAD/blob ... x.cpp#L308 and how it can be used
https://github.com/FreeCAD/FreeCAD/blob ... Gui.py#L87
fc_tofu
Posts: 519
Joined: Sun Jan 05, 2020 4:56 pm

Re: [PR] 0.19pre PartWB, Attachment >Apply, donnot work

Post by fc_tofu » Thu Mar 26, 2020 3:54 pm

wmayer wrote:
Thu Mar 26, 2020 7:14 am
The actual binding was implemented with git commit ce3eadf289b
It's not possible to only override TaskAttachmentEditor.py without having rebuilt the FreeCADGui.dll.
Thanks, got it.
Post Reply

Who is online

Users browsing this forum: Bing [Bot], fc_tofu, papyblaise and 17 guests