MACRO:Work Feature 2014_12

Need help, or want to share a macro? Post here!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
rentlau_64
Posts: 181
Joined: Tue Oct 21, 2014 9:47 am
Location: Pau (France)

Re: MACRO:Work Feature 2014_12

Post by rentlau_64 »

Sgrogan,
yes i noticed that and i have the same behavior.
neverteless the functions of Curves and Surfaces tabs seems to works proprely!!?
I am looking to fix it.
thank you for your help.
i will keep you inform
Rentlau_64
User avatar
nemesis
Posts: 373
Joined: Tue Mar 25, 2014 11:24 pm
Location: France, Lyon

Re: MACRO:Work Feature 2014_12

Post by nemesis »

Works Fine for me also!
Thanks a lot again for this macro! Since I use it it has become mandatory for all my projects!
rentlau_64
Posts: 181
Joined: Tue Oct 21, 2014 9:47 am
Location: Pau (France)

Re: MACRO:Work Feature 2014_12

Post by rentlau_64 »

Hello,

I corrected the bug concerning the 'progressBar'. and committed.
not yet the close button behavior.

Have fun
Rentlau_64
User avatar
easyw-fc
Veteran
Posts: 3633
Joined: Thu Jul 09, 2015 9:34 am

Re: MACRO:Work Feature 2014_12

Post by easyw-fc »

rentlau_64 wrote: Have fun
Rentlau_64
Hi @ Rentlau_64
Great tools! :)

it would be possible to add a translation on axis?
I mean in Modif. Rotate it is possible to select an axis to use as reference for rotation and there is a slider to set the angle...
It would be nice if it would be possible to have the same also in Translate ... Adding to Start, End tab an Axis tab to set translation on axis and a slider to do the translation...

That would be useful when having to move on its axis a part that is not oriented to any main axis...

thx
Maurice
rentlau_64
Posts: 181
Joined: Tue Oct 21, 2014 9:47 am
Location: Pau (France)

Re: MACRO:Work Feature 2014_12

Post by rentlau_64 »

Maurice,
thank you, I am please that the macro helps you.
I will look for the axis translation,
long time i didn't touch this part of the code but 'apriori" seems not difficult to add.
Let see if I get some time to do it this week end, but quite sure next week.

Will keep you inform.
Rentlau_64
rentlau_64
Posts: 181
Joined: Tue Oct 21, 2014 9:47 am
Location: Pau (France)

Re: MACRO:Work Feature 2014_12

Post by rentlau_64 »

Hello!

A new release 2017-02-05 is available:
https://github.com/Rentlau/WorkFeature.git

documentation on releases at:
https://github.com/Rentlau/WorkFeature/ ... tation.pdf
some documentation at:
https://github.com/Rentlau/WorkFeature/ ... tation.pdf

Some Tutorials below:
/WorkFeature/Doc/Tutorials/
https://github.com/Rentlau/WorkFeature/ ... egment.mp4
https://github.com/Rentlau/WorkFeature/ ... Points.mp4
https://github.com/Rentlau/WorkFeature/ ... Points.mp4
WF_Tuto_WIRE_2DConvexPolygon.mp4
WF_Tuto_WIRE_CreatePolygon.mp4
WF_Tuto_WIRE_Regression2D.mp4
To see these files you must download the .zip file from github and go into /WorkFeature-master/WorkFeature/Doc/Tutorials/ directory after unzip.


@ easyw-fc
I added a Translation based on selection of a Axis/segment.
Hope it will help you?

Have fun.

Rentlau_64
Last edited by rentlau_64 on Thu Feb 09, 2017 6:22 am, edited 2 times in total.
User avatar
easyw-fc
Veteran
Posts: 3633
Joined: Thu Jul 09, 2015 9:34 am

Re: MACRO:Work Feature 2014_12

Post by easyw-fc »

by mistake I duplicated the post :oops:

Maurice
Last edited by easyw-fc on Mon Feb 06, 2017 1:32 pm, edited 3 times in total.
User avatar
easyw-fc
Veteran
Posts: 3633
Joined: Thu Jul 09, 2015 9:34 am

Re: MACRO:Work Feature 2014_12

Post by easyw-fc »

rentlau_64 wrote:Hello!

