Draft/Arch: Used new PropertyVectorDistance where needed

This commit is contained in:
Yorik van Havre 2015-09-01 10:47:25 -03:00
parent 4daf44b925
commit 2aff34eab8
3 changed files with 26 additions and 26 deletions

View File

@ -83,7 +83,7 @@ class _Frame(ArchComponent.Component):
ArchComponent.Component.__init__(self,obj)
obj.addProperty("App::PropertyLink","Profile","Arch","The profile used to build this frame")
obj.addProperty("App::PropertyBool","Align","Arch","Specifies if the profile must be aligned with the extrusion wires")
obj.addProperty("App::PropertyVector","Offset","Arch","An offset vector between the base sketch and the frame")
obj.addProperty("App::PropertyVectorDistance","Offset","Arch","An offset vector between the base sketch and the frame")
obj.addProperty("App::PropertyInteger","BasePoint","Arch","Crossing point of the path on the profile.")
obj.addProperty("App::PropertyAngle","Rotation","Arch","The rotation of the profile around its extrusion axis")
self.Type = "Frame"

View File

@ -357,16 +357,16 @@ class _ViewProviderSpace(ArchComponent.ViewProviderComponent):
vobj.LineWidth = 1
vobj.LineColor = (1.0,0.0,0.0,1.0)
vobj.DrawStyle = "Dotted"
vobj.addProperty("App::PropertyStringList", "Text", "Arch",translate("Arch","The text to show. Use $area, $label, $tag, $floor, $walls, $ceiling to insert the respective data"))
vobj.addProperty("App::PropertyString", "FontName", "Arch",translate("Arch","The name of the font"))
vobj.addProperty("App::PropertyColor", "TextColor", "Arch",translate("Arch","The color of the area text"))
vobj.addProperty("App::PropertyLength", "FontSize", "Arch",translate("Arch","The size of the text font"))
vobj.addProperty("App::PropertyLength", "FirstLine", "Arch",translate("Arch","The size of the first line of text"))
vobj.addProperty("App::PropertyFloat", "LineSpacing", "Arch",translate("Arch","The space between the lines of text"))
vobj.addProperty("App::PropertyVector", "TextPosition","Arch",translate("Arch","The position of the text. Leave (0,0,0) for automatic position"))
vobj.addProperty("App::PropertyEnumeration","TextAlign", "Arch",translate("Arch","The justification of the text"))
vobj.addProperty("App::PropertyInteger", "Decimals", "Arch",translate("Arch","The number of decimals to use for calculated texts"))
vobj.addProperty("App::PropertyBool", "ShowUnit", "Arch",translate("Arch","Show the unit suffix"))
vobj.addProperty("App::PropertyStringList", "Text", "Arch",translate("Arch","The text to show. Use $area, $label, $tag, $floor, $walls, $ceiling to insert the respective data"))
vobj.addProperty("App::PropertyString", "FontName", "Arch",translate("Arch","The name of the font"))
vobj.addProperty("App::PropertyColor", "TextColor", "Arch",translate("Arch","The color of the area text"))
vobj.addProperty("App::PropertyLength", "FontSize", "Arch",translate("Arch","The size of the text font"))
vobj.addProperty("App::PropertyLength", "FirstLine", "Arch",translate("Arch","The size of the first line of text"))
vobj.addProperty("App::PropertyFloat", "LineSpacing", "Arch",translate("Arch","The space between the lines of text"))
vobj.addProperty("App::PropertyVectorDistance","TextPosition","Arch",translate("Arch","The position of the text. Leave (0,0,0) for automatic position"))
vobj.addProperty("App::PropertyEnumeration", "TextAlign", "Arch",translate("Arch","The justification of the text"))
vobj.addProperty("App::PropertyInteger", "Decimals", "Arch",translate("Arch","The number of decimals to use for calculated texts"))
vobj.addProperty("App::PropertyBool", "ShowUnit", "Arch",translate("Arch","Show the unit suffix"))
vobj.TextColor = (0.0,0.0,0.0,1.0)
vobj.Text = ["$label","$area"]
vobj.TextAlign = ["Left","Center","Right"]

