Word.BorderLineStyle enum
Gibt die Rahmenart für ein Objekt an.
Hinweise
Verwendet von
Beispiele
// Link to full sample: https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/word/25-paragraph/add-border-to-paragraph.yaml
if (!Office.context.requirements.isSetSupported("WordApiDesktop", "1.3")) {
console.error("This sample requires WordApiDesktop 1.3 or later.");
return;
}
await Word.run(async (context) => {
// Insert a paragraph at the beginning of the document.
const paragraph: Word.Paragraph =
context.document.body.insertParagraph(
"Note: Added a border to this paragraph.",
Word.InsertLocation.start
);
// Load the paragraph borders so they can be formatted.
const borders: Word.BorderUniversalCollection = paragraph.borders;
borders.load("items");
await context.sync();
// Apply a visible double blue line to every side of the paragraph.
borders.items.forEach((border: Word.BorderUniversal) => {
border.isVisible = true;
border.color = "#4472C4";
border.lineStyle = Word.BorderLineStyle.double;
border.lineWidth = Word.LineWidth.pt150;
});
await context.sync();
console.log(
`Applied the ${Word.BorderLineStyle.double} line style to ${borders.items.length} paragraph borders.`
);
});
Felder
| dashDot = "DashDot" | Linienart "Strichlinie". |
| dashDotDot = "DashDotDot" | Linienart "Strich-Punkt-Punkt". |
| dashDotStroked = "DashDotStroked" | Linienart mit gestrichelten Punkten. |
| dashLargeGap = "DashLargeGap" | Gestrichelte Linie mit großen Lücken |
| dashSmallGap = "DashSmallGap" | Gestrichelte Linie mit kleinen Lücken |
| dot = "Dot" | Gepunktete Linienart. |
| double = "Double" | Doppelter Linienstil. |
| doubleWavy = "DoubleWavy" | Doppelte Wellenlinie. |
| emboss3D = "Emboss3D" | Geprägte 3D-Linienart. |
| engrave3D = "Engrave3D" | Eingravierte 3D-Linienart. |
| inset = "Inset" | Eingefügte Linienart. |
| none = "None" | Keine Linienart. |
| outset = "Outset" | Linienart "Gliederung". |
| single = "Single" | Einzeilige Art. |
| singleWavy = "SingleWavy" | Einzelne Wellenlinie. |
| thickThinLargeGap = "ThickThinLargeGap" | Dick-dünne Linienart mit großen Lücken. |
| thickThinMedGap = "ThickThinMedGap" | Dick-dünne Linienart mit mittleren Lücken. |
| thickThinSmallGap = "ThickThinSmallGap" | Dick-dünne Linienart mit kleinen Lücken. |
| thinThickLargeGap = "ThinThickLargeGap" | Dünn-dicke Linienform mit großen Lücken. |
| thinThickMedGap = "ThinThickMedGap" | Dünn-dicke Linienform mit mittleren Lücken. |
| thinThickSmallGap = "ThinThickSmallGap" | Dünn-dicke Linienart mit kleinen Lücken. |
| thinThickThinLargeGap = "ThinThickThinLargeGap" | Dünn-dick-dünne Linienart mit großen Lücken. |
| thinThickThinMedGap = "ThinThickThinMedGap" | Dünn-dick-dünne Linienart mit mittleren Lücken. |
| thinThickThinSmallGap = "ThinThickThinSmallGap" | Dünn-dick-dünne Linienart mit kleinen Lücken. |
| triple = "Triple" | Dreifache Linienart. |