Commit Graph

2861 Commits

Author SHA1 Message Date
Yorik van Havre
19feabd072 Merged crowdin translations 2022-03-31 11:41:28 +02:00
Yorik van Havre
d1c88b2486 Merge pull request #6676 from marioalexis84/draft-python2
Draft: Remove Python 2 type support
2022-03-31 11:10:07 +02:00
Yorik van Havre
b633b5636a Updated ts files 2022-03-31 11:02:28 +02:00
Chris Hennes
f442b7d36d Draft: PR6497 move return statement to new line 2022-03-29 12:35:46 -05:00
marioalexis
79b7bfd5d0 Draft: Remove Python 2 type support 2022-03-28 18:02:23 -03:00
Chris Hennes
22bfecf4bd Draft: PR4556 Step 3: sort QGridLayout by row-col 2022-03-28 10:43:21 -05:00
Chris Hennes
96339a252f Draft: PR4556 Step 2: remove native=true 2022-03-28 10:43:21 -05:00
wmayer
6ca12d31b3 Draft: include header with export macros 2022-03-24 20:48:41 +01:00
wmayer
d21a60b294 All: modernize C++11
* replace deprecated headers
2022-03-23 22:44:18 +01:00
wmayer
1b9f30fe76 Draft: modernize C++11
* use nullptr
2022-03-23 19:26:15 +01:00
Yorik van Havre
2a833b46c8 Merge branch 'master' of github.com:FreeCAD/FreeCAD 2022-03-23 10:51:15 +01:00
Yorik van Havre
1563822763 Translations: Merged crowdin strings 2022-03-23 10:37:50 +01:00
Yorik van Havre
3e86aaa3ab Merge pull request #6619 from matthijskooijman/draft-misc-fixes
Draft: Misc fixes
2022-03-23 10:30:12 +01:00
Yorik van Havre
d12a201d89 Translations: updated ts files 2022-03-23 10:24:55 +01:00
Matthijs Kooijman
b7c94992c9 Draft: Simplify using getattr instead of hasattr
Using the default argument supported by getattr makes this code a bit
simpler and probably (ever so slightly) faster.

See https://forum.freecadweb.org/viewtopic.php?f=10&t=58611 for previous
discussion.

This is not an exhaustive change, these are just a few I encounted while
working with the code.
2022-03-22 14:46:50 +01:00
Matthijs Kooijman
52e7dafedb Draft: Fix mixup of TextAlignment vs Justification for Labels
TextAlignment is the vertical alignment, while Justification is the
horizontal alignment. here, get_text was passed the vertical, while it
expected the horizontal. This caused the alignment of a Label to be
wrong in the resulting SVG (e.g. in a TechDraw draft view).

This seems to have been broken since SVG support for Labels was first
introduced in commit d6f8ded4ca (Initial work, only text (no lines)).
2022-03-22 14:46:50 +01:00
Matthijs Kooijman
f62d0c4637 Draft: Fix SVG generation for label objects
Label objects would produce invalid SVG XML, because the stroke-linecap
property was added as if it was a style (with : and ;), but it was
inserted in the XML tag directly, rather than inside the style attribute
value. The invalid SVG prevented for example a TechDraw draft view from
rendering when it contained a label.

This was added in commit 6a7912d399 (Draft: Using square endcaps for
lines in SVG output).

This stroke-linecap is supported both as a presentation attribute inside
the style or a XML attribute, so for consistency with the surrounding
attributes, it is made a normal attribute, rather than putting it inside
the style.

See also https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/stroke-linecap
2022-03-22 14:38:36 +01:00
Yorik van Havre
a8420f918b Draft: Restored cloning of arch objects 2022-03-21 15:16:53 +01:00
Matthijs Kooijman
2f05f86f6c Draft: Fix incorrect use of in operator
Looking at the surrounding code, this should be `==` rather than `in`.
The code does work as intended, because a string is always a substring
of itself, but better to fix it anyway.

