Commit Graph

264 Commits

Author SHA1 Message Date
wmayer
e4d531bb8b Py3.8: missing initializer for member '_typeobject::tp_vectorcall' [-Wmissing-field-initializers] 2020-06-08 14:32:21 +02:00
wmayer
e47515beb0 PySide: [skip ci] add minimal example of embedding 2020-05-20 13:23:18 +02:00
wmayer
37c21cfb13 [skip ci] Port glib embedding example to Py3 and Gtk3 2020-05-20 12:47:17 +02:00
wmayer
52344f6508 [skip ci] part Qt embedding test application to Py3 and implement workaround for Qt5 2020-04-30 21:03:53 +02:00
luz.paz
d8b41f70d6 [skip-ci] Fix typos in Draft, Mesh, and src/Tools
Found via codespell v1.17.0.dev0  
```
codespell -q 3 -L aci,ake,aline,alle,alledges,alocation,als,ang,anid,ba,beginn,behaviour,bloaded,byteorder,calculater,cancelled,cancelling,cas,cascade,centimetre,childs,colour,colours,commen,connexion,currenty,dof,doubleclick,dum,eiter,elemente,ende,feld,finde,findf,freez,hist,iff,indicies,initialisation,initialise,initialised,initialises,initialisiert,ist,kilometre,lod,mantatory,methode,metres,millimetre,modell,nd,noe,normale,normaly,nto,numer,oder,orgin,orginx,orginy,ot,pard,pres,programm,que,recurrance,rougly,seperator,serie,sinc,strack,substraction,te,thist,thru,tread,uint,unter,vertexes,wallthickness,whitespaces -S ./.git,*.po,*.ts,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig*,./src/Mod/Robot/App/kdl_cp,./src/Mod/Import/App/SCL,./src/WindowsInstaller,./src/Doc/FreeCAD.uml
```
2020-04-30 11:40:38 +02:00
wmayer
843d394957 Tools: [skip ci] move import of requests module into try/except block 2020-04-15 10:39:46 +02:00
wmayer
890809bcb0 [skip ci]: make SubWCRef not to fail if internet connection is blocked 2020-04-14 12:38:53 +02:00
wmayer
27a475d84b Tools: [skip ci] implement method to get commit number, date and branch name from sha 2020-04-13 13:32:32 +02:00
donovaly
b935c12ae0 [Tools] remove ThumbnailProvider.sln
This single files does not help anything, one would also need the *.vcxproj files. But whatever I try, unless you run not CMake prior to compiling, it will try to build a Win32 DLL and fails.
So since I cannot find a way to provide .sln and .vcxproj files that can be used out of the box, the single .sln file is just senseless alone.
2020-04-01 13:29:39 +02:00
donovaly
f05b38c502 [Tools] add Visual Studio project files
see: https://forum.freecadweb.org/viewtopic.php?f=10&t=44609&start=10#p381463

