ThreeDFormat
ITextFrameFormat.ThreeDFormat 属性
返回一个表示文本的 3D 效果属性的 ThreeDFormat 对象。仅限读取 IThreeDFormat
。
public IThreeDFormat ThreeDFormat { get; }
示例
[C#]
using (Presentation pres = new Presentation())
{
IAutoShape autoShape = pres.Slides[0].Shapes.AddAutoShape(ShapeType.Rectangle, 10, 20, 400, 300);
ITextFrame textFrame = autoShape.TextFrame;
textFrame.Text = "Aspose.Slide 测试文本";
// 设置文本变换
textFrame.TextFrameFormat.Transform = TextShapeType.ArchUpPour;
// 设置挤出
textFrame.TextFrameFormat.ThreeDFormat.ExtrusionColor.Color = Color.Orange;
textFrame.TextFrameFormat.ThreeDFormat.ExtrusionHeight = 6;
// 设置轮廓
textFrame.TextFrameFormat.ThreeDFormat.ContourColor.Color = Color.DarkRed;
textFrame.TextFrameFormat.ThreeDFormat.ContourWidth = 1.5;
// 设置深度
textFrame.TextFrameFormat.ThreeDFormat.Depth = 3;
// 设置材质
textFrame.TextFrameFormat.ThreeDFormat.Material = MaterialPresetType.Plastic;
// 设置照明
textFrame.TextFrameFormat.ThreeDFormat.LightRig.Direction = LightingDirection.Top;
textFrame.TextFrameFormat.ThreeDFormat.LightRig.LightType = LightRigPresetType.Balanced;
textFrame.TextFrameFormat.ThreeDFormat.LightRig.SetRotation(0, 0, 40);
// 设置相机类型
textFrame.TextFrameFormat.ThreeDFormat.Camera.CameraType = CameraPresetType.PerspectiveContrastingRightFacing;
}
另请参见
- 接口 IThreeDFormat
- 接口 ITextFrameFormat
- 命名空间 Aspose.Slides
- 程序集 Aspose.Slides