All Frameworks Object Hierarchy This Framework Indexes
Example : Product0 Part1 Part3 Part2In this sample, product0 and Part1 are nodes and Part3 and Part2 are leaves.
Example with the color property: ( color inheritance flag, color) Product0 (1,red) Part1 (0,blue) Part3 (1,green) Part2 (0,Yellow)In this sample the real colord of the product0 is red, blue for the part1, green for the part3 and yellow for the part2. But the visible color of each element is red, because the product0 gives the red color at all the tree.
o Func GetLayer( | oLayerType, | |
oLayerValue) As |
Dim layer layer = CLng(0) Dim layertype As CatVisLayerType Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetLayer layertype, layer If (layertype = catVisLayerNone) Then MsgBox "Layer None" End If If (layertype = catVisLayerBasic) Then MsgBox "layer =" & layer End If
o Func GetPick( | oPick) As |
Dim pickstate As CatVisPropertyPick Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetPick pickstate MsgBox "pick = " & pickstate
o Func GetRealColor( | oRed, | |
oGreen, | ||
oBlue) As |
Dim r, g, b r = CLng(0) g = CLng(0) b = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetRealColor r, g, b MsgBox "r = " & r & " g = " & g & " b = " & b
o Func GetRealInheritance( | iPropertyType, | |
oInheritance) As |
Dim inhLineType, inhWidth, inhColor, inhOpacity inhLineType = CLng(0) inhWidth = CLng(0) inhColor = CLng(0) inhOpacity = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetRealInheritance catVisPropertyLineType, inhLineType visProperties1.GetRealInheritance catVisPropertyWidth, inhWidth visProperties1.GetRealInheritance catVisPropertyColor, inhColor visProperties1.GetRealInheritance catVisPropertyOpacity, inhOpacity MsgBox "Inheritance : linetype = " & inhLineType & "width =" & inhWidth & "Colour =" & inhColor & "Opacity =" & inhOpacity
o Func GetRealLineType( | oLineType) As |
Dim linetype linetype = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetRealLineType linetype MsgBox "linetype = " & linetype
o Func GetRealOpacity( | oOpacity) As |
Dim op op = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetRealOpacity op MsgBox "opacity = " & op
o Func GetRealWidth( | oLineWidth) As |
Dim width width = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetRealWidth width MsgBox "width = " & width
o Func GetShow( | oShow) As |
Dim showstate As CatVisPropertyShow Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetShow showstate MsgBox "show = " & showstate
o Func GetSymbolType( | oSymbolType) As |
Dim symbol symbol = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetSymbolType symbol MsgBox "Symbol = " & symbol
o Func GetVisibleColor( | oRed, | |
oGreen, | ||
oBlue) As |
Dim r, g, b r = CLng(0) g = CLng(0) b = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetVisibleColor r, g, b MsgBox "r = " & r & " g = " & g & " b = " & b
o Func GetVisibleInheritance( | iPropertyType, | |
oInheritance) As |
o Func GetVisibleLineType( | oLineType) As |
Dim linetype linetype = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetVisibleLineType linetype MsgBox "linetype = " & linetype
o Func GetVisibleOpacity( | oOpacity) As |
Dim op op = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetVisibleOpacity op MsgBox "opacity = " & op
o Func GetVisibleWidth( | oLineWidth) As |
Dim width width = CLng(0) Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.GetVisibleWidth width MsgBox "width = " & width
o Sub SetLayer( | iLayerType, | |
iLayerValue) |
Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.SetLayer catVisLayerBasic, 100
o Sub SetPick( | iPick) |
Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.SetPick catVisPropertyNoPickAttr
o Sub SetRealColor( | iRed, | |
iGreen, | ||
iBlue, | ||
iInheritance) |
Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.SetRealColor 255,0,0,1
o Sub SetRealLineType( | iLineType, | |
iInheritance) |
Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.SetRealLineType 4,1
o Sub SetRealOpacity( | iOpacity, | |
iInheritance) |
Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.SetRealOpacity 128,1
o Sub SetRealWidth( | iLineWidth, | |
iInheritance) |
Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.SetRealWidth 4,1
o Sub SetShow( | iShow) |
Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.SetShow catVisPropertyNoShowAttr
o Sub SetSymbolType( | iSymbolType) |
/ | / |/__
___ /| / | /
Set visProperties1 = CATIA.ActiveDocument.Selection.VisProperties visProperties1.SetSymbolType 4
Copyright © 2003, Dassault Systèmes. All rights reserved.