View File

@ -3287,11 +3287,11 @@ class _Dimension(_DraftObject):
"The Draft Dimension object"
def __init__(self, obj):
_DraftObject.__init__(self,obj,"Dimension")
obj.addProperty("App::PropertyVector","Start","Draft","Startpoint of dimension")
obj.addProperty("App::PropertyVector","End","Draft","Endpoint of dimension")
obj.addProperty("App::PropertyVectorDistance","Start","Draft","Startpoint of dimension")
obj.addProperty("App::PropertyVectorDistance","End","Draft","Endpoint of dimension")
obj.addProperty("App::PropertyVector","Normal","Draft","the normal direction of this dimension")
obj.addProperty("App::PropertyVector","Direction","Draft","the normal direction of this dimension")
obj.addProperty("App::PropertyVector","Dimline","Draft","Point through which the dimension line passes")
obj.addProperty("App::PropertyVectorDistance","Dimline","Draft","Point through which the dimension line passes")
obj.addProperty("App::PropertyLink","Support","Draft","The object measured by this dimension")
obj.addProperty("App::PropertyLinkSubList","LinkedGeometry","Draft","The geometry this dimension is linked to")
obj.addProperty("App::PropertyLength","Distance","Draft","The measurement of this dimension")
@ -3349,7 +3349,7 @@ class _ViewProviderDimension(_ViewProviderDraft):
obj.addProperty("App::PropertyDistance","ExtLines","Draft","Length of the extension lines")
obj.addProperty("App::PropertyBool","FlipArrows","Draft","Rotate the dimension arrows 180 degrees")
obj.addProperty("App::PropertyBool","ShowUnit","Draft","Show the unit suffix")
obj.addProperty("App::PropertyVector","TextPosition","Draft","The position of the text. Leave (0,0,0) for automatic position")
obj.addProperty("App::PropertyVectorDistance","TextPosition","Draft","The position of the text. Leave (0,0,0) for automatic position")
obj.addProperty("App::PropertyString","Override","Draft","Text override. Use $dim to insert the dimension length")
obj.FontSize = getParam("textheight",0.20)
obj.TextSpacing = getParam("dimspacing",0.05)
@ -3683,8 +3683,8 @@ class _AngularDimension(_DraftObject):
_DraftObject.__init__(self,obj,"AngularDimension")
obj.addProperty("App::PropertyAngle","FirstAngle","Draft","Start angle of the dimension")
obj.addProperty("App::PropertyAngle","LastAngle","Draft","End angle of the dimension")
obj.addProperty("App::PropertyVector","Dimline","Draft","Point through which the dimension line passes")
obj.addProperty("App::PropertyVector","Center","Draft","The center point of this dimension")
obj.addProperty("App::PropertyVectorDistance","Dimline","Draft","Point through which the dimension line passes")
obj.addProperty("App::PropertyVectorDistance","Center","Draft","The center point of this dimension")
obj.addProperty("App::PropertyVector","Normal","Draft","The normal direction of this dimension")
obj.addProperty("App::PropertyLink","Support","Draft","The object measured by this dimension")
obj.addProperty("App::PropertyLinkSubList","LinkedGeometry","Draft","The geometry this dimension is linked to")
@ -3719,7 +3719,7 @@ class _ViewProviderAngularDimension(_ViewProviderDraft):
obj.addProperty("App::PropertyColor","LineColor","Draft","Line color")
obj.addProperty("App::PropertyBool","FlipArrows","Draft","Rotate the dimension arrows 180 degrees")
obj.addProperty("App::PropertyBool","ShowUnit","Draft","Show the unit suffix")
obj.addProperty("App::PropertyVector","TextPosition","Draft","The position of the text. Leave (0,0,0) for automatic position")
obj.addProperty("App::PropertyVectorDistance","TextPosition","Draft","The position of the text. Leave (0,0,0) for automatic position")
obj.addProperty("App::PropertyString","Override","Draft","Text override. Use 'dim' to insert the dimension length")
obj.FontSize = getParam("textheight",0.20)
obj.FontName = getParam("textfont","")
@ -4131,8 +4131,8 @@ class _Wire(_DraftObject):
obj.addProperty("App::PropertyBool","Closed","Draft","If the wire is closed or not")
obj.addProperty("App::PropertyLink","Base","Draft","The base object is the wire is formed from 2 objects")
obj.addProperty("App::PropertyLink","Tool","Draft","The tool object is the wire is formed from 2 objects")
obj.addProperty("App::PropertyVector","Start","Draft","The start point of this line")
obj.addProperty("App::PropertyVector","End","Draft","The end point of this line")
obj.addProperty("App::PropertyVectorDistance","Start","Draft","The start point of this line")
obj.addProperty("App::PropertyVectorDistance","End","Draft","The end point of this line")
obj.addProperty("App::PropertyLength","Length","Draft","The length of this line")
obj.addProperty("App::PropertyLength","FilletRadius","Draft","Radius to use to fillet the corners")
obj.addProperty("App::PropertyLength","ChamferSize","Draft","Size of the chamfer to give to the corners")
@ -4739,11 +4739,11 @@ class _Array(_DraftObject):
obj.addProperty("App::PropertyInteger","NumberY","Draft","Number of copies in Y direction")
obj.addProperty("App::PropertyInteger","NumberZ","Draft","Number of copies in Z direction")
obj.addProperty("App::PropertyInteger","NumberPolar","Draft","Number of copies")
obj.addProperty("App::PropertyVector","IntervalX","Draft","Distance and orientation of intervals in X direction")
obj.addProperty("App::PropertyVector","IntervalY","Draft","Distance and orientation of intervals in Y direction")
obj.addProperty("App::PropertyVector","IntervalZ","Draft","Distance and orientation of intervals in Z direction")
obj.addProperty("App::PropertyVector","IntervalAxis","Draft","Distance and orientation of intervals in Axis direction")
obj.addProperty("App::PropertyVector","Center","Draft","Center point")
obj.addProperty("App::PropertyVectorDistance","IntervalX","Draft","Distance and orientation of intervals in X direction")
obj.addProperty("App::PropertyVectorDistance","IntervalY","Draft","Distance and orientation of intervals in Y direction")
obj.addProperty("App::PropertyVectorDistance","IntervalZ","Draft","Distance and orientation of intervals in Z direction")
obj.addProperty("App::PropertyVectorDistance","IntervalAxis","Draft","Distance and orientation of intervals in Axis direction")
obj.addProperty("App::PropertyVectorDistance","Center","Draft","Center point")
obj.addProperty("App::PropertyAngle","Angle","Draft","Angle to cover with copies")
obj.addProperty("App::PropertyBool","Fuse","Draft","Specifies if copies must be fused (slower)")
obj.ArrayType = ['ortho','polar']
@ -4838,7 +4838,7 @@ class _PathArray(_DraftObject):
obj.addProperty("App::PropertyLink","PathObj","Draft","The path object along which to distribute objects")
obj.addProperty("App::PropertyLinkSubList","PathSubs","Draft","Selected subobjects (edges) of PathObj")
obj.addProperty("App::PropertyInteger","Count","Draft","Number of copies")
obj.addProperty("App::PropertyVector","Xlate","Draft","Optional translation vector")
obj.addProperty("App::PropertyVectorDistance","Xlate","Draft","Optional translation vector")
obj.addProperty("App::PropertyBool","Align","Draft","Orientation of Base along path")
obj.Count = 2
obj.PathSubs = []