Hello.
I have a compound object made-up of several solids. How can I set the view properties (i.e. the shape color) of each solid using Python?
Thanks in advance.
Search found 254 matches
- Wed Apr 03, 2024 6:19 pm
- Forum: Python scripting and macros
- Topic: Setting the view properties of the solids in a compound
- Replies: 11
- Views: 903
- Sat Mar 30, 2024 12:31 am
- Forum: FEM
- Topic: FreeCAD as pre-post processor for MBDyn
- Replies: 437
- Views: 176930
- Sat Mar 30, 2024 12:07 am
- Forum: Python scripting and macros
- Topic: A property list of properties.
- Replies: 3
- Views: 341
Re: A property list of properties.
Good question. I've resorted to hacks like: obj = App.ActiveDocument.addObject("Part::Feature", "CustomObject") obj.addProperty("App::PropertyStringList", "ListOfTuples", "Parameters", "List of Vector Tuples") obj.ListOfTuples = ['(0,0,0)'...
- Fri Mar 29, 2024 10:35 pm
- Forum: Python scripting and macros
- Topic: A property list of properties.
- Replies: 3
- Views: 341
A property list of properties.
Hi. Is there a way to add a list property to a scripted object, such as a list of vectors: obj.addProperty("App::PropertyVectorList", "ThePropertyName", "Subsection", "Description for tooltip") but using other properties for the list? For example a list of mas...
- Wed Mar 27, 2024 1:39 pm
- Forum: Python scripting and macros
- Topic: Problem with "App::PropertyIntegerConstraint"
- Replies: 4
- Views: 484
Re: Problem with "App::PropertyIntegerConstraint"
Is this the intended behavior? How can I have it always inside the range?edwilliams16 wrote: ↑Wed Mar 27, 2024 12:57 am Yes. If I save and restore, it no longer heeds the constraints.
- Wed Mar 27, 2024 12:00 am
- Forum: Python scripting and macros
- Topic: Problem with "App::PropertyIntegerConstraint"
- Replies: 4
- Views: 484
Re: Problem with "App::PropertyIntegerConstraint"
Is anyone having this problem? I have found that it works fine when I just added the property, but after closing and opening the file, it wont respect the max and min values any more...
- Sun Mar 17, 2024 2:05 am
- Forum: Open discussion
- Topic: MBDYN
- Replies: 7
- Views: 1159
Re: MBDYN
Hello. Sorry the late reply. The thing is that Im not using GitLab anymore. Basically because nobody but me is contributing to the code and because my time to work on this project is very limited and because Im not very good with git. So I simply regularly upload the workbench into a shared google d...
- Sun Mar 17, 2024 1:51 am
- Forum: Python scripting and macros
- Topic: Problem with "App::PropertyIntegerConstraint"
- Replies: 4
- Views: 484
Problem with "App::PropertyIntegerConstraint"
Hi. Im trying to use App::PropertyIntegerConstraint as provided in the example: obj = FreeCAD.ActiveDocument.addObject("App::FeaturePython", "InternalObjectName") obj.Label = "User-friendly label" obj.addProperty("App::PropertyIntegerConstraint", "TheProp...
- Wed Dec 27, 2023 6:57 pm
- Forum: Python scripting and macros
- Topic: cancel method
- Replies: 1
- Views: 289
cancel method
Hi. I followed this tutorial on creating and adding dialogs: https://wiki.freecad.org/Manual:Creating_interface_tools The def accept(self): method is executed when user clicks Ok button. What is the method for cancel button? I thought it would be def cancel(self): but it does not work. Thanks...
- Fri Oct 06, 2023 10:25 pm
- Forum: FEM
- Topic: FreeCAD as pre-post processor for MBDyn
- Replies: 437
- Views: 176930
Re: FreeCAD as pre-post processor for MBDyn
Hello. The "MBD workbench" can now also act as an assembly workbench (yes, yet another assembly workbench); using MBDyn to solve the assembly. It is now possible to put together relatively complex assemblies. Here is an example: https://www.youtube.com/watch?v=zuqqGvZJGhc Of course, once t...