主题
ExtrusionColor (属性)
返回一个 ColorFormat 对象,该对象表示形状延伸区域的颜色。只读。
示例
python
#本示例向第一张工作表中添加椭圆,然后指定椭圆的深度为 50 磅,并指定深度部分的颜色为紫色
def test():
worksheet = Worksheets.Item(1)
shape = worksheet.Shapes.AddShape(msoShapeOval, 90, 90, 90, 40)
threeDFormat = shape.ThreeD
threeDFormat.Visible = True
threeDFormat.Depth = 50
threeDFormat.ExtrusionColor.RGB = RGB(255, 100, 255)
#RGB value for purple
python
#本示例显示活动工作表中第三个形状的延伸的颜色是否为红色
def test():
shape = ActiveSheet.Shapes.Item(3)
print(shape.ThreeD.ExtrusionColor.RGB == RGB(255, 0, 0))