A new release 2017-02-05 is available:
https://github.com/Rentlau/WorkFeature.git
@ easyw-fc
I added a Translation based on selection of a Axis/segment.
Hope it will help you?

Have fun.

Rentlau_64
Hi @rentlau_64
I downloaded the latest WF macro and I placed it on my macro folder...
I can launch it, but if I try to apply a Translation or a Rotation to a Part I get errors...
Here a log:
Log: Loading GUI of Part module... done
Log: Init: Showing main window
Log: Main window restored
Log: Show main window
Log: Toolbars restored
Log: 3Dconnexion device not attached.
Log: Init: Entering event loop
Log: Init: Processing command line files
Msg: Loaded from common database : 22 curves !Msg:
Msg: Loaded from common database : 19 curves !Msg:
Msg: Combo View<PySide.QtGui.QDockWidget object at 0x0000026D921FE908>Msg:
Msg: Combo View<PySide.QtGui.QDockWidget object at 0x0000026D921FE908>
Msg: WorkFeatures<PySide.QtGui.QDockWidget object at 0x0000026D91B8CA88>Msg:
Msg: WorkFeatures<PySide.QtGui.QDockWidget object at 0x0000026D91B8CA88>
Msg: Tabified done !Msg:
Msg: Tabified done !
Err: Unhandled unknown exception caught in GUIApplication::notify.
Log: The event type 2 was sent to QPushButton
Object tree:
QPushButton (ObjRot_button_select) is child of
QFrame (frame_11) is child of
QWidget (rotate_tab_2) is child of
QStackedWidget (qt_tabwidget_stackedwidget) is child of
QTabWidget (tabWidget_9) is child of
QWidget (Modif_Tab_2) is child of
QStackedWidget (qt_tabwidget_stackedwidget) is child of
QTabWidget (tabWidget_7) is child of
QWidget (scrollAreaWidgetContents) is child of
QWidget (qt_scrollarea_viewport) is child of
QScrollArea (scrollArea) is child of
QWidget (Form) is child of
QWidget is child of
QDockWidget (WorkFeatures) is child of
Gui::MainWindowErr: Unhandled unknown exception caught in GUIApplication::notify.
Tested with FC 0.16 and FC 01.7 both 64b

more test:
if I launch the macro using "start_WF.FCMacro"
I get this error:
Traceback (most recent call last):
File "C:\Cad\Progetti_K\3D-FreeCad-tools\WorkFeature\WF_ObjRot_2015.py", line 362, in initialize
func.print_msg("initialize !")
File "C:\Cad\Progetti_K\3D-FreeCad-tools\WorkFeature\WF_2015.py", line 209, in print_msg
print message
AttributeError: 'list' object has no attribute 'write'
EDIT
I found:
I had to comment all the occurrence of

Code: Select all

print message
in .py files
now it works fine

Thx
Maurice
rentlau_64
Posts: 181
Joined: Tue Oct 21, 2014 9:47 am
Location: Pau (France)

Re: MACRO:Work Feature 2014_12

Post by rentlau_64 »

Maurice,

Thank for the info. unfortunately never see this kind of error.
Seems to be relative to a "list" to print!?
Could you describe me the suite of actions you realized to get this error in order to me to reproduce and fix it. (better if you give me a FreeCAD file also)

Merci

Rentlau_64

PS: I use:

OS: Ubuntu 15.04
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.16.6692 (Git)
Build type: None
Branch: master
Hash: 87293fac9bb85c5f5e0ebf563374e27d565116ae
Python version: 2.7.9
Qt version: 4.8.6
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17
User avatar
easyw-fc
Veteran
Posts: 3633
Joined: Thu Jul 09, 2015 9:34 am

Re: MACRO:Work Feature 2014_12

Post by easyw-fc »

rentlau_64 wrote:Maurice,

Thank for the info. unfortunately never see this kind of error.
Seems to be relative to a "list" to print!?
Could you describe me the suite of actions you realized to get this error in order to me to reproduce and fix it. (better if you give me a FreeCAD file also)

Merci

Rentlau_64
EDIT
any "print" occurrence will trig the error, not only "print message" I've found

It should be enough to enable python redirect to report view to trig the error
python-redirect.png
python-redirect.png (59.71 KiB) Viewed 3558 times
Post Reply