One needs all 4 files. It works on difference PCs since all paths are relative.
2020-03-31 12:05:45 +02:00
donovaly
d1d85c6207 [Tools] extend ThumbNail Provider for .FCBak
- as requested in the forum, the thumbnail provider should also work for *.FCBak file, see
https://forum.freecadweb.org/viewtopic.php?f=4&t=10775&p=381936#p378680
2020-03-31 12:01:53 +02:00
luz.paz
fad1badd05 Fix typo in templateClassPyExport.py [skip ci] 2019-12-23 16:50:23 +01:00
luz.paz
0c6786d4bf Templates: fix header uniformity
This PR fixes header uniformity across all template files.
2019-12-21 16:12:54 +01:00
wmayer
228f89638d Python: change generation of callback functions for class or static methods 2019-12-19 17:55:12 +01:00
luz.paz
06cf1d5b70 Fix various typos [skip ci]
Fixed via 
```
codespell -q 3 -L aci,ake,aline,alle,alledges,alocation,als,ang,anid,ba,beginn,behaviour,bloaded,byteorder,calculater,cancelled,cancelling,cas,cascade,centimetre,childs,colour,colours,commen,currenty,dof,doubleclick,dum,eiter,elemente,feld,freez,hist,iff,indicies,initialisation,initialise,initialised,initialises,initialisiert,ist,kilometre,lod,mantatory,methode,metres,millimetre,modell,nd,noe,normale,normaly,nto,numer,oder,orgin,orginx,orginy,ot,pard,pres,programm,que,recurrance,rougly,seperator,serie,sinc,strack,substraction,te,thist,thru,tread,uint,unter,vertexes,wallthickness,whitespaces -S ./.git,*.po,*.ts,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig*,./src/Mod/Robot/App/kdl_cp,./src/Mod/Import/App/SCL,./src/WindowsInstaller,./src/Doc/FreeCAD.uml
```
2019-12-17 15:13:48 -03:00
wmayer
1ec6701519 handle nested name spaces in Python generation script 2019-11-20 22:57:58 +01:00
wmayer
5c7bef0ad8 add support of static and class methods in Python wrappers 2019-11-12 23:24:42 +01:00
wmayer
3cd487064e make PythpnToCPP script Py2 compliant 2019-11-05 21:11:10 +01:00
Huang, Zhaoquan
69b98c48ea Explicitly specify encoding in PythonToCPP.py
On Windows, the python script opens a file with the default ANSI
encoding. This causes UnicodeDecodeError in some region. The encoding
should be set explicitly to match the files.
2019-11-05 09:28:44 -03:00
donovaly
0b1b9160ab ThumbnailProvider: update MSVC solution file
Now ThumbnailProvider can be compiled easily using MSVC 2017
2019-11-05 10:15:20 +01:00
wmayer
5476ab4b61 fix building of thumbnail dll for msvc 2017 or higher 2019-11-04 19:08:54 +01:00
luz.paz
1bc33025d6 LGTM: various fixes for using string operator instead of numeric 2019-10-25 10:33:12 -03:00
wmayer
e4f8d98079 add new CMake macro generate_from_any and extend PythonToCPP script to create source file from any text file 2019-10-14 22:20:59 +02:00
Przemo Firszt
9a82946296 SubWCRev out ot source build fix by sopwith
Signed-off-by: Przemo Firszt <przemo@firszt.eu>
2019-09-21 13:14:46 +02:00
luz.paz
f22ae848ea Fix misc. typos, whitespace, and http:// to https:// issues 2019-09-03 11:11:43 -03:00
Zheng, Lei
8ecee3c413 Tools: modify exception catch implemention in templateClassPyExport 2019-08-28 17:46:07 +02:00
luz.paz
eb595acfec Fix misc. source comment typos
Found via `codespell -q 3 -I ../fc-word-whitelist.txt -S ./.git,*.po,*.ts,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig*,./src/Mod/Robot/App/kdl_cp,./src/Mod/Import/App/SCL,./src/WindowsInstaller`  
Fix ./src/Tools/fcinfo grammar + whitesapce  
Fix typos in ./src/Mod/Mesh/App/Core/Evaluation.cpp
2019-08-07 20:16:45 -04:00
Yorik van Havre
b013624ba8 Tools: added --gui option to fcinfo tool 2019-07-28 13:59:03 -03:00
Yorik van Havre
1919659fad Tools: Small additional fix in fcinfo tool 2019-07-27 15:59:03 -03:00
Yorik van Havre
b351c3da5a Tools: More options to fcinfo tool 2019-07-27 15:48:51 -03:00
luz.paz
3fe94ea7cf [Crowdin] string fix + misc. typo and whitespace fixes
* Crowdin link: https://crowdin.com/translate/freecad/6766/en-hu#6576162  
* Tacked on a few typo+whitespace fixes
2019-06-20 18:42:09 +02:00
Yorik van Havre
2713078b25 Tools: Prefer using Qt5 translation tools over Qt4 2019-06-17 19:32:37 -03:00
Yorik van Havre
1186bf45e1 Tools: Added AddonManager to translation scripts 2019-06-17 17:26:19 -03:00
wmayer
0e17c22e39 Py3: make fcbt scripts working 2019-05-20 19:02:35 +02:00
luz.paz
8d5fbd947b FIx some user and non-user facing typos
Found via ` codespell -q 3 -I ../fc-word-whitelist.txt -S ./.git,*.po,*.ts,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig* -L pard,wallthicknessOn`  
codespell version 1.15.0.dev0
2019-05-12 16:59:26 +02:00
Yorik van Havre
19d38abce6 Tools: small fix in update script 2019-05-10 19:18:52 -03:00
Russell Johnson
aaae829704 Path: Integrate 4th-axis feature to PathPocketShape and 3D Surface ops (#2114)
* PathSurface: Add StepDown support

Add StepDown support for PathSurface operation.
A low-level optimization algorithm is included.

* Update PageOpSurfaceEdit.ui

* PathSurface: Activate CompletionMode input

Update code to use CompletionMode selection from user.

* PathSurfaceGui: Add Completion Mode selection box

Add Completion Mode selection box for user input.

* PathSurface: Use depth_params() for step control

Implemented PathUtils.depth_params() for control of step downs to maintain consistency throughout PathWB.
Suggested by Sliptonic.

* PathSurface: Improve stability - Rev3

Organized code better, improved path optimization algorithm

* PathSurface: Add XY rotational surfacing

Add options to perform 3D surfacing by rotating object around X or Y axis.

* PathSurface: update setup function

Add properties to setup function

* PathSurface: Remove extraneous code

removed commented lines that consume processing time

* PathSurface: Correct nxt.z point assignment

Corrected error in nxt.z value assignment. Was assigning value to pnt.z instead of nxt.z

* PathSurface: Update 4th axis operation

Provided both parallel and perpendicular to axis  scans when performing rotational operation.

* PathSurface: Corrected Y-axis rotation to gcode

Inverted Y-axis scan values in gcode to produce correct result

* PathSurface: Adjust gcode feed rates

Adjust feed rates for axial rotations

* PathSurface: Implement waterline alternative

Used OCL dropcutter scan as data base for python algorithm to extract a waterline.  Waterline also incorporates step down feature.

* PathSurface: Update to 3m-Usable

stability improvements
fixed step on multi-pass 4th axis scans
initiate code to accommodate cut modes: zigzag, line
initiate code to accommodate offset cutter on 4th axis scans to simulate a tilted cutter for ball end mills

* PathSurface: Update 3m-Usable_r1

change instantiated static class attributes from value None, to 0.0

* PathSurface: Revert to 3i-Usable_r1

Further testing needed for 3m-Usable release

* PathSurface: Update to Rev. 3s Usable

fixed step over in rotational scans
start/stop indexes
tilt cutter adaptation for ball end mill
cut pattern: zigzag, line partially implemented
ignore waste option initiated for planar scans
cut mode partially implemented: conventional & climb

* PathSurface: Update to Rev. 3t Usable

Corrected rotational errors
corrected cutter tilt rotation
added "ignore waste" feature for planar surface operation

* Implement 4th-axis feature

Implement 4th-axis feature:
add gcode commands for rotation
re-compute operation heights, to consider rotation radii

* Deleted reference to undeclared variable

* Added missing class attributes/variables

* Added missing class variables/attributes

* Relocate class variables to higher class

* Remove references to undeclared variables

relocated class variables here
delete references to undeclared variables

* Correct rotation direction for normal-to-Y faces

* Remove X oriented 180 degree rotation adjustment

Probable error in FreeCAD gcode renderer, producing incorrect B axis rotation

* Update 4th-axis integration

Address FC error with B axis rotation rendering: user input to override error for visual alignment with model.
Correct pocket depths with Final Depth input enforced.
Add Reverse Direction flag input for reversing direction of pocket: necessary in some use cases.
NOTE: 4th-axis throws errors with Extension Corners feature.  EC feature needs 4th-axis rotation integration when calculating extensions for a particular part feature/face.
General testing needed.

* PathSurface: Add StepDown support

Add StepDown support for PathSurface operation.
A low-level optimization algorithm is included.

* Update PageOpSurfaceEdit.ui

* PathSurface: Activate CompletionMode input

Update code to use CompletionMode selection from user.

* PathSurfaceGui: Add Completion Mode selection box

Add Completion Mode selection box for user input.

* PathSurface: Use depth_params() for step control

Implemented PathUtils.depth_params() for control of step downs to maintain consistency throughout PathWB.
Suggested by Sliptonic.

* PathSurface: Improve stability - Rev3

Organized code better, improved path optimization algorithm

* PathSurface: Add XY rotational surfacing

Add options to perform 3D surfacing by rotating object around X or Y axis.

* PathSurface: update setup function

Add properties to setup function

* PathSurface: Remove extraneous code

removed commented lines that consume processing time

* PathSurface: Correct nxt.z point assignment

Corrected error in nxt.z value assignment. Was assigning value to pnt.z instead of nxt.z

* PathSurface: Update 4th axis operation

Provided both parallel and perpendicular to axis  scans when performing rotational operation.

* PathSurface: Corrected Y-axis rotation to gcode

Inverted Y-axis scan values in gcode to produce correct result

* PathSurface: Adjust gcode feed rates

Adjust feed rates for axial rotations

* PathSurface: Implement waterline alternative

Used OCL dropcutter scan as data base for python algorithm to extract a waterline.  Waterline also incorporates step down feature.

* PathSurface: Update to 3m-Usable

stability improvements
fixed step on multi-pass 4th axis scans
initiate code to accommodate cut modes: zigzag, line
initiate code to accommodate offset cutter on 4th axis scans to simulate a tilted cutter for ball end mills

* PathSurface: Update 3m-Usable_r1

change instantiated static class attributes from value None, to 0.0

* PathSurface: Revert to 3i-Usable_r1

Further testing needed for 3m-Usable release

* PathSurface: Update to Rev. 3s Usable

fixed step over in rotational scans
start/stop indexes
tilt cutter adaptation for ball end mill
cut pattern: zigzag, line partially implemented
ignore waste option initiated for planar scans
cut mode partially implemented: conventional & climb

* PathSurface: Update to Rev. 3t Usable

Corrected rotational errors
corrected cutter tilt rotation
added "ignore waste" feature for planar surface operation

* Implement 4th-axis feature

Implement 4th-axis feature:
add gcode commands for rotation
re-compute operation heights, to consider rotation radii

* Deleted reference to undeclared variable

* Added missing class attributes/variables

* Added missing class variables/attributes

* Relocate class variables to higher class

* Remove references to undeclared variables

relocated class variables here
delete references to undeclared variables

* Remove X oriented 180 degree rotation adjustment

Probable error in FreeCAD gcode renderer, producing incorrect B axis rotation

* Correct rotation direction for normal-to-Y faces

* Update 4th-axis integration

Address FC error with B axis rotation rendering: user input to override error for visual alignment with model.
Correct pocket depths with Final Depth input enforced.
Add Reverse Direction flag input for reversing direction of pocket: necessary in some use cases.
NOTE: 4th-axis throws errors with Extension Corners feature.  EC feature needs 4th-axis rotation integration when calculating extensions for a particular part feature/face.
General testing needed.

* Apply XYZ Model translations to paths; Add rotation axis selection property

* Spelling correction

ln 110

* Geometry list box: shrink height

560 to 400 height

* Update 4th-axis integration

Clean up code
Add comments for visionary elements
Apply axis selection to opHeights rotational calculations

* Update 4th-axis integration

Prepare sorting of vertical faces per axis_angle grouping, just as horizontal faces are sorted, for analysis as connected shapes

* Reset to FreeCAD master current

* Reset to current FreeCAD master version

* Update PathPocketBase.py

* Reset to current FreeCAD master

* Corrected __created__ date

* Convert all print() to PathLog.debug()

* Convert print() to PathLog.debug(); Clean up code

Use PathLog.debug over print() for troubleshooting
Clean up large commented sections of code.

* Convert print() to PathLog.debug(); combine duplicate methods

* Update last modified stamp

* Update last mofified timestamp

Also, removed commented-out code

* Typo corrected: "selt." to "self."

Discovered in https://api.travis-ci.org/v3/job/526456071/log.txt
on 30 April 2019 while searching for errors related to failure of PR #2114

* Restore initialization of self.depthparams

PR is failing Travis CI build test. Previous deletion of this code appears to be the reason.
See report at: https://api.travis-ci.org/v3/job/526492709/log.txt

* Convert tuple sizes from other PathWB ops

* B-axis rotation: render correction

* Revert "rebase to FC master 2019-05-02"

* Correct depthparams opOnDocumentRestored() issue

* Relocate "UseRotation" property from PathAreaOp.py

* Improve meshFromShape() calculation per @sliptonic

faster mesh creation
helps smooth jagged lines in path results

* Part: Make 3rd party libraries into PCH

* PartDesign: 3rdParty to PCH

* Sketcher: PCH

* PartDesign: PCH GUI

* Sketcher: GUI PCH

* Travis windows build (#2110)

Travis windows build

* Travis: enable clcache debug

* disable travis clcache debug

* respect user settings for dialog used in merge-document command

* msbuild verbose and logo

* Travis force wait 60 minutes

* Travis: Use & between vars sourcing and msbuild

* Travis: Move building to external batch script (#2131)

* Travis: Move building to external batch script

* Travis: double quotes to escape route

* Travis: use cmd.exe to call batch file

* Crowdin: fix grammatical error + whitespace 

https://crowdin.com/translate/freecad/569/en-fi#6498705

* Crowdin: experiment to fix crowdin 'ghost' strings

The following translation strings still perpetuate after updating crowdin translations. This commit experiments with removing their source counterparts in the FC .ts files. I'm not sure why they are not rendered obsolete by the normal operations. 
  
* https://crowdin.com/translate/freecad/6766/en-en#6499472  
* https://crowdin.com/translate/freecad/6766/en-en#6573450

* fix for edit tracker draw styles

* deleted commented code

* Travis: filter out

* AddonManager: allow to add custom repositories

* Revert "rebase to FC master 2019-05-02"

* Draft: Fixed Draft text justification

* Arch: Fixed bug in arch windows creation

* Arch: Fixed export of windows colors to IFC

* Draft: Fixed 0.18.1 bug in DXF importer

* Arch: Fixed wrong exported objects in IFC export

* Arch: Fixed export of sites to IFC

* Start: Fixed bad default icon in start page

* Correct depthparams opOnDocumentRestored() issue

* Relocate "UseRotation" property from PathAreaOp.py

* Improve meshFromShape() calculation per @sliptonic

faster mesh creation
helps smooth jagged lines in path results

* Relocate "UseRotation" property in PathAreaOp.py

* Syntax correction

Travis CI python 3.7 build test fails regularly due to syntax error at this point

* Correct rebase issue: PR #2114

* Correct rebase issue: PR #2114

* Correct rebase issue: PR #2114

* Correct rebase issue: PR #2114

* Correct rebase issue: PR #2114

* Correct rebase issue: PR #2114

* path pep8 cleanup

* Multi-face geometry selection repaired

Previous version broke ability to select process multiple faces selected by user in geometry tab in operation task window.
Also performed some syntax cleaning per PEP8 linter

* Update script version info
2019-05-06 21:29:08 -05:00
Mikael Lindqvist
2d2b5f3e19 When using fcbt.py to generate a python module, use FreeCAD.getUserAppDataDir() rather than FreeCAD.getHomeDir() to specify the module icon 2019-05-06 10:26:10 -03:00
luz.paz
fa1a429367 src/Tools/updatets.py: modernization tweeks
Made CLI output more user-friendly especially since we're transitioning to py3/qt5 and the translation tools have different standards (minor changes).  
+ added Changelog
+ bumped version and added authors
2019-05-06 10:21:58 -03:00
Yorik van Havre
8f58abfd49 Tools: Updated wiki download scripts 2019-03-06 17:11:00 -03:00
Yorik van Havre
ad28ba5095 Tools: Fixed bug in FreeCAD.ts generation 2019-03-02 19:32:10 -03:00
Yorik van Havre
4a5cf9c52f Tools: Updated translation scripts to handle only the master (untranslated) ts files 2019-02-08 19:15:56 -02:00
Yorik van Havre
b2619e7eb7 Tools: Discard obsolete strings in translation files 2019-02-08 18:32:10 -02:00
luz.paz
4cfda0c3a5 Misc. typos
Found via `codespell`
2019-02-08 11:01:24 -02:00
Yorik van Havre
27885764c5 Tools: Use downloaded zip file from crowdin without arguments 2019-02-01 13:53:38 -02:00
Yorik van Havre
a32d938962 Re-added linux thumbnailer utility that had been washed out together with debian folder 2019-01-12 13:27:31 -02:00
cclauss
c701531069 flake8 noqa a Python 3 syntax error 2019-01-09 10:31:27 +01:00
cclauss
59731e95a8 Undefined name: to --> 'to' (again)
Just like #1884 but on a different file.
```
./src/Tools/FCFileTools.py:47:50: F821 undefined name 'to'
                print('Error copying', pathFrom, to, pathTo, '--skipped')
                                                 ^
./src/Tools/FCFileTools.py:86:54: F821 undefined name 'to'
                    print('Error copying', pathFrom, to, pathTo, '--skipped')
                                                     ^
```
2019-01-08 11:57:18 -02:00
cclauss
a7c0f4bc5b Drop depencence on six module 2019-01-07 15:51:34 +01:00
cclauss
51ab27f54a Fix file, long, raw_input, and xrange for Python 3 2019-01-07 15:42:37 +01:00