Arch/TechDraw: TD Arch views now have a 'fillSpaces' property to show Arch spaces as color-filled areas

This commit is contained in:
Yorik van Havre
2019-04-19 18:20:33 -03:00
parent 9d296194e8
commit ea0c7694cd
5 changed files with 46 additions and 24 deletions

View File

@@ -59,6 +59,7 @@ DrawViewArch::DrawViewArch(void)
ADD_PROPERTY_TYPE(AllOn ,(false),group,App::Prop_None,"If hidden objects must be shown or not");
RenderMode.setEnums(RenderModeEnums);
ADD_PROPERTY_TYPE(RenderMode, ((long)0),group,App::Prop_None,"The render mode to use");
ADD_PROPERTY_TYPE(FillSpaces ,(false),group,App::Prop_None,"If True, Arch Spaces are shown as a colored area");
ADD_PROPERTY_TYPE(ShowHidden ,(false),group,App::Prop_None,"If the hidden geometry behind the section plane is shown or not");
ADD_PROPERTY_TYPE(ShowFill ,(false),group,App::Prop_None,"If cut areas must be filled with a hatch pattern or not");
ADD_PROPERTY_TYPE(LineWidth,(0.35),group,App::Prop_None,"Line width of this view");
@@ -113,7 +114,8 @@ App::DocumentObjectExecReturn *DrawViewArch::execute(void)
<< ",linewidth=" << LineWidth.getValue()
<< ",fontsize=" << FontSize.getValue()
<< ",techdraw=True"
<< ",rotation=" << Rotation.getValue();
<< ",rotation=" << Rotation.getValue()
<< ",fillSpaces=" << (FillSpaces.getValue() ? "True" : "False");
Base::Interpreter().runString("import ArchSectionPlane");
Base::Interpreter().runStringArg("svgBody = ArchSectionPlane.getSVG(App.activeDocument().%s %s)",

View File

@@ -45,6 +45,7 @@ public:
App::PropertyLink Source;
App::PropertyBool AllOn;
App::PropertyEnumeration RenderMode; // "Wireframe","Solid"
App::PropertyBool FillSpaces;
App::PropertyBool ShowHidden;
App::PropertyBool ShowFill;
App::PropertyFloat LineWidth;