PowerPoint.ShapeLineStyle enum
Spécifie le style d'une ligne.
Remarques
[ Ensemble d’API : PowerPointApi 1.4 ]
Exemples
// Link to full sample: https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/powerpoint/shapes/get-shapes-by-type.yaml
// Changes the dash style of every line in the slide.
await PowerPoint.run(async (context) => {
// Get the type of shape for every shape in the collection.
const shapes: PowerPoint.ShapeCollection = context.presentation.slides.getItemAt(0).shapes;
shapes.load("type");
await context.sync();
// Change the dash style for shapes of the type `line`.
shapes.items.forEach((shape) => {
if (shape.type === PowerPoint.ShapeType.line) {
shape.lineFormat.style = PowerPoint.ShapeLineStyle.thickThin;
shape.lineFormat.dashStyle = PowerPoint.ShapeLineDashStyle.dashDot;
}
});
await context.sync();
});
Champs
| single = "Single" | Ligne simple. |
| thickBetweenThin = "ThickBetweenThin" | Trait épais avec un trait fin de chaque coté |
| thickThin = "ThickThin" | Trait épais jouxtant un trait fin. Pour les lignes horizontales, la ligne épaisse se trouve au-dessus de la ligne mince. Pour les lignes verticales, la ligne épaisse est à gauche de la ligne mince. |
| thinThick = "ThinThick" | Trait épais jouxtant un trait fin. Pour les lignes horizontales, la ligne épaisse se trouve sous la ligne mince. Pour les lignes verticales, la ligne épaisse se trouve à droite de la ligne mince. |
| thinThin = "ThinThin" | Deux traits fins |