Commit Graph

122 Commits

Author SHA1 Message Date
carlopav
05c250d7b5 Arch: fix regression in SectionPlane 2020-05-18 12:18:36 +02:00
luz.paz
8fb5c65736 Arch: [skip ci] fix header uniformity
This PR fixes header uniformity across all Arch files
2019-12-26 18:24:06 +01:00
Zheng, Lei
a3e88a399f Arch: relax Part::Feature type checking
For supporting Link inside Arch.
2019-11-17 13:03:42 -03:00
luz.paz
95af9ed202 Arch: ArchSectionPlane.py LGTM incorrect variable fix [skip ci]
LGTM reported `For loop variable 'objs' is not used in the loop body.`
2019-10-25 10:23:24 -03:00
carlopav
1d0bf0e5bc [Arch] Add Section plane context menu for CutView
Added Section plane context menu to toggle cutview property
2019-10-17 17:37:59 -03:00
Yorik van Havre
cf9bbe14fb Arch: small bugfix 2019-09-03 19:58:38 -03:00
luz.paz
f22ae848ea Fix misc. typos, whitespace, and http:// to https:// issues 2019-09-03 11:11:43 -03:00
Yorik van Havre
ed0eff0248 TechDraw/Arch: Added new Coin Mono rendering mode to TD ArchViews 2019-08-24 19:41:57 -03:00
Yorik van Havre
93b5481c68 Arch: Optimization in SVG generation code 2019-08-21 19:56:25 -03:00
Yorik van Havre
f93a986b5a Arch/TD: Added Coin mode to TD arch views 2019-08-21 18:44:02 -03:00
Yorik van Havre
c168a7d14b Arch/TD: Support for Arch BuildingParts in TD ArchView 2019-08-16 19:03:49 -03:00
furti
ce943982ec Arch: Fix missing cache value for SectionPlane
When the Arch SectionPlane was rendered via TechDraw in Solid mode, the
last parameter "fillSpaces" was not set for the svgcache.
So the next render operation threw an exeption because there where only
4 instead of 5 elements in the cache list.
2019-08-14 14:43:13 -03:00
Yorik van Havre
3c68d1e0c3 Arch: Fixed some flat objects not appearing in techdraw 2019-05-13 13:10:36 -03:00
Yorik van Havre
8b4d6c0e64 Arch: Better behaviour and tooltips on section plane task panel buttons - fixes #3643 2019-05-09 11:42:22 -03:00
Yorik van Havre
9a64f3fad9 Arch: Added 'Clip' property to section planes to clip the rendered contents to the plane limits 2019-04-28 17:29:19 -03:00
Yorik van Havre
ea0c7694cd Arch/TechDraw: TD Arch views now have a 'fillSpaces' property to show Arch spaces as color-filled areas 2019-04-19 18:20:33 -03:00
furti
09731554c2 Add option to fill cut shapes with material colors
Previously when setting the "Show Fill" property of the TechDraw Arch
Section View to true, the areas where always filled with a default grey
color.

This commit adds a property called "UseMaterialColorForFill" to the
ArchSectionPlane. When set to true, it will use the objects material
color to fill the cut shapes and fall back to the default color
when no Material is found.
2019-03-22 10:36:07 -03:00
Yorik van Havre
21dc8c5054 Arch: Fixed remaining encoding problems - issue #3827 2019-02-19 20:03:51 -03:00
furti
27a467a44b Fix missing DWG imports in ArchSectionPlane.getSVG
When a DWG file is imported into FreeCAD it gets imported as a Part
object with a compound shape. One would imagine, that such an object
should be rendered like a symbol inside a TechDraw View. But when the
imported shape is inside a SectionPlane that also contains solids, the
shape is not included in the SVG.

The problem is, that getCutShapes only uses solid shapes, when a volume
was cut before. But the imported DWG is a flat 2D object and has no solids
inside.

To fix it, the getSVG method will check if an object looks like a draft
object, meaning:
 - It has a shape
 - It has no solids
 - It has no volume

When it finds such a shape, it will treat it like a draft object. So
it is displayed like a symbol in the resulting SVG.

https://forum.freecadweb.org/viewtopic.php?f=3&t=34079
2019-02-09 19:53:54 -02:00
furti
cce889b21c Fix missing door symbols in getSVG
The ArchSectionPlane has a built in SVG Cache. But the door symbols and
a few other things are not inside the cache. This things not inside the
cache rely on the presence of a cutface. But this cutface was only built
when the cache is not available.

So the First invocation after the cache was cleared added the symbols.
The next invocations of the method, with a cached SVG did not calculate
the symbols again, because the cutfaces where missing.

This commit fixes it by calculating the cutfaces independent from the
cache.

