DynamicData v2.59

Info about new community or project announcements, implemented features, classes, modules or APIs. Might get technical!
PLEASE DO NOT POST HELP REQUESTS OR OTHER DISCUSSIONS HERE!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

DynamicData v2.59

Post by TheMarkster »

Latest version 2.59

Lots of changes in recent days. Biggest change is dropping the "dd" prefix. You can still add "dd" to the beginning of your property names if you want to, but it's no longer done automatically or needed. The prefix was useful in older versions where the expression engine picklist didn't work unless you had entered at least the first 2 characters of your property name, but now that issue has been fixed. Other improvements: now you get a nice preview evaluation of your property value, and hints for many property types in the form of placeholder text. You also get a message if there is a naming conflict or if the name you have chosen is invalid for a property name.
Snip macro screenshot-685bb5.png
Snip macro screenshot-685bb5.png (19.7 KiB) Viewed 1993 times
Notice in the image above how the variable name "1Color" is invalid (because property names cannot begin with a numeral) and there is a red text warning message showing this and even a suggested new name. This suggestion of a new name is also provided where there is a naming conflict with an existing attribute. And the Color property can now be initialized in 3 ways: as a tuple (255,0,0); as the name of the color, e.g. "red"; or with familiar html hexadecimal syntax: #ff0000.

Another big change is in the copy command dialog. The code in that command class was... messy, to put it mildly. That has been cleaned up some to make the code more easily maintainable and the interface is much nicer for the user. All the options are presented in one dialog, unless it is required to rename a property before adding it with the copy option, in which you get a popup where you enter the new name.
Snip macro screenshot-93c3a8.png
Snip macro screenshot-93c3a8.png (49.98 KiB) Viewed 1993 times
In the image above you can see the new copy / set / bind dialog. Notice the blue text at the bottom, giving you a preview of the action to be performed. If the action cannot be performed an appropriate message in red text will be displayed. In this dialog you can copy a property from one object to the other. Copying creates a new property in the destination object (the one the arrow is pointing to) and sets it to the same value as the source property selected in the source object list widget. Setting doesn't create a new property in the destination object, but rather sets an existing property to the same value as the selected property in the source object. Binding binds the source object's property to the destination object's selected property via expressions. The properties must be the exact same type for this to be performed, and there must also not be a circular dependency created, both of which are checked for before you attempt to perform the action. The other function is to break the binding of the selected property.

The documentation on github is in need of updating to reflect the recent changes. That's next on my todo list.
Last edited by TheMarkster on Fri Dec 15, 2023 7:26 am, edited 3 times in total.
User avatar
bambuko
Veteran
Posts: 2165
Joined: Thu Oct 24, 2019 12:53 pm
Location: UK, England, North Devon

Re: DynamicData now supports renaming groups

Post by bambuko »

TheMarkster wrote: Sat Mar 12, 2022 7:24 am ... version 2.39 DynamicData ...
just out of curiosity - is there a way to check which version I currently have?
(I have updated regardless :) )
Thank you!
I am using Link branch and Assembly3
you can also download ... and try it here
excellent Assembly3 tutorials here
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: DynamicData now supports renaming groups

Post by TheMarkster »

bambuko wrote: Sat Mar 12, 2022 8:21 am
TheMarkster wrote: Sat Mar 12, 2022 7:24 am ... version 2.39 DynamicData ...
just out of curiosity - is there a way to check which version I currently have?
(I have updated regardless :) )
Thank you!
I forgot to update the version information in the class file. I'll push a new update to 2.40 so it shows the version correctly in new objects in the DynamicData property.

Edit: Done. I also added version information to the settings page when it is opened from the DynamicData menu.
User avatar
jruiz
Posts: 479
Joined: Tue Oct 28, 2014 1:07 pm
Contact:

Re: DynamicData now supports editing tooltips

Post by jruiz »

TheMarkster wrote: Sat Mar 12, 2022 7:24 am As of version 2.42 DynamicData now supports editing tooltips of dynamic properties.

Now we can edit property names, group names, and tooltip values.

###############################
...
.
.
.
Excellent!

IMHO, the use of Dynamic Data "should be a must" for any FreeCAD project.

Great job!
I have uploaded many FreeCAD video tutorials to my YouTube channel
edwilliams16
Veteran
Posts: 3109
Joined: Thu Sep 24, 2020 10:31 pm
Location: Hawaii
Contact:

Re: DynamicData now supports editing tooltips

Post by edwilliams16 »

TheMarkster wrote: Sat Mar 12, 2022 7:24 am As of version 2.42 DynamicData now supports editing tooltips of dynamic properties.
Given the capability you have built in to the ParametricCurve_FP Macro, it seems it might be possible to build a configuration Save/Restore feature into your Dynamic Data Workbench.
This would provide a nice alternative to using Spreadsheet Configurations (which I have yet to try out...) to keep a number of variations of a model - particularly where it requires some tweaking to get a parameter set one desires.
I envisage a drop-down menu of parameter sets to which one can add/remove/edit etc. similar to that in the Parametric Curve Macro.
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: DynamicData now supports editing tooltips

Post by TheMarkster »

Interesting idea.
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: DynamicData now supports editing tooltips

Post by TheMarkster »

edwilliams16 wrote: Mon Mar 28, 2022 8:58 pm
TheMarkster wrote: Sat Mar 12, 2022 7:24 am As of version 2.42 DynamicData now supports editing tooltips of dynamic properties.
Given the capability you have built in to the ParametricCurve_FP Macro, it seems it might be possible to build a configuration Save/Restore feature into your Dynamic Data Workbench.
This would provide a nice alternative to using Spreadsheet Configurations (which I have yet to try out...) to keep a number of variations of a model - particularly where it requires some tweaking to get a parameter set one desires.
I envisage a drop-down menu of parameter sets to which one can add/remove/edit etc. similar to that in the Parametric Curve Macro.
Better late than never, I guess. Newest version now has a configuration creation and editing tool. Another new feature is to be able to edit enumeration properties via the Gui.

Here is a screenshot of the configuration editor:
create_configuration_scr.png
create_configuration_scr.png (15.45 KiB) Viewed 7335 times
It is still a bit of a work in progress, but currently in a usable state.
edwilliams16
Veteran
Posts: 3109
Joined: Thu Sep 24, 2020 10:31 pm
Location: Hawaii
Contact:

Re: DynamicData now supports editing tooltips

Post by edwilliams16 »

TheMarkster wrote: Sun Sep 24, 2023 11:22 pm
I like it. In my tryout, I'm not sure how I ended up with longer property lists than I have configurations - but it isn't causing a problem AFAIK.
Attachments
ddconfiguration.FCStd
(6.61 KiB) Downloaded 208 times
Screenshot 2023-09-24 at 2.28.31 PM.png
Screenshot 2023-09-24 at 2.28.31 PM.png (155.52 KiB) Viewed 7311 times
Screenshot 2023-09-24 at 2.28.56 PM.png
Screenshot 2023-09-24 at 2.28.56 PM.png (89.11 KiB) Viewed 7311 times
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: DynamicData now supports editing tooltips

Post by TheMarkster »

An extra float is added to each FloatList. The value is taken from the first item in the list and this becomes the default configuration, such as when the enumeration shows something like "Select size". It was that or do away with the "select size" and just show the first enum.
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: DynamicData v2.59

Post by TheMarkster »

Version 2.59 is now out. I have edited the first post to reflect the recent changes.
Post Reply