Setting Shadow of Text Effects of Shape or TextBox with Golang via C++
Contents
[
Hide
]
You can set the Shadow of Text Effects for any Shape or TextBox. Please use the Shape.GetTextBody() property. It provides access to the shape’s text settings and returns FontSetting objects. After accessing it, set the Shadow via the FontSetting.GetPresetType() property. This property is of the type PresetShadowType, which has several values. Some of these are:
- OffsetDiagonalBottomRight
- OffsetBottom
- OffsetDiagonalTopRight
- InsideLeft
- InsideCenter
- PerspectiveDiagonalUpperLeft
- PerspectiveDiagonalLowerRight
The following code snippet demonstrates the use of FontSetting.GetPresetType() to set the shadow of text effects for a Shape or TextBox.