Reported in https://forum.freecadweb.org/viewtopic.php?f=3&t=33987
2019-02-08 11:05:17 -02:00
Yorik van Havre
b56598428d Arch: Disabled children claiming for Section Planes for now (buggy) 2018-11-08 15:17:22 -02:00
George Shuklin
3391a5ea4b Initial work, only text (no lines) 2018-10-26 19:25:44 -03:00
Yorik van Havre
b11ed19f8d Arch: Make section planes claim their children in the tree 2018-10-25 12:13:16 -03:00
Yorik van Havre
b469c237b5 Arch: cache svg calculations in section planes/techdraw views for better performance 2018-08-28 21:03:25 -03:00
Yorik van Havre
559a5e6e58 Arch: Added placement controls to section plane's task panel 2018-08-28 11:18:35 -03:00
Yorik van Havre
8708da2627 Arch: Section plane is now created at center of selected objects 2018-08-27 22:09:03 -03:00
Yorik van Havre
1885036139 Arch: Added preference option for screen helpers color (axes, grids, etc...) 2018-07-25 10:56:12 -03:00
luz.paz
c0014cbd3e Misc. comment typos
+ Found via `codespell -q 3 --skip="*.po,*.ts,./.git,./src/3rdParty,./src/CXX,./src/zipios++,./src/Mod/Assembly/App/opendcm" -I ~/Projects/fc-word-whitelist.txt`

+ crowdin translation refinements:  
- https://crowdin.com/translate/freecad/6766/en-en#6499546
- https://crowdin.com/translate/freecad/6766/en-en#6504496
2018-06-13 20:37:17 -04:00
Yorik van Havre
e49a5af3ae Arch: separate properties creation in own methods and check properties at file load 2018-06-01 19:36:35 -03:00
Yorik van Havre
ea0df1e212 Arch: Added CutMargin property to section planes 2018-05-14 12:34:14 -03:00
Yorik van Havre
c360263582 Arch/Draft: Make sure an active doc exists before creating objects 2018-05-08 16:07:55 -03:00
Simon
1815a9ef4d Fix wrong variable name symbolLineWidth -> svgSymbolLineWidth. 2017-04-23 19:42:25 -03:00
Simon
e2b5c16c05 ArchSectionPlane: Fix incomplete SVG because of = instead of +=. 2017-04-23 19:42:25 -03:00
Simon
f673658a22 ArchSectionPlane: Remove placeholders in getSVG and more clean up.
getSVG puts placeholders in the generated SVG code and replaces them
afterwards with length values. With the changes of the previous commits
this seems not to be necessary anymore.

I replace them in a separate commit so this change can be reverted easily.
2017-04-23 19:42:25 -03:00
Simon
99247f57d7 ArchSectionPlane: Add properties for the line color and the fill color
* Both properties are automatically added to old section planes
  with the help of onDocumentRestored.
* A bit of style clean up to improve the readability of touched code lines.
2017-04-23 19:42:25 -03:00
Simon
9633c94515 ProjectionAlgos: Make the style of the lines in the SVG file configurable.
* getSVG provides new style parameters for every kind of line:
  V, V0, V1, H, H0, H1.
* Old line width parameters are removed. The style parameters
  can be used instead.
* A style is a map container for svg attribute keys and values
  (string, string).
* The Python interface is updated to offer the new style parameters
  accordingly as a dict.
* Because there are many parameters on the function call now,
  the Python interface supports keyword parameters.
* Update ArchSectionPlane to take advantage of the new style parameters.
  This simplifies the code. String replacements could be removed
  (done in a later commit).
* FeatureViewPy.cpp is – to my knowledge – the only function that used the
  old line width parameters. I rewrote it to use the new style parameters.
2017-04-23 19:42:25 -03:00
Yorik van Havre
177c350a16 Arch: misc minor bugfixes 2017-03-08 15:55:07 -03:00
Yorik van Havre
67fdbfdbeb Arch: Fixed bug in Section Plane + TechDraw view when the section is empty 2017-01-19 17:54:58 -02:00
looooo
2bc1162193 py3: Arch: print fixes 2017-01-17 11:13:36 +01:00
Priit Laes
1591601654 py3: Arch: *.py: Fix syntax for python3 2017-01-17 09:24:46 +01:00
wmayer
d9b1ce7ca2 remove UnicodeUTF8 2016-12-27 19:31:25 +01:00
Yorik van Havre
223dd70b99 Arch: Small fix in section plane's Drawing view object 2016-12-10 11:23:04 -02:00
Yorik van Havre
af97583026 Doc: Fixes in doxygen docs for Draft,Arch, FEM 2016-11-17 17:04:09 -02:00
Yorik van Havre
945d99f982 Draft: implemented dxf export of techdraw pages 2016-11-05 15:13:48 -02:00
Yorik van Havre
c465ca261c Arch: Added preference setting to control linewidth of Draft objects seen by Arch Section Planes 2016-11-03 16:40:12 -02:00
Yorik van Havre
6951705835 Arch: Support for opening symbols - fixes #2353 2016-11-02 20:10:20 -02:00
Yorik van Havre
e2e73af4ac TechDraw: Fixed solid rendering of Arch Views 2016-11-02 13:14:31 -02:00
Yorik van Havre
195ea429e6 Arch: fixed rotation of space labels in techdraw 2016-11-01 18:53:48 -02:00
Yorik van Havre
4ee8a2a53d Arch: Section planes can now also include Draft stuff (dimensions, etc) 2016-10-31 11:10:08 -02:00
Yorik van Havre
801f36cc39 Arch: cosmetic fixes in task panels 2016-10-28 17:14:41 -02:00