Seems this was broken since this code was first introduced in commit
193339991f (Draft: clean up ViewProviderLabel class)
2022-03-20 14:45:52 +01:00
wmayer
e28f2a0c47 Qt: remove some more leftovers of Qt4 2022-03-19 23:27:28 +01:00
andrea reale
83d3a916c0 remove QT4 references 2022-03-19 23:07:38 +01:00
Yorik van Havre
74016d1f74 Merge pull request #6544 from Roy-043/Draft-Fix-Angle-Lock-for-non-XY-workingplane
Draft: Fix Angle Lock for non-XY workingplane
2022-03-17 15:46:52 +01:00
flachyjoe
cf9485f191 Don't take grid into account when View_FitAll 2022-03-16 17:30:25 +01:00
Yorik van Havre
a55ee61840 Merged crowdin translations 2022-03-14 12:21:01 +01:00
Yorik van Havre
cfdd2af62d Updated master ts files 2022-03-14 12:13:40 +01:00
wmayer
0f9768fb33 Fix coverity issue:
* CID 332682: Resource leak
* CID 350607: Resource leak
* CID 332677: Resource leak
2022-03-14 11:35:04 +01:00
Civil Guy
3c2c38fd1a Minor spelling fixes 2022-03-11 13:57:03 +01:00
Roy-043
b830f77215 Draft: Fix Angle Lock for non-XY workingplane 2022-03-10 17:44:38 +01:00
Yorik van Havre
419594a5dc Draft: Fixed error in SVG rendering of LinkedArrays - fixes #6516 2022-03-10 13:34:18 +01:00
Yorik van Havre
2cff977548 Merged crowdin translations 2022-03-07 14:55:22 +01:00
Yorik van Havre
6b71ce3a3e Updated master translation files 2022-03-07 14:49:13 +01:00
wmayer
4b415d1b37 Mod: add string header to dxf.h 2022-03-01 15:13:34 +01:00
wmayer
6ae3feedae Draft, Import, area: include iosfwd instead of iostream if forward declarations are sufficient 2022-03-01 12:37:00 +01:00
Roy-043
6a1d81f62b Draft: Fix Draft_Line Length is zero bug
When changing the Length of a Draft_Line to f.e. 0.5 the input of the zero resulted in a zero length line.
2022-02-24 12:26:42 +01:00
Yorik van Havre
07783e463d Merge pull request #6406 from marioalexis84/draft-drawing_techdraw
Draft: Replace Drawing functions with TechDraw functions
2022-02-21 11:10:36 +01:00
Roy
84b3003e8e Draft: Housekeeping: call 'make' functions with new name (4) 2022-02-20 22:31:08 -06:00
marioalexis
b4c20bce20 Draft: Replace Drawing functions with TechDraw functions 2022-02-20 16:34:29 -03:00
Yorik van Havre
a242ae0f52 Merge pull request #6355 from Roy-043/Draft-Housekeeping-call-'make'-functions-with-new-name-(3)
Draft: Housekeeping: call 'make' functions with new name (3)
2022-02-17 11:40:59 +01:00
wmayer
0208608b9e Base: fix Matrix4D::hasScale
* If all column vectors of the 3x3 sub-matrix are equal the function incorrectly claims that it's uniform scaling.
* Detect also non-uniform scaling and if was applied from the left or right side
* Replace the int with an enum and expose it to Python
* Add several new unit tests
2022-02-15 21:05:11 +01:00
Yorik van Havre
e1028eb65e Merged crowdin translations 2022-02-14 12:31:57 +01:00
Yorik van Havre
93fc8c5357 Updated ts files 2022-02-14 12:31:47 +01:00
Roy
1566c00d35 Draft: Housekeeping: call 'make' functions with new name (3) 2022-02-13 11:01:15 +01:00
Roy
acfdfb9c2d Draft: Housekeeping: call 'make' functions with new name, continued 2022-02-12 19:34:57 +01:00
wmayer
29b940fb66 Part: Circle variable name change to create consistency
Change variable names of the Circle from Angle0 to Angle1 to create consistency with all other named angle variables
2022-02-11 18:28:58 +01:00
Yorik van Havre
9e9790f1b1 Merge pull request #6337 from Roy-043/Draft-Housekeeping-call-'make'-functions-with-new-name
Draft: Housekeeping: call 'make' functions with new name
2022-02-11 12:00:23 +01:00
Yorik van Havre
c79c2d95fd Merge pull request #5496 from Roy-043/Draft-fix-isClosed-bug-in-offsets.py
Draft: fix isClosed bug in offsets.py
2022-02-11 11:42:11 +01:00
Roy
f59011bfea Draft: Housekeeping: call 'make' functions with new name 2022-02-10 16:44:37 +01:00
marioalexis
e83972f990 Draft: Fix SoSeparator not deleted 2022-02-09 19:07:10 -03:00
Roy
aa3aaaefc6 Fixed an error in the connect function. Point v2 could be undefined. 2022-02-09 22:06:36 +01:00
Roy-043
f338d2abcb Draft: fix isClosed bug in offsets.py
Use built-in isClosed() function instead of isReallyClosed which is buggy.
2022-02-04 15:03:04 +01:00