PowerPoint.ShapeFontUnderlineStyle enum
应用于字体的下划线类型。
注解
示例
// Link to full sample: https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/powerpoint/shapes/shapes.yaml
// This function gets the collection of shapes on the first slide,
// and adds a brace pair, {}, to the collection, while specifying its
// location and size. Then it names the shape, sets its text and font
// color, and centers it inside the braces.
await PowerPoint.run(async (context) => {
const shapes: PowerPoint.ShapeCollection = context.presentation.slides.getItemAt(0).shapes;
const braces: PowerPoint.Shape = shapes.addGeometricShape(PowerPoint.GeometricShapeType.bracePair, {
left: 100,
top: 400,
height: 50,
width: 150,
});
braces.name = "Braces";
braces.textFrame.textRange.text = "Shape text";
braces.textFrame.textRange.font.color = "purple";
braces.textFrame.textRange.font.underline = PowerPoint.ShapeFontUnderlineStyle.heavy;
braces.textFrame.verticalAlignment = PowerPoint.TextVerticalAlignment.middleCentered;
braces.textFrame.autoSizeSetting = PowerPoint.ShapeAutoSize.autoSizeShapeToFitText;
return context.sync();
});
字段
| dash = "Dash" | 带有包含短划线的行的文本下划线。 |
| dashHeavy = "DashHeavy" | 用包含短划线的粗线为文本下划线。 |
| dashLong = "DashLong" | 带有包含长短划线的行的文本的下划线。 |
| dashLongHeavy = "DashLongHeavy" | 用包含长短划线的粗线下划线文本。 |
| dotDash = "DotDash" | 用包含点和短划线的线条下划线文本。 |
| dotDashHeavy = "DotDashHeavy" | 用包含点和短划线的粗线为文本下划线。 |
| dotDotDash = "DotDotDash" | 用包含双点和短划线的线条下划线文本。 |
| dotDotDashHeavy = "DotDotDashHeavy" | 用包含双点和短划线的粗线对文本进行下划线。 |
| dotted = "Dotted" | 带虚线的文本的下划线。 |
| dottedHeavy = "DottedHeavy" | 用粗虚线下划线的文本。 |
| double = "Double" | 双行文本的下划线。 |
| heavy = "Heavy" | 用粗行下划文本的下划线。 |
| none = "None" | 无下划线。 |
| single = "Single" | 常规单行下划线。 |
| wavy = "Wavy" | 带波浪线的文本的下划线。 |
| wavyDouble = "WavyDouble" | 带有双波浪线的文本的下划线。 |
| wavyHeavy = "WavyHeavy" | 用粗波浪线下划文本的下划线。 |