From b34a9d814bc1f4330350534c2154e7667c7f444c Mon Sep 17 00:00:00 2001 From: Elizabeth Samuel Date: Mon, 15 Sep 2025 16:59:46 -0700 Subject: [PATCH 1/2] [office-js-preview] (Word) Add TableOfFiguresAddOptions descriptions (#73680) --- types/office-js-preview/index.d.ts | 99 ++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) diff --git a/types/office-js-preview/index.d.ts b/types/office-js-preview/index.d.ts index 74526773537a7fa..5b49aa5e89b01fa 100644 --- a/types/office-js-preview/index.d.ts +++ b/types/office-js-preview/index.d.ts @@ -114488,17 +114488,116 @@ declare namespace Word { * @beta */ interface TableOfFiguresAddOptions { + /** + * If provided, specifies the string names of additional styles to use for the table of figures. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ addedStyles?: string; + /** + * If provided, specifies the label that identifies the items to include in a table of figures. + * Corresponds to the `\c` switch for a {@link https://support.microsoft.com/office/1f538bc4-60e6-4854-9f64-67754d78d05c | Table of Contents (TOC) field}. + * The default value is "Figure". + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ captionLabel?: string; + /** + * If provided, specifies whether the page numbers in the table of figures should be hidden when publishing to the web. + * The default value is `true`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ hidePageNumbersOnWeb?: boolean; + /** + * If provided, specifies whether to include the caption label and caption number in a table of figures. + * The default value is `true`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ includeLabel?: boolean; + /** + * If provided, specifies whether page numbers are included in a table of figures. + * The default value is `true`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ includePageNumbers?: boolean; + /** + * If provided, specifies the ending heading level for a table of figures when `useBuiltInHeadingStyles` is set to `true`. Should be a value from 1 to 9 and greater than `upperHeadingLevel`. + * Corresponds to the ending value used with the `\o` switch for a {@link https://support.microsoft.com/office/1f538bc4-60e6-4854-9f64-67754d78d05c | Table of Contents (TOC) field}. + * The default value is `9`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ lowerHeadingLevel?: number; + /** + * If provided, specifies whether to align page numbers with the right margin in a table of figures. + * The default value is `true`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ rightAlignPageNumbers?: boolean; + /** + * If provided, specifies a one-letter identifier from {@link https://support.microsoft.com/office/01e5dd8a-4730-4bc2-8594-23d7329e25c3 | TC fields} that's used for a table of figures. + * Corresponds to the `\f` switch for a {@link https://support.microsoft.com/office/1f538bc4-60e6-4854-9f64-67754d78d05c | Table of Contents (TOC) field}. For example, "T" indicates a table of figures includes TC fields that use the table identifier T. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ tableId?: string; + /** + * If provided, specifies the starting heading level for a table of figures when `useBuiltInHeadingStyles` is set to `true`. Should be a value from 1 to 9 and smaller than `lowerHeadingLevel`. + * Corresponds to the starting value used with the `\o` switch for a {@link https://support.microsoft.com/office/1f538bc4-60e6-4854-9f64-67754d78d05c | Table of Contents (TOC) field}. + * The default value is `1`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ upperHeadingLevel?: number; + /** + * If provided, specifies whether to use built-in heading styles to create a table of figures. + * The default value is `false`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ useBuiltInHeadingStyles?: boolean; + /** + * If provided, specifies whether to use {@link https://support.microsoft.com/office/01e5dd8a-4730-4bc2-8594-23d7329e25c3 | Table of Contents Entry (TC) fields} to create a table of figures. + * Use the {@link Word.TableOfFiguresCollection | TableOfFiguresCollection.markTocEntry} method to mark entries to include in a table of figures. + * The default value is `false`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ useFields?: boolean; + /** + * If provided, specifies whether entries in a table of figures should be formatted as hyperlinks when the document is published to the web. + * The default value is `true`. + * + * @remarks + * [Api set: WordApi BETA (PREVIEW ONLY)] + * @beta + */ useHyperlinksOnWeb?: boolean; } /** From 6b9db9cb6de7119fa63ab3ce81c8544b40af04ed Mon Sep 17 00:00:00 2001 From: Elizabeth Samuel Date: Mon, 15 Sep 2025 19:02:02 -0700 Subject: [PATCH 2/2] [office-js] [office-js-preview] (PowerPoint) Updates from CDN (#73678) --- types/office-js-preview/index.d.ts | 10793 ++++++++++++++------------- types/office-js/index.d.ts | 7251 +++++++++--------- 2 files changed, 9387 insertions(+), 8657 deletions(-) diff --git a/types/office-js-preview/index.d.ts b/types/office-js-preview/index.d.ts index 5b49aa5e89b01fa..70446f93fe8c56b 100644 --- a/types/office-js-preview/index.d.ts +++ b/types/office-js-preview/index.d.ts @@ -181939,6 +181939,75 @@ declare namespace PowerPoint { */ slideMasterId?: string; } + /** + * Represents the adjustment values for a shape. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + class Adjustments extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Specifies the number of adjustment points. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + readonly count: number; + /** + * Gets the adjustment value at the specified zero-based index. + Throws an `InvalidArgument` exception when the index is out of range. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param index The index of the adjustment to retrieve. + * @returns The adjustment value at the given index. + */ + get(index: number): OfficeExtension.ClientResult; + /** + * Sets the adjustment value at the specified zero-based index. + Throws an `InvalidArgument` exception when the index is out of range. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param index The index of the adjustment to set. + * @param value The adjustment value to set. + */ + set(index: number, value: number): void; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.AdjustmentsLoadOptions): PowerPoint.Adjustments; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.Adjustments; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Adjustments; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.Adjustments` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.AdjustmentsData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.AdjustmentsData; + } /** * Represents the possible binding types. * @@ -182056,6 +182125,18 @@ declare namespace PowerPoint { * @param id ID of the object to be retrieved. */ getItem(id: string): PowerPoint.CustomXmlPart; + /** + * Gets a `CustomXmlPart` by its zero-based index in the collection. + Throws an `InvalidArgument` exception when the index is out of range. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param index The index of the custom XML part in the collection. + * @returns The custom XML part at the given index. + */ + getItemAt(index: number): PowerPoint.CustomXmlPart; /** * Gets a `CustomXmlPart` based on its ID. If the `CustomXmlPart` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. @@ -182153,6 +182234,18 @@ declare namespace PowerPoint { * @param id ID of the object to be retrieved. */ getItem(id: string): PowerPoint.CustomXmlPart; + /** + * Gets a `CustomXmlPart` by its zero-based index in the collection. + Throws an `InvalidArgument` exception when the index is out of range. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param index The index of the custom XML part in the collection. + * @returns The custom XML part at the given index. + */ + getItemAt(index: number): PowerPoint.CustomXmlPart; /** * Gets a `CustomXmlPart` based on its ID. If the `CustomXmlPart` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. @@ -182189,3080 +182282,3003 @@ declare namespace PowerPoint { toJSON(): PowerPoint.Interfaces.CustomXmlPartCollectionData; } /** - * Specifies the type of a placeholder. + * Represents the available options when adding a {@link PowerPoint.Hyperlink}. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - enum PlaceholderType { + interface HyperlinkAddOptions { /** - * The placeholder is unsupported. + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - unsupported = "Unsupported", + address?: string; /** - * The placeholder is for a date. + * Specifies the string displayed when hovering over the hyperlink. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - date = "Date", + screenTip?: string; + } + /** + * Represents a scoped collection of hyperlinks. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + class HyperlinkScopedCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.Hyperlink[]; /** - * The placeholder is for a slide number. + * Gets the number of hyperlinks in the collection. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * @returns The number of hyperlinks in the collection. */ - slideNumber = "SlideNumber", + getCount(): OfficeExtension.ClientResult; /** - * The placeholder is for a footer. + * Gets a hyperlink using its zero-based index in the collection. + Throws an `InvalidArgument` exception when the index is out of range. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param index The index of the hyperlink in the collection. + * @returns The hyperlink at the given index. */ - footer = "Footer", + getItemAt(index: number): PowerPoint.Hyperlink; /** - * The placeholder is for a header. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - header = "Header", + load(options?: PowerPoint.Interfaces.HyperlinkScopedCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.HyperlinkScopedCollection; /** - * The placeholder is for a title. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - title = "Title", + load(propertyNames?: string | string[]): PowerPoint.HyperlinkScopedCollection; /** - * The placeholder is for a body. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - body = "Body", + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.HyperlinkScopedCollection; /** - * The placeholder is for a center title. - * @remarks - * [Api set: PowerPointApi 1.8] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.HyperlinkScopedCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkScopedCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - centerTitle = "CenterTitle", + toJSON(): PowerPoint.Interfaces.HyperlinkScopedCollectionData; + } + /** + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ParagraphHorizontalAlignment { /** - * The placeholder is for a subtitle. + * Align text to the left margin. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subtitle = "Subtitle", + left = "Left", /** - * The placeholder is for a vertical title. + * Align text in the center. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - verticalTitle = "VerticalTitle", + center = "Center", /** - * The placeholder is for a vertical body. + * Align text to the right margin. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - verticalBody = "VerticalBody", + right = "Right", /** - * The placeholder is for generic content. + * Align text so that it's justified across the whole line. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - content = "Content", + justify = "Justify", /** - * The placeholder is for a chart. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - chart = "Chart", + justifyLow = "JustifyLow", /** - * The placeholder is for a table. + * Distributes the text words across an entire text line. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - table = "Table", + distributed = "Distributed", /** - * The placeholder is for an online picture. + * Distributes Thai text specially, because each character is treated as a word. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - onlinePicture = "OnlinePicture", + thaiDistributed = "ThaiDistributed", + } + /** + * Specifies the style of a bullet. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + enum BulletStyle { /** - * The placeholder is for a SmartArt. + * Style is unsupported. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - smartArt = "SmartArt", + unsupported = "Unsupported", /** - * The placeholder is for media. + * Lowercase alphabetical characters with a period. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - media = "Media", + alphabetLowercasePeriod = "AlphabetLowercasePeriod", /** - * The placeholder is for generic vertical content. + * Uppercase alphabetical characters with a period. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - verticalContent = "VerticalContent", + alphabetUppercasePeriod = "AlphabetUppercasePeriod", /** - * The placeholder is for a picture. + * Arabic numerals with closing parenthesis. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - picture = "Picture", + arabicNumeralParenthesisRight = "ArabicNumeralParenthesisRight", /** - * The placeholder is for a cameo. + * Arabic numerals with a period. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - cameo = "Cameo", - } - /** - * Specifies the type of a shape. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ShapeType { + arabicNumeralPeriod = "ArabicNumeralPeriod", /** - * The given shape's type is unsupported. + * Lowercase Roman numerals with both parentheses. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - unsupported = "Unsupported", + romanLowercaseParenthesesBoth = "RomanLowercaseParenthesesBoth", /** - * The shape is an image. + * Lowercase Roman numerals with closing parenthesis. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - image = "Image", + romanLowercaseParenthesisRight = "RomanLowercaseParenthesisRight", /** - * The shape is a geometric shape such as rectangle. + * Lowercase Roman numerals with period. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - geometricShape = "GeometricShape", + romanLowercasePeriod = "RomanLowercasePeriod", /** - * The shape is a group shape which contains sub-shapes. + * Uppercase Roman numerals with period. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - group = "Group", + romanUppercasePeriod = "RomanUppercasePeriod", /** - * The shape is a line. + * Lowercase alphabetical characters with both parentheses. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - line = "Line", + alphabetLowercaseParenthesesBoth = "AlphabetLowercaseParenthesesBoth", /** - * The shape is a table. + * Lowercase alphabetical characters with closing parenthesis. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - table = "Table", + alphabetLowercaseParenthesisRight = "AlphabetLowercaseParenthesisRight", /** - * The shape is a callout. + * Uppercase alphabetical characters with both parentheses. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - callout = "Callout", + alphabetUppercaseParenthesesBoth = "AlphabetUppercaseParenthesesBoth", /** - * The shape is a chart. + * Uppercase alphabetical characters with closing parenthesis. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - chart = "Chart", + alphabetUppercaseParenthesisRight = "AlphabetUppercaseParenthesisRight", /** - * The shape is a content Office Add-in. + * Arabic numerals with both parentheses. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - contentApp = "ContentApp", + arabicNumeralParenthesesBoth = "ArabicNumeralParenthesesBoth", /** - * The shape is a diagram. + * Arabic numerals. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - diagram = "Diagram", + arabicNumeralPlain = "ArabicNumeralPlain", /** - * The shape is a freeform object. + * Uppercase Roman numerals with both parentheses. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - freeform = "Freeform", + romanUppercaseParenthesesBoth = "RomanUppercaseParenthesesBoth", /** - * The shape is a graphic. + * Uppercase Roman numerals with closing parenthesis. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - graphic = "Graphic", + romanUppercaseParenthesisRight = "RomanUppercaseParenthesisRight", /** - * The shape is an ink object. + * Simplified Chinese without a period. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - ink = "Ink", + simplifiedChinesePlain = "SimplifiedChinesePlain", /** - * The shape is a media object. + * Simplified Chinese with a period. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - media = "Media", + simplifiedChinesePeriod = "SimplifiedChinesePeriod", /** - * The shape is a 3D model. + * Double-byte circled number for values up to 10. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - model3D = "Model3D", + circleNumberDoubleBytePlain = "CircleNumberDoubleBytePlain", /** - * The shape is an OLE (Object Linking and Embedding) object. + * Text colored number with same color circle drawn around it. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - ole = "Ole", + circleNumberWideDoubleByteWhitePlain = "CircleNumberWideDoubleByteWhitePlain", /** - * The shape is a placeholder. + * Shadow color number with circular background of normal text color. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - placeholder = "Placeholder", + circleNumberWideDoubleByteBlackPlain = "CircleNumberWideDoubleByteBlackPlain", /** - * The shape is a SmartArt graphic. + * Traditional Chinese without a period. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - smartArt = "SmartArt", + traditionalChinesePlain = "TraditionalChinesePlain", /** - * The shape is a text box. + * Traditional Chinese with a period. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - textBox = "TextBox", - } - /** - * Represents the properties of a `placeholder` shape. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - class PlaceholderFormat extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + traditionalChinesePeriod = "TraditionalChinesePeriod", /** - * Gets the type of the shape contained within the placeholder. See {@link PowerPoint.ShapeType} for details. - Returns `null` if the placeholder is empty. - * + * Arabic alphabet with a dash. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly containedType: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox" | null; + arabicAlphabetDash = "ArabicAlphabetDash", /** - * Returns the type of this placeholder. See {@link PowerPoint.PlaceholderType} for details. - * + * Arabic Abjad alphabet with a dash. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly type: PowerPoint.PlaceholderType | "Unsupported" | "Date" | "SlideNumber" | "Footer" | "Header" | "Title" | "Body" | "CenterTitle" | "Subtitle" | "VerticalTitle" | "VerticalBody" | "Content" | "Chart" | "Table" | "OnlinePicture" | "SmartArt" | "Media" | "VerticalContent" | "Picture" | "Cameo"; + arabicAbjadDash = "ArabicAbjadDash", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Hebrew alphabet with a dash. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(options?: PowerPoint.Interfaces.PlaceholderFormatLoadOptions): PowerPoint.PlaceholderFormat; + hebrewAlphabetDash = "HebrewAlphabetDash", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Japanese/Korean numbers without a period. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNames?: string | string[]): PowerPoint.PlaceholderFormat; + kanjiKoreanPlain = "KanjiKoreanPlain", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Japanese/Korean numbers with a period. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.PlaceholderFormat; + kanjiKoreanPeriod = "KanjiKoreanPeriod", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.PlaceholderFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.PlaceholderFormatData`) that contains shallow copies of any loaded child properties from the original object. + * Double-byte Arabic numbering scheme (no punctuation). + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - toJSON(): PowerPoint.Interfaces.PlaceholderFormatData; - } - /** - * Represents a single hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - class Hyperlink extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + arabicDoubleBytePlain = "ArabicDoubleBytePlain", /** - * Specifies the URL target of the hyperlink. - * + * Double-byte Arabic numbering scheme with double-byte period. * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - address: string; + arabicDoubleBytePeriod = "ArabicDoubleBytePeriod", /** - * Specifies the string displayed when hovering over the hyperlink. - * + * Thai alphabet with a period. * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - screenTip: string; + thaiAlphabetPeriod = "ThaiAlphabetPeriod", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Thai alphabet with closing parenthesis. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(options?: PowerPoint.Interfaces.HyperlinkLoadOptions): PowerPoint.Hyperlink; + thaiAlphabetParenthesisRight = "ThaiAlphabetParenthesisRight", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Thai alphabet with both parentheses. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNames?: string | string[]): PowerPoint.Hyperlink; + thaiAlphabetParenthesesBoth = "ThaiAlphabetParenthesesBoth", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Thai numerals with a period. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Hyperlink; + thaiNumeralPeriod = "ThaiNumeralPeriod", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Hyperlink` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkData`) that contains shallow copies of any loaded child properties from the original object. + * Thai numerals with closing parenthesis. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - toJSON(): PowerPoint.Interfaces.HyperlinkData; - } - /** - * Represents a collection of hyperlinks. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - class HyperlinkCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + thaiNumeralParenthesisRight = "ThaiNumeralParenthesisRight", + /** + * Thai numerals with both parentheses. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + thaiNumeralParenthesesBoth = "ThaiNumeralParenthesesBoth", + /** + * Hindi alphabet (vowels) with a period. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + hindiAlphabetPeriod = "HindiAlphabetPeriod", + /** + * Hindi numerals with a period. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + hindiNumeralPeriod = "HindiNumeralPeriod", + /** + * Kanji Simplified Chinese with double-byte period. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + kanjiSimplifiedChineseDoubleBytePeriod = "KanjiSimplifiedChineseDoubleBytePeriod", + /** + * Hindi numerals with closing parenthesis. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + hindiNumeralParenthesisRight = "HindiNumeralParenthesisRight", + /** + * Hindi alphabet (consonants) with a period. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + hindiAlphabet1Period = "HindiAlphabet1Period", + } + /** + * Specifies the type of a bullet. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + enum BulletType { + /** + * Type is unsupported. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + unsupported = "Unsupported", + /** + * No bullets. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + none = "None", + /** + * Numbered bullet (e.g., 1, 2, 3 or a, b, c). + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + numbered = "Numbered", + /** + * Symbol-based bullet (e.g., disc, circle, square). + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + unnumbered = "Unnumbered", + } + /** + * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class BulletFormat extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.Hyperlink[]; /** - * Gets the number of hyperlinks in the collection. + * Specifies the style of the bullets in the paragraph. See {@link PowerPoint.BulletStyle} for details. + Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. * * @remarks - * [Api set: PowerPointApi 1.6] - * @returns The number of hyperlinks in the collection. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - getCount(): OfficeExtension.ClientResult; + style: PowerPoint.BulletStyle | "Unsupported" | "AlphabetLowercasePeriod" | "AlphabetUppercasePeriod" | "ArabicNumeralParenthesisRight" | "ArabicNumeralPeriod" | "RomanLowercaseParenthesesBoth" | "RomanLowercaseParenthesisRight" | "RomanLowercasePeriod" | "RomanUppercasePeriod" | "AlphabetLowercaseParenthesesBoth" | "AlphabetLowercaseParenthesisRight" | "AlphabetUppercaseParenthesesBoth" | "AlphabetUppercaseParenthesisRight" | "ArabicNumeralParenthesesBoth" | "ArabicNumeralPlain" | "RomanUppercaseParenthesesBoth" | "RomanUppercaseParenthesisRight" | "SimplifiedChinesePlain" | "SimplifiedChinesePeriod" | "CircleNumberDoubleBytePlain" | "CircleNumberWideDoubleByteWhitePlain" | "CircleNumberWideDoubleByteBlackPlain" | "TraditionalChinesePlain" | "TraditionalChinesePeriod" | "ArabicAlphabetDash" | "ArabicAbjadDash" | "HebrewAlphabetDash" | "KanjiKoreanPlain" | "KanjiKoreanPeriod" | "ArabicDoubleBytePlain" | "ArabicDoubleBytePeriod" | "ThaiAlphabetPeriod" | "ThaiAlphabetParenthesisRight" | "ThaiAlphabetParenthesesBoth" | "ThaiNumeralPeriod" | "ThaiNumeralParenthesisRight" | "ThaiNumeralParenthesesBoth" | "HindiAlphabetPeriod" | "HindiNumeralPeriod" | "KanjiSimplifiedChineseDoubleBytePeriod" | "HindiNumeralParenthesisRight" | "HindiAlphabet1Period" | null; /** - * Gets a hyperlink using its zero-based index in the collection. An error is thrown if the index is out of range. + * Specifies the type of the bullets in the paragraph. See {@link PowerPoint.BulletType} for details. + Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + type: PowerPoint.BulletType | "Unsupported" | "None" | "Numbered" | "Unnumbered" | null; + /** + * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. * - * @param index The index of the hyperlink in the collection. - * @returns The hyperlink at the given index. An error is thrown if index is out of range. + * @remarks + * [Api set: PowerPointApi 1.4] */ - getItemAt(index: number): PowerPoint.Hyperlink; + visible: boolean | null; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.HyperlinkCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.HyperlinkCollection; + load(options?: PowerPoint.Interfaces.BulletFormatLoadOptions): PowerPoint.BulletFormat; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.HyperlinkCollection; + load(propertyNames?: string | string[]): PowerPoint.BulletFormat; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.HyperlinkCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.BulletFormat; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.HyperlinkCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Whereas the original `PowerPoint.BulletFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BulletFormatData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.HyperlinkCollectionData; + toJSON(): PowerPoint.Interfaces.BulletFormatData; } /** - * Specifies the connector type for line shapes. + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ConnectorType { + class ParagraphFormat extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Straight connector type + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - straight = "Straight", + readonly bulletFormat: PowerPoint.BulletFormat; /** - * Elbow connector type + * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - elbow = "Elbow", + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; /** - * Curve connector type + * Represents the indent level of the paragraph. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - curve = "Curve", + indentLevel: number; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.ParagraphFormatLoadOptions): PowerPoint.ParagraphFormat; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.ParagraphFormat; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.ParagraphFormat; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.ParagraphFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ParagraphFormatData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** - * Specifies the shape type for a `GeometricShape` object. + * The type of underline applied to a font. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum GeometricShapeType { - /** - * Straight Line from Top-Right Corner to Bottom-Left Corner of the Shape - * @remarks - * [Api set: PowerPointApi 1.4] - */ - lineInverse = "LineInverse", + enum ShapeFontUnderlineStyle { /** - * Isosceles Triangle + * No underlining. * @remarks * [Api set: PowerPointApi 1.4] */ - triangle = "Triangle", + none = "None", /** - * Right Triangle + * Regular single line underlining. * @remarks * [Api set: PowerPointApi 1.4] */ - rightTriangle = "RightTriangle", + single = "Single", /** - * Rectangle + * Underlining of text with double lines. * @remarks * [Api set: PowerPointApi 1.4] */ - rectangle = "Rectangle", + double = "Double", /** - * Diamond + * Underlining of text with a thick line. * @remarks * [Api set: PowerPointApi 1.4] */ - diamond = "Diamond", + heavy = "Heavy", /** - * Parallelogram + * Underlining of text with a dotted line. * @remarks * [Api set: PowerPointApi 1.4] */ - parallelogram = "Parallelogram", + dotted = "Dotted", /** - * Trapezoid + * Underlining of text with a thick, dotted line. * @remarks * [Api set: PowerPointApi 1.4] */ - trapezoid = "Trapezoid", + dottedHeavy = "DottedHeavy", /** - * Trapezoid which may have Non-Equal Sides + * Underlining of text with a line containing dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - nonIsoscelesTrapezoid = "NonIsoscelesTrapezoid", + dash = "Dash", /** - * Pentagon + * Underlining of text with a thick line containing dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - pentagon = "Pentagon", + dashHeavy = "DashHeavy", /** - * Hexagon + * Underlining of text with a line containing long dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - hexagon = "Hexagon", + dashLong = "DashLong", /** - * Heptagon + * Underlining of text with a thick line containing long dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - heptagon = "Heptagon", + dashLongHeavy = "DashLongHeavy", /** - * Octagon + * Underlining of text with a line containing dots and dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - octagon = "Octagon", + dotDash = "DotDash", /** - * Decagon + * Underlining of text with a thick line containing dots and dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - decagon = "Decagon", + dotDashHeavy = "DotDashHeavy", /** - * Dodecagon + * Underlining of text with a line containing double dots and dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - dodecagon = "Dodecagon", + dotDotDash = "DotDotDash", /** - * Star: 4 Points + * Underlining of text with a thick line containing double dots and dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - star4 = "Star4", + dotDotDashHeavy = "DotDotDashHeavy", /** - * Star: 5 Points + * Underlining of text with a wavy line. * @remarks * [Api set: PowerPointApi 1.4] */ - star5 = "Star5", + wavy = "Wavy", /** - * Star: 6 Points + * Underlining of text with a thick, wavy line. * @remarks * [Api set: PowerPointApi 1.4] */ - star6 = "Star6", + wavyHeavy = "WavyHeavy", /** - * Star: 7 Points + * Underlining of text with double wavy lines. * @remarks * [Api set: PowerPointApi 1.4] */ - star7 = "Star7", - /** - * Star: 8 Points + wavyDouble = "WavyDouble", + } + /** + * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class ShapeFont extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: + + - `true`: All the text has the **All Caps** attribute. + + - `false`: None of the text has the **All Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - star8 = "Star8", + allCaps: boolean | null; /** - * Star: 10 Points + * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: + + - `true`: All the text is bold. + + - `false`: None of the text is bold. + + - `null`: Returned if some, but not all, of the text is bold. + * * @remarks * [Api set: PowerPointApi 1.4] */ - star10 = "Star10", + bold: boolean | null; /** - * Star: 12 Points + * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. + * * @remarks * [Api set: PowerPointApi 1.4] */ - star12 = "Star12", + color: string | null; /** - * Star: 16 Points + * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Double strikethrough** attribute. + + - `false`: None of the text has the **Double strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - star16 = "Star16", + doubleStrikethrough: boolean | null; /** - * Star: 24 Points + * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: + + - `true`: All the text is italicized. + + - `false`: None of the text is italicized. + + - `null`: Returned if some, but not all, of the text is italicized. + * * @remarks * [Api set: PowerPointApi 1.4] */ - star24 = "Star24", + italic: boolean | null; /** - * Star: 32 Points + * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. + * * @remarks * [Api set: PowerPointApi 1.4] */ - star32 = "Star32", + name: string | null; /** - * Rectangle: Rounded Corners + * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. + * * @remarks * [Api set: PowerPointApi 1.4] */ - roundRectangle = "RoundRectangle", + size: number | null; /** - * Rectangle: Single Corner Rounded + * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: + + - `true`: All the text has the **Small Caps** attribute. + + - `false`: None of the text has the **Small Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - round1Rectangle = "Round1Rectangle", + smallCaps: boolean | null; /** - * Rectangle: Top Corners Rounded + * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Strikethrough** attribute. + + - `false`: None of the text has the **Strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - round2SameRectangle = "Round2SameRectangle", + strikethrough: boolean | null; /** - * Rectangle: Diagonal Corners Rounded + * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Subscript** attribute. + + - `false`: None of the text has the **Subscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - round2DiagonalRectangle = "Round2DiagonalRectangle", + subscript: boolean | null; /** - * Rectangle: Top Corners One Rounded and One Snipped + * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Superscript** attribute. + + - `false`: None of the text has the **Superscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - snipRoundRectangle = "SnipRoundRectangle", + superscript: boolean | null; /** - * Rectangle: Single Corner Snipped + * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - snip1Rectangle = "Snip1Rectangle", + underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; /** - * Rectangle: Top Corners Snipped - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - snip2SameRectangle = "Snip2SameRectangle", + load(options?: PowerPoint.Interfaces.ShapeFontLoadOptions): PowerPoint.ShapeFont; /** - * Rectangle: Diagonal Corners Snipped - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - snip2DiagonalRectangle = "Snip2DiagonalRectangle", + load(propertyNames?: string | string[]): PowerPoint.ShapeFont; /** - * Plaque - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - plaque = "Plaque", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.ShapeFont; /** - * Oval - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.ShapeFont` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeFontData`) that contains shallow copies of any loaded child properties from the original object. */ - ellipse = "Ellipse", + toJSON(): PowerPoint.Interfaces.ShapeFontData; + } + /** + * Determines the type of automatic sizing allowed. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeAutoSize { /** - * Teardrop + * No autosizing. * @remarks * [Api set: PowerPointApi 1.4] */ - teardrop = "Teardrop", + autoSizeNone = "AutoSizeNone", /** - * Arrow: Pentagon + * The text is adjusted to fit the shape. * @remarks * [Api set: PowerPointApi 1.4] */ - homePlate = "HomePlate", + autoSizeTextToFitShape = "AutoSizeTextToFitShape", /** - * Arrow: Chevron + * The shape is adjusted to fit the text. * @remarks * [Api set: PowerPointApi 1.4] */ - chevron = "Chevron", + autoSizeShapeToFitText = "AutoSizeShapeToFitText", /** - * Partial Circle + * A combination of automatic sizing schemes are used. * @remarks * [Api set: PowerPointApi 1.4] */ - pieWedge = "PieWedge", + autoSizeMixed = "AutoSizeMixed", + } + /** + * Represents the vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + If one of the centered options is selected, the contents of the `TextFrame` will be centered horizontally within the `Shape` as a group. + To change the horizontal alignment of a text, see {@link PowerPoint.ParagraphFormat} and {@link PowerPoint.ParagraphHorizontalAlignment}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum TextVerticalAlignment { /** - * Partial Circle with Adjustable Spanning Area + * Specifies that the `TextFrame` should be top aligned to the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - pie = "Pie", + top = "Top", /** - * Block Arc + * Specifies that the `TextFrame` should be center aligned to the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - blockArc = "BlockArc", + middle = "Middle", /** - * Circle: Hollow + * Specifies that the `TextFrame` should be bottom aligned to the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - donut = "Donut", + bottom = "Bottom", /** - * "Not Allowed" Symbol + * Specifies that the `TextFrame` should be top aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - noSmoking = "NoSmoking", + topCentered = "TopCentered", /** - * Arrow: Right + * Specifies that the `TextFrame` should be center aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - rightArrow = "RightArrow", + middleCentered = "MiddleCentered", /** - * Arrow: Left + * Specifies that the `TextFrame` should be bottom aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - leftArrow = "LeftArrow", + bottomCentered = "BottomCentered", + } + /** + * Represents the text frame of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class TextFrame extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Arrow: Up + * Represents the text that is attached to a shape in the text frame, and properties and methods for manipulating the text. See {@link PowerPoint.TextRange} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - upArrow = "UpArrow", + readonly textRange: PowerPoint.TextRange; /** - * Arrow: Down + * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. + * * @remarks * [Api set: PowerPointApi 1.4] */ - downArrow = "DownArrow", + autoSizeSetting: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; /** - * Arrow: Striped Right + * Represents the bottom margin, in points, of the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - stripedRightArrow = "StripedRightArrow", + bottomMargin: number; /** - * Arrow: Notched Right + * Specifies if the text frame contains text. + * * @remarks * [Api set: PowerPointApi 1.4] */ - notchedRightArrow = "NotchedRightArrow", + readonly hasText: boolean; /** - * Arrow: Bent-Up + * Represents the left margin, in points, of the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - bentUpArrow = "BentUpArrow", + leftMargin: number; /** - * Arrow: Left-Right + * Represents the right margin, in points, of the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - leftRightArrow = "LeftRightArrow", + rightMargin: number; /** - * Arrow: Up-Down + * Represents the top margin, in points, of the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - upDownArrow = "UpDownArrow", + topMargin: number; /** - * Arrow: Left-Up + * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - leftUpArrow = "LeftUpArrow", + verticalAlignment: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; /** - * Arrow: Left-Right-Up + * Determines whether lines break automatically to fit text inside the shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - leftRightUpArrow = "LeftRightUpArrow", + wordWrap: boolean; /** - * Arrow: Quad + * Deletes all the text in the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - quadArrow = "QuadArrow", + deleteText(): void; /** - * Callout: Left Arrow + * Returns the parent {@link PowerPoint.Shape} object that holds this `TextFrame`. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - leftArrowCallout = "LeftArrowCallout", + getParentShape(): PowerPoint.Shape; /** - * Callout: Right Arrow - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - rightArrowCallout = "RightArrowCallout", + load(options?: PowerPoint.Interfaces.TextFrameLoadOptions): PowerPoint.TextFrame; /** - * Callout: Up Arrow - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - upArrowCallout = "UpArrowCallout", + load(propertyNames?: string | string[]): PowerPoint.TextFrame; /** - * Callout: Down Arrow - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - downArrowCallout = "DownArrowCallout", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TextFrame; /** - * Callout: Left-Right Arrow - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TextFrame` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TextFrameData`) that contains shallow copies of any loaded child properties from the original object. */ - leftRightArrowCallout = "LeftRightArrowCallout", + toJSON(): PowerPoint.Interfaces.TextFrameData; + } + /** + * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class TextRange extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Callout: Up-Down Arrow + * Returns a `ShapeFont` object that represents the font attributes for the text range. + * * @remarks * [Api set: PowerPointApi 1.4] */ - upDownArrowCallout = "UpDownArrowCallout", + readonly font: PowerPoint.ShapeFont; /** - * Callout: Quad Arrow + * Returns a collection of hyperlinks that exist on this `TextRange`. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - quadArrowCallout = "QuadArrowCallout", + readonly hyperlinks: PowerPoint.HyperlinkScopedCollection; /** - * Arrow: Bent + * Represents the paragraph format of the text range. See {@link PowerPoint.ParagraphFormat} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - bentArrow = "BentArrow", + readonly paragraphFormat: PowerPoint.ParagraphFormat; /** - * Arrow: U-Turn + * Gets or sets the length of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - uturnArrow = "UturnArrow", + length: number; /** - * Arrow: Circular + * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - circularArrow = "CircularArrow", + start: number; /** - * Arrow: Circular with Opposite Arrow Direction + * Represents the plain text content of the text range. + * * @remarks * [Api set: PowerPointApi 1.4] */ - leftCircularArrow = "LeftCircularArrow", + text: string; /** - * Arrow: Circular with Two Arrows in Both Directions + * Returns the parent {@link PowerPoint.TextFrame} object that holds this `TextRange`. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - leftRightCircularArrow = "LeftRightCircularArrow", + getParentTextFrame(): PowerPoint.TextFrame; /** - * Arrow: Curved Right + * Returns a `TextRange` object for the substring in the given range. + * * @remarks * [Api set: PowerPointApi 1.4] + * + * @param start The zero-based index of the first character to get from the text range. + * @param length Optional. The number of characters to be returned in the new text range. If length is omitted, all the characters from start to the end of the text range's last paragraph will be returned. */ - curvedRightArrow = "CurvedRightArrow", + getSubstring(start: number, length?: number): PowerPoint.TextRange; /** - * Arrow: Curved Left + * Sets a hyperlink on this `TextRange` with the specified options. This will delete all existing hyperlinks on this `TextRange`. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param options Optional. The options for the hyperlink. + * @returns The newly created {@link PowerPoint.Hyperlink} object. */ - curvedLeftArrow = "CurvedLeftArrow", + setHyperlink(options?: PowerPoint.HyperlinkAddOptions): PowerPoint.Hyperlink; /** - * Arrow: Curved Up + * Selects this `TextRange` in the current view. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - curvedUpArrow = "CurvedUpArrow", + setSelected(): void; /** - * Arrow: Curved Down - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - curvedDownArrow = "CurvedDownArrow", + load(options?: PowerPoint.Interfaces.TextRangeLoadOptions): PowerPoint.TextRange; /** - * Arrow: Curved Right Arrow with Varying Width - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - swooshArrow = "SwooshArrow", + load(propertyNames?: string | string[]): PowerPoint.TextRange; /** - * Cube - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - cube = "Cube", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TextRange; /** - * Cylinder - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TextRange` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TextRangeData`) that contains shallow copies of any loaded child properties from the original object. */ - can = "Can", + toJSON(): PowerPoint.Interfaces.TextRangeData; + } + /** + * Specifies the type of object that a hyperlink is applied to. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + enum HyperlinkType { /** - * Lightning Bolt + * Specifies that the hyperlink is applied to a TextRange. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - lightningBolt = "LightningBolt", + textRange = "TextRange", /** - * Heart + * Specifies that the hyperlink is applied to a Shape. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - heart = "Heart", + shape = "Shape", + } + /** + * Represents a single hyperlink. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + class Hyperlink extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Sun + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] */ - sun = "Sun", + address: string; /** - * Moon + * Specifies the string displayed when hovering over the hyperlink. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] */ - moon = "Moon", + screenTip: string; /** - * Smiley Face + * Returns the type of object that the hyperlink is applied to. See {@link PowerPoint.HyperlinkType} for details. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - smileyFace = "SmileyFace", + readonly type: PowerPoint.HyperlinkType | "TextRange" | "Shape"; /** - * Explosion: 8 Points + * Deletes the hyperlink. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - irregularSeal1 = "IrregularSeal1", + delete(): void; /** - * Explosion: 14 Points + * Returns the {@link PowerPoint.Shape} object that the hyperlink is applied to. + If the hyperlink is not of type `shape`, or it is within a domain that does not currently support a {@link PowerPoint.Shape}, then this method returns an object with its `isNullObject` property set to `true`. + For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - irregularSeal2 = "IrregularSeal2", + getLinkedShapeOrNullObject(): PowerPoint.Shape; /** - * Rectangle: Folded Corner + * Returns the {@link PowerPoint.TextRange} object that the hyperlink is applied to. + If the hyperlink is not of type `textRange`, or it is within a domain that does not currently support a {@link PowerPoint.TextRange}, then this method returns an object with its `isNullObject` property set to `true`. + For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - foldedCorner = "FoldedCorner", + getLinkedTextRangeOrNullObject(): PowerPoint.TextRange; /** - * Rectangle: Beveled - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - bevel = "Bevel", + load(options?: PowerPoint.Interfaces.HyperlinkLoadOptions): PowerPoint.Hyperlink; /** - * Frame - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - frame = "Frame", + load(propertyNames?: string | string[]): PowerPoint.Hyperlink; /** - * Half Frame - * @remarks - * [Api set: PowerPointApi 1.4] - */ - halfFrame = "HalfFrame", - /** - * L-Shape - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - corner = "Corner", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Hyperlink; /** - * Diagonal Stripe - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.Hyperlink` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkData`) that contains shallow copies of any loaded child properties from the original object. */ - diagonalStripe = "DiagonalStripe", + toJSON(): PowerPoint.Interfaces.HyperlinkData; + } + /** + * Specifies the type of a placeholder. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + enum PlaceholderType { /** - * Chord + * The placeholder is unsupported. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - chord = "Chord", + unsupported = "Unsupported", /** - * Arc + * The placeholder is for a date. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - arc = "Arc", + date = "Date", /** - * Left Bracket + * The placeholder is for a slide number. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - leftBracket = "LeftBracket", + slideNumber = "SlideNumber", /** - * Right Bracket + * The placeholder is for a footer. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - rightBracket = "RightBracket", + footer = "Footer", /** - * Left Brace + * The placeholder is for a header. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - leftBrace = "LeftBrace", + header = "Header", /** - * Right Brace + * The placeholder is for a title. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - rightBrace = "RightBrace", + title = "Title", /** - * Double Bracket + * The placeholder is for a body. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - bracketPair = "BracketPair", + body = "Body", /** - * Double Brace + * The placeholder is for a center title. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - bracePair = "BracePair", + centerTitle = "CenterTitle", /** - * Callout: Line with No Border + * The placeholder is for a subtitle. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - callout1 = "Callout1", + subtitle = "Subtitle", /** - * Callout: Bent Line with No Border + * The placeholder is for a vertical title. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - callout2 = "Callout2", + verticalTitle = "VerticalTitle", /** - * Callout: Double Bent Line with No Border + * The placeholder is for a vertical body. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - callout3 = "Callout3", + verticalBody = "VerticalBody", /** - * Callout: Line with Accent Bar + * The placeholder is for generic content. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - accentCallout1 = "AccentCallout1", + content = "Content", /** - * Callout: Bent Line with Accent Bar + * The placeholder is for a chart. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - accentCallout2 = "AccentCallout2", + chart = "Chart", /** - * Callout: Double Bent Line with Accent Bar + * The placeholder is for a table. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - accentCallout3 = "AccentCallout3", + table = "Table", /** - * Callout: Line + * The placeholder is for an online picture. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - borderCallout1 = "BorderCallout1", + onlinePicture = "OnlinePicture", /** - * Callout: Bent Line + * The placeholder is for a SmartArt. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - borderCallout2 = "BorderCallout2", + smartArt = "SmartArt", /** - * Callout: Double Bent Line + * The placeholder is for media. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - borderCallout3 = "BorderCallout3", + media = "Media", /** - * Callout: Line with Border and Accent Bar + * The placeholder is for generic vertical content. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - accentBorderCallout1 = "AccentBorderCallout1", + verticalContent = "VerticalContent", /** - * Callout: Bent Line with Border and Accent Bar + * The placeholder is for a picture. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - accentBorderCallout2 = "AccentBorderCallout2", + picture = "Picture", /** - * Callout: Double Bent Line with Border and Accent Bar + * The placeholder is for a cameo. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - accentBorderCallout3 = "AccentBorderCallout3", + cameo = "Cameo", + } + /** + * Specifies the type of a shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeType { /** - * Speech Bubble: Rectangle + * The given shape's type is unsupported. * @remarks * [Api set: PowerPointApi 1.4] */ - wedgeRectCallout = "WedgeRectCallout", + unsupported = "Unsupported", /** - * Speech Bubble: Rectangle with Corners Rounded + * The shape is an image. * @remarks * [Api set: PowerPointApi 1.4] */ - wedgeRRectCallout = "WedgeRRectCallout", + image = "Image", /** - * Speech Bubble: Oval + * The shape is a geometric shape such as rectangle. * @remarks * [Api set: PowerPointApi 1.4] */ - wedgeEllipseCallout = "WedgeEllipseCallout", + geometricShape = "GeometricShape", /** - * Thought Bubble: Cloud + * The shape is a group shape which contains sub-shapes. * @remarks * [Api set: PowerPointApi 1.4] */ - cloudCallout = "CloudCallout", + group = "Group", /** - * Cloud + * The shape is a line. * @remarks * [Api set: PowerPointApi 1.4] */ - cloud = "Cloud", + line = "Line", /** - * Ribbon: Tilted Down + * The shape is a table. * @remarks * [Api set: PowerPointApi 1.4] */ - ribbon = "Ribbon", + table = "Table", /** - * Ribbon: Tilted Up + * The shape is a callout. * @remarks * [Api set: PowerPointApi 1.4] */ - ribbon2 = "Ribbon2", + callout = "Callout", /** - * Ribbon: Curved and Tilted Down + * The shape is a chart. * @remarks * [Api set: PowerPointApi 1.4] */ - ellipseRibbon = "EllipseRibbon", + chart = "Chart", /** - * Ribbon: Curved and Tilted Up + * The shape is a content Office Add-in. * @remarks * [Api set: PowerPointApi 1.4] */ - ellipseRibbon2 = "EllipseRibbon2", + contentApp = "ContentApp", /** - * Ribbon: Straight with Both Left and Right Arrows + * The shape is a diagram. * @remarks * [Api set: PowerPointApi 1.4] */ - leftRightRibbon = "LeftRightRibbon", + diagram = "Diagram", /** - * Scroll: Vertical + * The shape is a freeform object. * @remarks * [Api set: PowerPointApi 1.4] */ - verticalScroll = "VerticalScroll", + freeform = "Freeform", /** - * Scroll: Horizontal + * The shape is a graphic. * @remarks * [Api set: PowerPointApi 1.4] */ - horizontalScroll = "HorizontalScroll", + graphic = "Graphic", /** - * Wave + * The shape is an ink object. * @remarks * [Api set: PowerPointApi 1.4] */ - wave = "Wave", + ink = "Ink", /** - * Double Wave + * The shape is a media object. * @remarks * [Api set: PowerPointApi 1.4] */ - doubleWave = "DoubleWave", + media = "Media", /** - * Cross + * The shape is a 3D model. * @remarks * [Api set: PowerPointApi 1.4] */ - plus = "Plus", + model3D = "Model3D", /** - * Flowchart: Process + * The shape is an OLE (Object Linking and Embedding) object. * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartProcess = "FlowChartProcess", + ole = "Ole", /** - * Flowchart: Decision + * The shape is a placeholder. * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartDecision = "FlowChartDecision", + placeholder = "Placeholder", /** - * Flowchart: Data + * The shape is a SmartArt graphic. * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartInputOutput = "FlowChartInputOutput", + smartArt = "SmartArt", /** - * Flowchart: Predefined Process + * The shape is a text box. * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartPredefinedProcess = "FlowChartPredefinedProcess", + textBox = "TextBox", + } + /** + * Represents the properties of a `placeholder` shape. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + class PlaceholderFormat extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Flowchart: Internal Storage + * Gets the type of the shape contained within the placeholder. See {@link PowerPoint.ShapeType} for details. + Returns `null` if the placeholder is empty. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - flowChartInternalStorage = "FlowChartInternalStorage", + readonly containedType: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox" | null; /** - * Flowchart: Document + * Returns the type of this placeholder. See {@link PowerPoint.PlaceholderType} for details. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - flowChartDocument = "FlowChartDocument", + readonly type: PowerPoint.PlaceholderType | "Unsupported" | "Date" | "SlideNumber" | "Footer" | "Header" | "Title" | "Body" | "CenterTitle" | "Subtitle" | "VerticalTitle" | "VerticalBody" | "Content" | "Chart" | "Table" | "OnlinePicture" | "SmartArt" | "Media" | "VerticalContent" | "Picture" | "Cameo"; /** - * Flowchart: Multidocument - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - flowChartMultidocument = "FlowChartMultidocument", + load(options?: PowerPoint.Interfaces.PlaceholderFormatLoadOptions): PowerPoint.PlaceholderFormat; /** - * Flowchart: Terminator - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - flowChartTerminator = "FlowChartTerminator", + load(propertyNames?: string | string[]): PowerPoint.PlaceholderFormat; /** - * Flowchart: Preparation - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - flowChartPreparation = "FlowChartPreparation", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.PlaceholderFormat; /** - * Flowchart: Manual Input - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.PlaceholderFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.PlaceholderFormatData`) that contains shallow copies of any loaded child properties from the original object. */ - flowChartManualInput = "FlowChartManualInput", + toJSON(): PowerPoint.Interfaces.PlaceholderFormatData; + } + /** + * Represents a collection of hyperlinks. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + class HyperlinkCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.Hyperlink[]; /** - * Flowchart: Manual Operation + * Adds a hyperlink to the specified target with the given options. If the target already contains any hyperlinks, they will be deleted. + The new hyperlink may appear anywhere in the collection and is not guaranteed to be added at the end. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param target The target to add the hyperlink to. Can be a {@link PowerPoint.TextRange} or a {@link PowerPoint.Shape}. + * @param options Optional. The options for the hyperlink. + * @returns The newly created {@link PowerPoint.Hyperlink} object. */ - flowChartManualOperation = "FlowChartManualOperation", + add(target: TextRange | Shape, options?: PowerPoint.HyperlinkAddOptions): PowerPoint.Hyperlink; /** - * Flowchart: Connector + * Gets the number of hyperlinks in the collection. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] + * @returns The number of hyperlinks in the collection. */ - flowChartConnector = "FlowChartConnector", + getCount(): OfficeExtension.ClientResult; /** - * Flowchart: Card + * Gets a hyperlink using its zero-based index in the collection. An error is thrown if the index is out of range. + Throws an `InvalidArgument` exception when the index is out of range. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] + * + * @param index The index of the hyperlink in the collection. + * @returns The hyperlink at the given index. */ - flowChartPunchedCard = "FlowChartPunchedCard", + getItemAt(index: number): PowerPoint.Hyperlink; /** - * Flowchart: Punched Tape - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - flowChartPunchedTape = "FlowChartPunchedTape", + load(options?: PowerPoint.Interfaces.HyperlinkCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.HyperlinkCollection; /** - * Flowchart: Summing Junction - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - flowChartSummingJunction = "FlowChartSummingJunction", + load(propertyNames?: string | string[]): PowerPoint.HyperlinkCollection; /** - * Flowchart: Or - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - flowChartOr = "FlowChartOr", + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.HyperlinkCollection; /** - * Flowchart: Collate - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.HyperlinkCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - flowChartCollate = "FlowChartCollate", + toJSON(): PowerPoint.Interfaces.HyperlinkCollectionData; + } + /** + * Specifies the connector type for line shapes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ConnectorType { /** - * Flowchart: Sort + * Straight connector type * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartSort = "FlowChartSort", + straight = "Straight", /** - * Flowchart: Extract + * Elbow connector type * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartExtract = "FlowChartExtract", + elbow = "Elbow", /** - * Flowchart: Merge + * Curve connector type * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMerge = "FlowChartMerge", + curve = "Curve", + } + /** + * Specifies the shape type for a `GeometricShape` object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum GeometricShapeType { /** - * FlowChart: Offline Storage + * Straight Line from Top-Right Corner to Bottom-Left Corner of the Shape * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartOfflineStorage = "FlowChartOfflineStorage", + lineInverse = "LineInverse", /** - * Flowchart: Stored Data + * Isosceles Triangle * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartOnlineStorage = "FlowChartOnlineStorage", + triangle = "Triangle", /** - * Flowchart: Sequential Access Storage + * Right Triangle * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMagneticTape = "FlowChartMagneticTape", + rightTriangle = "RightTriangle", /** - * Flowchart: Magnetic Disk + * Rectangle * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMagneticDisk = "FlowChartMagneticDisk", + rectangle = "Rectangle", /** - * Flowchart: Direct Access Storage + * Diamond * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMagneticDrum = "FlowChartMagneticDrum", + diamond = "Diamond", /** - * Flowchart: Display + * Parallelogram * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartDisplay = "FlowChartDisplay", + parallelogram = "Parallelogram", /** - * Flowchart: Delay + * Trapezoid * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartDelay = "FlowChartDelay", + trapezoid = "Trapezoid", /** - * Flowchart: Alternate Process + * Trapezoid which may have Non-Equal Sides * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartAlternateProcess = "FlowChartAlternateProcess", + nonIsoscelesTrapezoid = "NonIsoscelesTrapezoid", /** - * Flowchart: Off-page Connector + * Pentagon * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartOffpageConnector = "FlowChartOffpageConnector", + pentagon = "Pentagon", /** - * Action Button: Blank + * Hexagon * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonBlank = "ActionButtonBlank", + hexagon = "Hexagon", /** - * Action Button: Go Home + * Heptagon * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonHome = "ActionButtonHome", + heptagon = "Heptagon", /** - * Action Button: Help + * Octagon * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonHelp = "ActionButtonHelp", + octagon = "Octagon", /** - * Action Button: Get Information + * Decagon * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonInformation = "ActionButtonInformation", + decagon = "Decagon", /** - * Action Button: Go Forward or Next + * Dodecagon * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonForwardNext = "ActionButtonForwardNext", + dodecagon = "Dodecagon", /** - * Action Button: Go Back or Previous + * Star: 4 Points * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonBackPrevious = "ActionButtonBackPrevious", + star4 = "Star4", /** - * Action Button: Go to End + * Star: 5 Points * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonEnd = "ActionButtonEnd", + star5 = "Star5", /** - * Action Button: Go to Beginning + * Star: 6 Points * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonBeginning = "ActionButtonBeginning", + star6 = "Star6", /** - * Action Button: Return + * Star: 7 Points * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonReturn = "ActionButtonReturn", + star7 = "Star7", /** - * Action Button: Document + * Star: 8 Points * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonDocument = "ActionButtonDocument", + star8 = "Star8", /** - * Action Button: Sound + * Star: 10 Points * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonSound = "ActionButtonSound", + star10 = "Star10", /** - * Action Button: Video + * Star: 12 Points * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonMovie = "ActionButtonMovie", + star12 = "Star12", /** - * Gear: A Gear with Six Teeth + * Star: 16 Points * @remarks * [Api set: PowerPointApi 1.4] */ - gear6 = "Gear6", + star16 = "Star16", /** - * Gear: A Gear with Nine Teeth + * Star: 24 Points * @remarks * [Api set: PowerPointApi 1.4] */ - gear9 = "Gear9", + star24 = "Star24", /** - * Funnel + * Star: 32 Points * @remarks * [Api set: PowerPointApi 1.4] */ - funnel = "Funnel", + star32 = "Star32", /** - * Plus Sign + * Rectangle: Rounded Corners * @remarks * [Api set: PowerPointApi 1.4] */ - mathPlus = "MathPlus", + roundRectangle = "RoundRectangle", /** - * Minus Sign + * Rectangle: Single Corner Rounded * @remarks * [Api set: PowerPointApi 1.4] */ - mathMinus = "MathMinus", + round1Rectangle = "Round1Rectangle", /** - * Multiplication Sign + * Rectangle: Top Corners Rounded * @remarks * [Api set: PowerPointApi 1.4] */ - mathMultiply = "MathMultiply", + round2SameRectangle = "Round2SameRectangle", /** - * Division Sign + * Rectangle: Diagonal Corners Rounded * @remarks * [Api set: PowerPointApi 1.4] */ - mathDivide = "MathDivide", + round2DiagonalRectangle = "Round2DiagonalRectangle", /** - * Equals + * Rectangle: Top Corners One Rounded and One Snipped * @remarks * [Api set: PowerPointApi 1.4] */ - mathEqual = "MathEqual", + snipRoundRectangle = "SnipRoundRectangle", /** - * Not Equal + * Rectangle: Single Corner Snipped * @remarks * [Api set: PowerPointApi 1.4] */ - mathNotEqual = "MathNotEqual", + snip1Rectangle = "Snip1Rectangle", /** - * Four Right Triangles that Define a Rectangular Shape + * Rectangle: Top Corners Snipped * @remarks * [Api set: PowerPointApi 1.4] */ - cornerTabs = "CornerTabs", + snip2SameRectangle = "Snip2SameRectangle", /** - * Four Small Squares that Define a Rectangular Shape. + * Rectangle: Diagonal Corners Snipped * @remarks * [Api set: PowerPointApi 1.4] */ - squareTabs = "SquareTabs", + snip2DiagonalRectangle = "Snip2DiagonalRectangle", /** - * Four Quarter Circles that Define a Rectangular Shape. + * Plaque * @remarks * [Api set: PowerPointApi 1.4] */ - plaqueTabs = "PlaqueTabs", + plaque = "Plaque", /** - * A Rectangle Divided into Four Parts Along Diagonal Lines. + * Oval * @remarks * [Api set: PowerPointApi 1.4] */ - chartX = "ChartX", + ellipse = "Ellipse", /** - * A Rectangle Divided into Six Parts Along a Vertical Line and Diagonal Lines. + * Teardrop * @remarks * [Api set: PowerPointApi 1.4] */ - chartStar = "ChartStar", + teardrop = "Teardrop", /** - * A Rectangle Divided Vertically and Horizontally into Four Quarters. + * Arrow: Pentagon * @remarks * [Api set: PowerPointApi 1.4] */ - chartPlus = "ChartPlus", - } - /** - * Represents the available options when adding shapes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface ShapeAddOptions { + homePlate = "HomePlate", /** - * Specifies the height, in points, of the shape. - When not provided, a default value will be used. - Throws an `InvalidArgument` exception when set with a negative value. - * + * Arrow: Chevron * @remarks * [Api set: PowerPointApi 1.4] */ - height?: number; + chevron = "Chevron", /** - * Specifies the distance, in points, from the left side of the shape to the left side of the slide. - When not provided, a default value will be used. - * + * Partial Circle * @remarks * [Api set: PowerPointApi 1.4] */ - left?: number; + pieWedge = "PieWedge", /** - * Specifies the distance, in points, from the top edge of the shape to the top edge of the slide. - When not provided, a default value will be used. - * + * Partial Circle with Adjustable Spanning Area * @remarks * [Api set: PowerPointApi 1.4] */ - top?: number; + pie = "Pie", /** - * Specifies the width, in points, of the shape. - When not provided, a default value will be used. - Throws an `InvalidArgument` exception when set with a negative value. - * + * Block Arc * @remarks * [Api set: PowerPointApi 1.4] */ - width?: number; - } - /** - * Specifies the dash style for a line. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ShapeLineDashStyle { + blockArc = "BlockArc", /** - * The dash line pattern. + * Circle: Hollow * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + donut = "Donut", /** - * The dash-dot line pattern. + * "Not Allowed" Symbol * @remarks * [Api set: PowerPointApi 1.4] */ - dashDot = "DashDot", + noSmoking = "NoSmoking", /** - * The dash-dot-dot line pattern. + * Arrow: Right * @remarks * [Api set: PowerPointApi 1.4] */ - dashDotDot = "DashDotDot", + rightArrow = "RightArrow", /** - * The long dash line pattern. + * Arrow: Left * @remarks * [Api set: PowerPointApi 1.4] */ - longDash = "LongDash", + leftArrow = "LeftArrow", /** - * The long dash-dot line pattern. + * Arrow: Up * @remarks * [Api set: PowerPointApi 1.4] */ - longDashDot = "LongDashDot", + upArrow = "UpArrow", /** - * The round dot line pattern. + * Arrow: Down * @remarks * [Api set: PowerPointApi 1.4] */ - roundDot = "RoundDot", + downArrow = "DownArrow", /** - * The solid line pattern. + * Arrow: Striped Right * @remarks * [Api set: PowerPointApi 1.4] */ - solid = "Solid", + stripedRightArrow = "StripedRightArrow", /** - * The square dot line pattern. + * Arrow: Notched Right * @remarks * [Api set: PowerPointApi 1.4] */ - squareDot = "SquareDot", + notchedRightArrow = "NotchedRightArrow", /** - * The long dash-dot-dot line pattern. + * Arrow: Bent-Up * @remarks * [Api set: PowerPointApi 1.4] */ - longDashDotDot = "LongDashDotDot", + bentUpArrow = "BentUpArrow", /** - * The system dash line pattern. + * Arrow: Left-Right * @remarks * [Api set: PowerPointApi 1.4] */ - systemDash = "SystemDash", + leftRightArrow = "LeftRightArrow", /** - * The system dot line pattern. + * Arrow: Up-Down * @remarks * [Api set: PowerPointApi 1.4] */ - systemDot = "SystemDot", + upDownArrow = "UpDownArrow", /** - * The system dash-dot line pattern. + * Arrow: Left-Up * @remarks * [Api set: PowerPointApi 1.4] */ - systemDashDot = "SystemDashDot", - } - /** - * Represents the properties for a table cell border. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class Border extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + leftUpArrow = "LeftUpArrow", /** - * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). - * + * Arrow: Left-Right-Up * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - color: string | undefined; + leftRightUpArrow = "LeftRightUpArrow", /** - * Represents the dash style of the line. - * + * Arrow: Quad * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - dashStyle: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; + quadArrow = "QuadArrow", /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). - * + * Callout: Left Arrow * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - transparency: number | undefined; + leftArrowCallout = "LeftArrowCallout", /** - * Represents the weight of the line, in points. - * + * Callout: Right Arrow * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - weight: number | undefined; + rightArrowCallout = "RightArrowCallout", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Callout: Up Arrow + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(options?: PowerPoint.Interfaces.BorderLoadOptions): PowerPoint.Border; + upArrowCallout = "UpArrowCallout", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Callout: Down Arrow + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.Border; + downArrowCallout = "DownArrowCallout", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Callout: Left-Right Arrow + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Border; + leftRightArrowCallout = "LeftRightArrowCallout", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Border` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BorderData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.BorderData; - } - /** - * Represents the borders for a table cell. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class Borders extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + * Callout: Up-Down Arrow + * @remarks + * [Api set: PowerPointApi 1.4] + */ + upDownArrowCallout = "UpDownArrowCallout", /** - * Gets the bottom border. - * + * Callout: Quad Arrow * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly bottom: PowerPoint.Border; + quadArrowCallout = "QuadArrowCallout", /** - * Gets the diagonal border (top-left to bottom-right). - * + * Arrow: Bent * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly diagonalDown: PowerPoint.Border; + bentArrow = "BentArrow", /** - * Gets the diagonal border (bottom-left to top-right). - * + * Arrow: U-Turn * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly diagonalUp: PowerPoint.Border; + uturnArrow = "UturnArrow", /** - * Gets the left border. - * + * Arrow: Circular * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly left: PowerPoint.Border; + circularArrow = "CircularArrow", /** - * Gets the right border. - * + * Arrow: Circular with Opposite Arrow Direction * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly right: PowerPoint.Border; + leftCircularArrow = "LeftCircularArrow", /** - * Gets the top border. - * + * Arrow: Circular with Two Arrows in Both Directions * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly top: PowerPoint.Border; + leftRightCircularArrow = "LeftRightCircularArrow", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Arrow: Curved Right + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(options?: PowerPoint.Interfaces.BordersLoadOptions): PowerPoint.Borders; + curvedRightArrow = "CurvedRightArrow", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Arrow: Curved Left + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.Borders; + curvedLeftArrow = "CurvedLeftArrow", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Arrow: Curved Up + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Borders; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Borders` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BordersData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.BordersData; - } - /** - * Represents the margins of a table cell. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class Margins extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + curvedUpArrow = "CurvedUpArrow", /** - * Specifies the bottom margin in points. - * + * Arrow: Curved Down * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - bottom: number | undefined; + curvedDownArrow = "CurvedDownArrow", /** - * Specifies the left margin in points. - * + * Arrow: Curved Right Arrow with Varying Width * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - left: number | undefined; + swooshArrow = "SwooshArrow", /** - * Specifies the right margin in points. - * + * Cube * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - right: number | undefined; + cube = "Cube", /** - * Specifies the top margin in points. - * + * Cylinder * @remarks - * [Api set: PowerPointApi 1.9] - */ - top: number | undefined; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.MarginsLoadOptions): PowerPoint.Margins; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.Margins; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Margins; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Margins` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.MarginsData`) that contains shallow copies of any loaded child properties from the original object. + * [Api set: PowerPointApi 1.4] */ - toJSON(): PowerPoint.Interfaces.MarginsData; - } - /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ParagraphHorizontalAlignment { + can = "Can", /** - * Align text to the left margin. + * Lightning Bolt * @remarks * [Api set: PowerPointApi 1.4] */ - left = "Left", + lightningBolt = "LightningBolt", /** - * Align text in the center. + * Heart * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + heart = "Heart", /** - * Align text to the right margin. + * Sun * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + sun = "Sun", /** - * Align text so that it's justified across the whole line. + * Moon * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + moon = "Moon", /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * Smiley Face * @remarks * [Api set: PowerPointApi 1.4] */ - justifyLow = "JustifyLow", + smileyFace = "SmileyFace", /** - * Distributes the text words across an entire text line. + * Explosion: 8 Points * @remarks * [Api set: PowerPointApi 1.4] */ - distributed = "Distributed", + irregularSeal1 = "IrregularSeal1", /** - * Distributes Thai text specially, because each character is treated as a word. + * Explosion: 14 Points * @remarks * [Api set: PowerPointApi 1.4] */ - thaiDistributed = "ThaiDistributed", - } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ShapeFillType { + irregularSeal2 = "IrregularSeal2", /** - * Specifies that the shape should have no fill. + * Rectangle: Folded Corner * @remarks * [Api set: PowerPointApi 1.4] */ - noFill = "NoFill", + foldedCorner = "FoldedCorner", /** - * Specifies that the shape should have regular solid fill. + * Rectangle: Beveled * @remarks * [Api set: PowerPointApi 1.4] */ - solid = "Solid", + bevel = "Bevel", /** - * Specifies that the shape should have gradient fill. + * Frame * @remarks * [Api set: PowerPointApi 1.4] */ - gradient = "Gradient", + frame = "Frame", /** - * Specifies that the shape should have pattern fill. + * Half Frame * @remarks * [Api set: PowerPointApi 1.4] */ - pattern = "Pattern", + halfFrame = "HalfFrame", /** - * Specifies that the shape should have picture or texture fill. + * L-Shape * @remarks * [Api set: PowerPointApi 1.4] */ - pictureAndTexture = "PictureAndTexture", + corner = "Corner", /** - * Specifies that the shape should have slide background fill. + * Diagonal Stripe * @remarks * [Api set: PowerPointApi 1.4] */ - slideBackground = "SlideBackground", - } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - class ShapeFill extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + diagonalStripe = "DiagonalStripe", /** - * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). - * + * Chord * @remarks * [Api set: PowerPointApi 1.4] */ - foregroundColor: string; + chord = "Chord", /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. - * + * Arc * @remarks * [Api set: PowerPointApi 1.4] */ - transparency: number; + arc = "Arc", /** - * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. - * + * Left Bracket * @remarks * [Api set: PowerPointApi 1.4] */ - readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; + leftBracket = "LeftBracket", /** - * Clears the fill formatting of this shape. - * + * Right Bracket * @remarks * [Api set: PowerPointApi 1.4] */ - clear(): void; + rightBracket = "RightBracket", /** - * Sets the fill formatting of the shape to an image. This changes the fill type to `PictureAndTexture`. - * + * Left Brace * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param base64EncodedImage A string that is a Base64 encoding of the image data. + * [Api set: PowerPointApi 1.4] */ - setImage(base64EncodedImage: string): void; + leftBrace = "LeftBrace", /** - * Sets the fill formatting of the shape to a uniform color. This changes the fill type to `Solid`. - * + * Right Brace * @remarks * [Api set: PowerPointApi 1.4] - * - * @param color A string that specifies the fill color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). - */ - setSolidColor(color: string): void; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.ShapeFill; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.ShapeFill; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ShapeFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeFillData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.ShapeFillData; - } - /** - * The type of underline applied to a font. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ShapeFontUnderlineStyle { + rightBrace = "RightBrace", /** - * No underlining. + * Double Bracket * @remarks * [Api set: PowerPointApi 1.4] */ - none = "None", + bracketPair = "BracketPair", /** - * Regular single line underlining. + * Double Brace * @remarks * [Api set: PowerPointApi 1.4] */ - single = "Single", + bracePair = "BracePair", /** - * Underlining of text with double lines. + * Callout: Line with No Border * @remarks * [Api set: PowerPointApi 1.4] */ - double = "Double", + callout1 = "Callout1", /** - * Underlining of text with a thick line. + * Callout: Bent Line with No Border * @remarks * [Api set: PowerPointApi 1.4] */ - heavy = "Heavy", + callout2 = "Callout2", /** - * Underlining of text with a dotted line. + * Callout: Double Bent Line with No Border * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + callout3 = "Callout3", /** - * Underlining of text with a thick, dotted line. + * Callout: Line with Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + accentCallout1 = "AccentCallout1", /** - * Underlining of text with a line containing dashes. + * Callout: Bent Line with Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + accentCallout2 = "AccentCallout2", /** - * Underlining of text with a thick line containing dashes. + * Callout: Double Bent Line with Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + accentCallout3 = "AccentCallout3", /** - * Underlining of text with a line containing long dashes. + * Callout: Line * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + borderCallout1 = "BorderCallout1", /** - * Underlining of text with a thick line containing long dashes. + * Callout: Bent Line * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + borderCallout2 = "BorderCallout2", /** - * Underlining of text with a line containing dots and dashes. + * Callout: Double Bent Line * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + borderCallout3 = "BorderCallout3", /** - * Underlining of text with a thick line containing dots and dashes. + * Callout: Line with Border and Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + accentBorderCallout1 = "AccentBorderCallout1", /** - * Underlining of text with a line containing double dots and dashes. + * Callout: Bent Line with Border and Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + accentBorderCallout2 = "AccentBorderCallout2", /** - * Underlining of text with a thick line containing double dots and dashes. + * Callout: Double Bent Line with Border and Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + accentBorderCallout3 = "AccentBorderCallout3", /** - * Underlining of text with a wavy line. + * Speech Bubble: Rectangle * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + wedgeRectCallout = "WedgeRectCallout", /** - * Underlining of text with a thick, wavy line. + * Speech Bubble: Rectangle with Corners Rounded * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + wedgeRRectCallout = "WedgeRRectCallout", /** - * Underlining of text with double wavy lines. + * Speech Bubble: Oval * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", - } - /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - class ShapeFont extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + wedgeEllipseCallout = "WedgeEllipseCallout", /** - * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: - - - `true`: All the text has the **All Caps** attribute. - - - `false`: None of the text has the **All Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. - * + * Thought Bubble: Cloud * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - allCaps: boolean | null; + cloudCallout = "CloudCallout", /** - * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: - - - `true`: All the text is bold. - - - `false`: None of the text is bold. - - - `null`: Returned if some, but not all, of the text is bold. - * + * Cloud * @remarks * [Api set: PowerPointApi 1.4] */ - bold: boolean | null; + cloud = "Cloud", /** - * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. - * + * Ribbon: Tilted Down * @remarks * [Api set: PowerPointApi 1.4] */ - color: string | null; + ribbon = "Ribbon", /** - * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Double strikethrough** attribute. - - - `false`: None of the text has the **Double strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. - * + * Ribbon: Tilted Up * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - doubleStrikethrough: boolean | null; + ribbon2 = "Ribbon2", /** - * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: - - - `true`: All the text is italicized. - - - `false`: None of the text is italicized. - - - `null`: Returned if some, but not all, of the text is italicized. - * + * Ribbon: Curved and Tilted Down * @remarks * [Api set: PowerPointApi 1.4] */ - italic: boolean | null; + ellipseRibbon = "EllipseRibbon", /** - * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. - * + * Ribbon: Curved and Tilted Up * @remarks * [Api set: PowerPointApi 1.4] */ - name: string | null; + ellipseRibbon2 = "EllipseRibbon2", /** - * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. - * + * Ribbon: Straight with Both Left and Right Arrows * @remarks * [Api set: PowerPointApi 1.4] */ - size: number | null; + leftRightRibbon = "LeftRightRibbon", /** - * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: - - - `true`: All the text has the **Small Caps** attribute. - - - `false`: None of the text has the **Small Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. - * + * Scroll: Vertical * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - smallCaps: boolean | null; + verticalScroll = "VerticalScroll", /** - * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Strikethrough** attribute. - - - `false`: None of the text has the **Strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. - * + * Scroll: Horizontal * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - strikethrough: boolean | null; + horizontalScroll = "HorizontalScroll", /** - * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Subscript** attribute. - - - `false`: None of the text has the **Subscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. - * + * Wave * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subscript: boolean | null; + wave = "Wave", /** - * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Superscript** attribute. - - - `false`: None of the text has the **Superscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. - * + * Double Wave * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - superscript: boolean | null; + doubleWave = "DoubleWave", /** - * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * + * Cross * @remarks * [Api set: PowerPointApi 1.4] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; + plus = "Plus", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Flowchart: Process + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(options?: PowerPoint.Interfaces.ShapeFontLoadOptions): PowerPoint.ShapeFont; + flowChartProcess = "FlowChartProcess", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Flowchart: Decision + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.ShapeFont; + flowChartDecision = "FlowChartDecision", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Flowchart: Data + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.ShapeFont; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ShapeFont` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeFontData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.ShapeFontData; - } - /** - * Represents the font attributes, such as font name, size, and color. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface FontProperties { + flowChartInputOutput = "FlowChartInputOutput", /** - * Represents whether the font uses all caps, where lowercase letters are shown as capital letters. - * + * Flowchart: Predefined Process * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - allCaps?: boolean | undefined; + flowChartPredefinedProcess = "FlowChartPredefinedProcess", /** - * Represents the bold status of font. - * + * Flowchart: Internal Storage * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - bold?: boolean | undefined; + flowChartInternalStorage = "FlowChartInternalStorage", /** - * Represents the HTML color in the hexadecimal format (e.g., "#FF0000" represents red) or as a named HTML color value (e.g., "red"). - * + * Flowchart: Document * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - color?: string | undefined; + flowChartDocument = "FlowChartDocument", /** - * Represents the double-strikethrough status of the font. - * + * Flowchart: Multidocument * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - doubleStrikethrough?: boolean | undefined; + flowChartMultidocument = "FlowChartMultidocument", /** - * Represents the italic status of font. - * + * Flowchart: Terminator * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - italic?: boolean | undefined; + flowChartTerminator = "FlowChartTerminator", /** - * Represents the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. - * + * Flowchart: Preparation * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - name?: string | undefined; + flowChartPreparation = "FlowChartPreparation", /** - * Represents the font size in points (e.g., 11). - * + * Flowchart: Manual Input * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - size?: number | undefined; + flowChartManualInput = "FlowChartManualInput", /** - * Represents whether the text uses small caps, where lowercase letters are shown as small capital letters. - * + * Flowchart: Manual Operation * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - smallCaps?: boolean | undefined; + flowChartManualOperation = "FlowChartManualOperation", /** - * Represents the strikethrough status of the font. - * + * Flowchart: Connector * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - strikethrough?: boolean | undefined; + flowChartConnector = "FlowChartConnector", /** - * Represents the subscript status of the font. - * + * Flowchart: Card * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subscript?: boolean | undefined; + flowChartPunchedCard = "FlowChartPunchedCard", /** - * Represents the superscript status of the font. - * + * Flowchart: Punched Tape * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - superscript?: boolean | undefined; + flowChartPunchedTape = "FlowChartPunchedTape", /** - * Type of underline applied to the font. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * + * Flowchart: Summing Junction * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | undefined; - } - /** - * Represents a sequence of one or more characters with the same font attributes. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TextRun { + flowChartSummingJunction = "FlowChartSummingJunction", /** - * The font attributes (such as font name, font size, and color) applied to this text run. - * + * Flowchart: Or * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - font?: PowerPoint.FontProperties; + flowChartOr = "FlowChartOr", /** - * The text of this text run. - * + * Flowchart: Collate * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - text: string; - } - /** - * Represents the vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. - If one of the centered options is selected, the contents of the `TextFrame` will be centered horizontally within the `Shape` as a group. - To change the horizontal alignment of a text, see {@link PowerPoint.ParagraphFormat} and {@link PowerPoint.ParagraphHorizontalAlignment}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum TextVerticalAlignment { + flowChartCollate = "FlowChartCollate", /** - * Specifies that the `TextFrame` should be top aligned to the `Shape`. + * Flowchart: Sort * @remarks * [Api set: PowerPointApi 1.4] */ - top = "Top", + flowChartSort = "FlowChartSort", /** - * Specifies that the `TextFrame` should be center aligned to the `Shape`. + * Flowchart: Extract * @remarks * [Api set: PowerPointApi 1.4] */ - middle = "Middle", + flowChartExtract = "FlowChartExtract", /** - * Specifies that the `TextFrame` should be bottom aligned to the `Shape`. + * Flowchart: Merge * @remarks * [Api set: PowerPointApi 1.4] */ - bottom = "Bottom", + flowChartMerge = "FlowChartMerge", /** - * Specifies that the `TextFrame` should be top aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. + * FlowChart: Offline Storage * @remarks * [Api set: PowerPointApi 1.4] */ - topCentered = "TopCentered", + flowChartOfflineStorage = "FlowChartOfflineStorage", /** - * Specifies that the `TextFrame` should be center aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. + * Flowchart: Stored Data * @remarks * [Api set: PowerPointApi 1.4] */ - middleCentered = "MiddleCentered", + flowChartOnlineStorage = "FlowChartOnlineStorage", /** - * Specifies that the `TextFrame` should be bottom aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. + * Flowchart: Sequential Access Storage * @remarks * [Api set: PowerPointApi 1.4] */ - bottomCentered = "BottomCentered", - } - /** - * Represents a table. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - class TableCell extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + flowChartMagneticTape = "FlowChartMagneticTape", /** - * Gets the collection of borders for the table cell. - * + * Flowchart: Magnetic Disk * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly borders: PowerPoint.Borders; + flowChartMagneticDisk = "FlowChartMagneticDisk", /** - * Gets the fill color of the table cell. - * + * Flowchart: Direct Access Storage * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly fill: PowerPoint.ShapeFill; + flowChartMagneticDrum = "FlowChartMagneticDrum", /** - * Gets the font of the table cell. - * + * Flowchart: Display * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly font: PowerPoint.ShapeFont; + flowChartDisplay = "FlowChartDisplay", /** - * Gets the set of margins in the table cell. - * + * Flowchart: Delay * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly margins: PowerPoint.Margins; + flowChartDelay = "FlowChartDelay", /** - * Gets the number of table columns this cell spans across. - Will be greater than or equal to 1. - * + * Flowchart: Alternate Process * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - readonly columnCount: number; + flowChartAlternateProcess = "FlowChartAlternateProcess", /** - * Gets the zero-based column index of the cell within the table. - * + * Flowchart: Off-page Connector * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - readonly columnIndex: number; + flowChartOffpageConnector = "FlowChartOffpageConnector", /** - * Specifies the horizontal alignment of the text in the table cell. Returns `null` if the cell text contains different alignments. - * + * Action Button: Blank * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + actionButtonBlank = "ActionButtonBlank", /** - * Specifies the indent level of the text in the table cell. Returns `null` if the cell text contains different indent levels. - * + * Action Button: Go Home * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - indentLevel: number | null; + actionButtonHome = "ActionButtonHome", /** - * Gets the number of table rows this cell spans across. - Will be greater than or equal to 1. - * + * Action Button: Help * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - readonly rowCount: number; + actionButtonHelp = "ActionButtonHelp", /** - * Gets the zero-based row index of the cell within the table. - * + * Action Button: Get Information * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - readonly rowIndex: number; + actionButtonInformation = "ActionButtonInformation", /** - * Specifies the text content of the table cell. - * + * Action Button: Go Forward or Next * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - text: string; + actionButtonForwardNext = "ActionButtonForwardNext", /** - * Specifies the contents of the table cell as an array of {@link PowerPoint.TextRun} objects. - Each `TextRun` object represents a sequence of one or more characters that share the same font attributes. - * + * Action Button: Go Back or Previous * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - textRuns: PowerPoint.TextRun[]; + actionButtonBackPrevious = "ActionButtonBackPrevious", /** - * Specifies the vertical alignment of the text in the table cell. - * + * Action Button: Go to End * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - verticalAlignment: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + actionButtonEnd = "ActionButtonEnd", /** - * Resizes the table cell to span across a specified number of rows and columns. - If rowCount or columnCount are greater than 1, the cell will become a merged area. If the cell - is already a merged area and rowCount and columnCount are set to 1, the cell will no longer be - a merged area. - * + * Action Button: Go to Beginning * @remarks - * [Api set: PowerPointApi 1.9] - * - * @param rowCount The number of rows the cell will span across. Must be greater than 0. - * @param columnCount The number of columns the cell will span across. Must be greater than 0. + * [Api set: PowerPointApi 1.4] */ - resize(rowCount: number, columnCount: number): void; + actionButtonBeginning = "ActionButtonBeginning", /** - * Splits the cell into the specified number of rows and columns. - * + * Action Button: Return * @remarks - * [Api set: PowerPointApi 1.9] - * - * @param rowCount The number of rows to split into. Must be greater than 0. - * @param columnCount The number of columns to split into. Must be greater than 0. + * [Api set: PowerPointApi 1.4] */ - split(rowCount: number, columnCount: number): void; + actionButtonReturn = "ActionButtonReturn", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Action Button: Document + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(options?: PowerPoint.Interfaces.TableCellLoadOptions): PowerPoint.TableCell; + actionButtonDocument = "ActionButtonDocument", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Action Button: Sound + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.TableCell; + actionButtonSound = "ActionButtonSound", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Action Button: Video + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.TableCell; + actionButtonMovie = "ActionButtonMovie", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableCell` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableCellData`) that contains shallow copies of any loaded child properties from the original object. + * Gear: A Gear with Six Teeth + * @remarks + * [Api set: PowerPointApi 1.4] */ - toJSON(): PowerPoint.Interfaces.TableCellData; - } - /** - * Represents a collection of table cells. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - class TableCellCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.TableCell[]; + gear6 = "Gear6", /** - * Gets the number of table cells in the collection. - * + * Gear: A Gear with Nine Teeth * @remarks - * [Api set: PowerPointApi 1.8] - * @returns The number of table cells in the collection. + * [Api set: PowerPointApi 1.4] */ - getCount(): OfficeExtension.ClientResult; + gear9 = "Gear9", /** - * Gets the table cell using its zero-based index in the collection. If the `TableCell` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. - * + * Funnel * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param row Row index value of the table cell to be retrieved, as a zero-based index. - * @param column Column index value of the table cell to be retrieved, as a zero-based index. - * @returns The `TableCell` object. + * [Api set: PowerPointApi 1.4] */ - getItemAtOrNullObject(row: number, column: number): PowerPoint.TableCell; + funnel = "Funnel", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.TableCellCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableCellCollection; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Plus Sign + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.TableCellCollection; + mathPlus = "MathPlus", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Minus Sign + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableCellCollection; + mathMinus = "MathMinus", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableCellCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableCellCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Multiplication Sign + * @remarks + * [Api set: PowerPointApi 1.4] */ - toJSON(): PowerPoint.Interfaces.TableCellCollectionData; - } - /** - * Represents a column in a table. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class TableColumn extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + mathMultiply = "MathMultiply", /** - * Returns the index number of the column within the column collection of the table. Zero-indexed. - * + * Division Sign * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly columnIndex: number; + mathDivide = "MathDivide", /** - * Retrieves the width of the column in points. If the set column width is less than the minimum width, the column width will be increased to the minimum width. - * + * Equals * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - width: number; + mathEqual = "MathEqual", /** - * Deletes the column. - * + * Not Equal * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - delete(): void; + mathNotEqual = "MathNotEqual", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Four Right Triangles that Define a Rectangular Shape + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(options?: PowerPoint.Interfaces.TableColumnLoadOptions): PowerPoint.TableColumn; + cornerTabs = "CornerTabs", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Four Small Squares that Define a Rectangular Shape. + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.TableColumn; + squareTabs = "SquareTabs", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Four Quarter Circles that Define a Rectangular Shape. + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.TableColumn; + plaqueTabs = "PlaqueTabs", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableColumn` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableColumnData`) that contains shallow copies of any loaded child properties from the original object. + * A Rectangle Divided into Four Parts Along Diagonal Lines. + * @remarks + * [Api set: PowerPointApi 1.4] */ - toJSON(): PowerPoint.Interfaces.TableColumnData; - } - /** - * Represents the fill formatting of a table cell. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface FillProperties { + chartX = "ChartX", /** - * Represents the shape fill color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). - * + * A Rectangle Divided into Six Parts Along a Vertical Line and Diagonal Lines. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - color?: string | undefined; + chartStar = "ChartStar", /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). - * + * A Rectangle Divided Vertically and Horizontally into Four Quarters. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - transparency?: number | undefined; + chartPlus = "ChartPlus", } /** - * Represents the properties for a table cell border. + * Represents the available options when adding shapes. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - interface BorderProperties { + interface ShapeAddOptions { /** - * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). + * Specifies the height, in points, of the shape. + When not provided, a default value will be used. + Throws an `InvalidArgument` exception when set with a negative value. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - color?: string | undefined; + height?: number; /** - * Represents the dash style of the line. + * Specifies the distance, in points, from the left side of the shape to the left side of the slide. + When not provided, a default value will be used. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; + left?: number; /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). + * Specifies the distance, in points, from the top edge of the shape to the top edge of the slide. + When not provided, a default value will be used. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - transparency?: number | undefined; + top?: number; /** - * Represents the weight of the line, in points. + * Specifies the width, in points, of the shape. + When not provided, a default value will be used. + Throws an `InvalidArgument` exception when set with a negative value. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - weight?: number | undefined; + width?: number; } /** - * Represents the borders of a table cell. + * Specifies the dash style for a line. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - interface TableCellBorders { + enum ShapeLineDashStyle { /** - * Represents the bottom border. - * + * The dash line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - bottom?: PowerPoint.BorderProperties; + dash = "Dash", /** - * Represents the diagonal border (top-left to bottom-right). - * + * The dash-dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - diagonalDown?: PowerPoint.BorderProperties; + dashDot = "DashDot", /** - * Represents the diagonal border (bottom-left to top-right). - * + * The dash-dot-dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - diagonalUp?: PowerPoint.BorderProperties; + dashDotDot = "DashDotDot", /** - * Represents the left border. - * + * The long dash line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - left?: PowerPoint.BorderProperties; + longDash = "LongDash", /** - * Represents the right border. - * + * The long dash-dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - right?: PowerPoint.BorderProperties; + longDashDot = "LongDashDot", /** - * Represents the top border. - * + * The round dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - top?: PowerPoint.BorderProperties; - } - /** - * Represents the margins of a table cell. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TableCellMargins { + roundDot = "RoundDot", /** - * Specifies the bottom margin in points. - * + * The solid line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - bottom?: number | undefined; + solid = "Solid", /** - * Specifies the left margin in points. - * + * The square dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - left?: number | undefined; + squareDot = "SquareDot", /** - * Specifies the right margin in points. - * + * The long dash-dot-dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - right?: number | undefined; + longDashDotDot = "LongDashDotDot", /** - * Specifies the top margin in points. - * + * The system dash line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - top?: number | undefined; - } - /** - * Represents the table cell properties to update. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TableCellProperties { + systemDash = "SystemDash", /** - * Specifies the border formatting of the table cell. - * + * The system dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - borders?: PowerPoint.TableCellBorders; + systemDot = "SystemDot", /** - * Specifies the fill formatting of the table cell. - * + * The system dash-dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - fill?: PowerPoint.FillProperties; - /** - * Specifies the font formatting of the table cell. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - font?: PowerPoint.FontProperties; - /** - * Represents the horizontal alignment of the text in the table cell. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | undefined; - /** - * Represents the indent level of the text in the table cell. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - indentLevel?: number | undefined; - /** - * Specifies the margin settings in the table cell. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - margins?: PowerPoint.TableCellMargins; - /** - * Specifies the text content of the table cell. - - If a portion of the text requires different formatting, use the `textRuns` property instead. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - text?: string; - /** - * Specifies the contents of the table cell as an array of {@link PowerPoint.TextRun} objects. - Each `TextRun` object represents a sequence of one or more characters that share the same font attributes. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - textRuns?: PowerPoint.TextRun[]; - /** - * Represents the vertical alignment of the text in the table cell. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered" | undefined; + systemDashDot = "SystemDashDot", } /** - * Represents a collection of table columns. + * Represents the properties for a table cell border. * * @remarks * [Api set: PowerPointApi 1.9] */ - class TableColumnCollection extends OfficeExtension.ClientObject { + class Border extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.TableColumn[]; /** - * Adds one or more columns to the table. + * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param index Optional. Specifies the zero-based index where the new columns are added. Existing columns starting at the index location are shifted right. If the index value is undefined, null, -1, or greater than the number of columns in the table, the new columns are added at the end of the table. - * @param count Optional. The number of columns to add. If the value is undefined or 0, only one column is added. */ - // eslint-disable-next-line @definitelytyped/redundant-undefined - add(index?: number | null | undefined, count?: number | undefined): void; + color: string | undefined; /** - * Deletes the specified columns from the collection. + * Represents the dash style of the line. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param columns An array of `TableColumn` objects representing the columns to be deleted. */ - deleteColumns(columns: PowerPoint.TableColumn[]): void; + dashStyle: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; /** - * Gets the number of columns in the collection. + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). * * @remarks * [Api set: PowerPointApi 1.9] - * @returns The number of columns in the collection. */ - getCount(): OfficeExtension.ClientResult; + transparency: number | undefined; /** - * Gets the column using its zero-based index in the collection. + * Represents the weight of the line, in points. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param index Index value of the column to be retrieved, as a zero-based index. - * @returns The column object. */ - getItemAt(index: number): PowerPoint.TableColumn; + weight: number | undefined; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableColumnCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableColumnCollection; + load(options?: PowerPoint.Interfaces.BorderLoadOptions): PowerPoint.Border; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableColumnCollection; + load(propertyNames?: string | string[]): PowerPoint.Border; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableColumnCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Border; /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableColumnCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableColumnCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. - */ - toJSON(): PowerPoint.Interfaces.TableColumnCollectionData; + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.Border` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BorderData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.BorderData; } /** - * Represents the available options when clearing a table. + * Represents the borders for a table cell. * * @remarks * [Api set: PowerPointApi 1.9] */ - interface TableClearOptions { - /** - * Specifies if both values and formatting of the table should be cleared. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - all?: boolean; + class Borders extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Specifies if the formatting of the table should be cleared. + * Gets the bottom border. * * @remarks * [Api set: PowerPointApi 1.9] */ - format?: boolean; + readonly bottom: PowerPoint.Border; /** - * Specifies if the values of the table should be cleared. + * Gets the diagonal border (top-left to bottom-right). * * @remarks * [Api set: PowerPointApi 1.9] */ - text?: boolean; - } - /** - * Represents a row in a table. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class TableRow extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + readonly diagonalDown: PowerPoint.Border; /** - * Retrieves the current height of the row in points. + * Gets the diagonal border (bottom-left to top-right). * * @remarks * [Api set: PowerPointApi 1.9] */ - readonly currentHeight: number; + readonly diagonalUp: PowerPoint.Border; /** - * Specifies the height of the row in points. If the set row height is less than the minimum height, the row height will be increased to the minimum height. + * Gets the left border. * * @remarks * [Api set: PowerPointApi 1.9] */ - height: number; + readonly left: PowerPoint.Border; /** - * Returns the index number of the row within the rows collection of the table. Zero-indexed. + * Gets the right border. * * @remarks * [Api set: PowerPointApi 1.9] */ - readonly rowIndex: number; + readonly right: PowerPoint.Border; /** - * Deletes the row. + * Gets the top border. * * @remarks * [Api set: PowerPointApi 1.9] */ - delete(): void; + readonly top: PowerPoint.Border; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableRowLoadOptions): PowerPoint.TableRow; + load(options?: PowerPoint.Interfaces.BordersLoadOptions): PowerPoint.Borders; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableRow; + load(propertyNames?: string | string[]): PowerPoint.Borders; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -185271,616 +185287,732 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.TableRow; + }): PowerPoint.Borders; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableRow` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableRowData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.Borders` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BordersData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TableRowData; + toJSON(): PowerPoint.Interfaces.BordersData; } /** - * Represents a collection of table rows. + * Represents the margins of a table cell. * * @remarks * [Api set: PowerPointApi 1.9] */ - class TableRowCollection extends OfficeExtension.ClientObject { + class Margins extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.TableRow[]; /** - * Adds one or more rows to the table. + * Specifies the bottom margin in points. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param index Optional. Specifies the zero-based index where the new rows are added. Existing rows starting at the index location are shifted down. If the index value is undefined, null, -1, or greater than the number of rows in the table, the new rows are added at the end of the table. - * @param count Optional. The number of rows to add. If the value is undefined or 0, only one row is added. */ - // eslint-disable-next-line @definitelytyped/redundant-undefined - add(index?: number | null | undefined, count?: number | undefined): void; + bottom: number | undefined; /** - * Deletes the specified rows from the collection. + * Specifies the left margin in points. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param rows An array of `TableRow` objects representing the rows to be deleted. */ - deleteRows(rows: PowerPoint.TableRow[]): void; + left: number | undefined; /** - * Gets the number of rows in the collection. + * Specifies the right margin in points. * * @remarks * [Api set: PowerPointApi 1.9] - * @returns The number of rows in the collection. */ - getCount(): OfficeExtension.ClientResult; + right: number | undefined; /** - * Gets the row using its zero-based index in the collection. + * Specifies the top margin in points. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param index Index value of the row to be retrieved, as a zero-based index. - * @returns The row object. */ - getItemAt(index: number): PowerPoint.TableRow; + top: number | undefined; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableRowCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableRowCollection; + load(options?: PowerPoint.Interfaces.MarginsLoadOptions): PowerPoint.Margins; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableRowCollection; + load(propertyNames?: string | string[]): PowerPoint.Margins; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableRowCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Margins; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableRowCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableRowCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Whereas the original `PowerPoint.Margins` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.MarginsData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TableRowCollectionData; + toJSON(): PowerPoint.Interfaces.MarginsData; } /** - * Represents the available built-in table styles. + * Specifies a shape's fill type. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - enum TableStyle { + enum ShapeFillType { /** - * Specifies the style "No style, No grid" in UI. + * Specifies that the shape should have no fill. * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - noStyleNoGrid = "NoStyleNoGrid", + noFill = "NoFill", /** - * Specifies the style "Themed style 1 - Accent 1" in UI. + * Specifies that the shape should have regular solid fill. * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - themedStyle1Accent1 = "ThemedStyle1Accent1", + solid = "Solid", /** - * Specifies the style "Themed style 1 - Accent 2" in UI. + * Specifies that the shape should have gradient fill. * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - themedStyle1Accent2 = "ThemedStyle1Accent2", + gradient = "Gradient", /** - * Specifies the style "Themed style 1 - Accent 3" in UI. + * Specifies that the shape should have pattern fill. * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - themedStyle1Accent3 = "ThemedStyle1Accent3", + pattern = "Pattern", /** - * Specifies the style "Themed style 1 - Accent 4" in UI. + * Specifies that the shape should have picture or texture fill. * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - themedStyle1Accent4 = "ThemedStyle1Accent4", + pictureAndTexture = "PictureAndTexture", /** - * Specifies the style "Themed style 1 - Accent 5" in UI. + * Specifies that the shape should have slide background fill. * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - themedStyle1Accent5 = "ThemedStyle1Accent5", + slideBackground = "SlideBackground", + } + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class ShapeFill extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Specifies the style "Themed style 1 - Accent 6" in UI. + * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - themedStyle1Accent6 = "ThemedStyle1Accent6", + foregroundColor: string; /** - * Specifies the style "No style, Table grid" in UI. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - noStyleTableGrid = "NoStyleTableGrid", + transparency: number; /** - * Specifies the style "Themed style 2 - Accent 1" in UI. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - themedStyle2Accent1 = "ThemedStyle2Accent1", + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; /** - * Specifies the style "Themed style 2 - Accent 2" in UI. + * Clears the fill formatting of this shape. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - themedStyle2Accent2 = "ThemedStyle2Accent2", + clear(): void; /** - * Specifies the style "Themed style 2 - Accent 3" in UI. + * Sets the fill formatting of the shape to an image. This changes the fill type to `PictureAndTexture`. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] + * + * @param base64EncodedImage A string that is a Base64 encoding of the image data. */ - themedStyle2Accent3 = "ThemedStyle2Accent3", + setImage(base64EncodedImage: string): void; /** - * Specifies the style "Themed style 2 - Accent 4" in UI. + * Sets the fill formatting of the shape to a uniform color. This changes the fill type to `Solid`. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] + * + * @param color A string that specifies the fill color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). */ - themedStyle2Accent4 = "ThemedStyle2Accent4", + setSolidColor(color: string): void; /** - * Specifies the style "Themed style 2 - Accent 5" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - themedStyle2Accent5 = "ThemedStyle2Accent5", + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** - * Specifies the style "Themed style 2 - Accent 6" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - themedStyle2Accent6 = "ThemedStyle2Accent6", + load(propertyNames?: string | string[]): PowerPoint.ShapeFill; /** - * Specifies the style "Light Style 1" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - lightStyle1 = "LightStyle1", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.ShapeFill; /** - * Specifies the style "Light style 1 - Accent 1" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] - */ - lightStyle1Accent1 = "LightStyle1Accent1", + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.ShapeFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeFillData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.ShapeFillData; + } + /** + * Represents the font attributes, such as font name, size, and color. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface FontProperties { /** - * Specifies the style "Light style 1 - Accent 2" in UI. + * Represents whether the font uses all caps, where lowercase letters are shown as capital letters. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle1Accent2 = "LightStyle1Accent2", + allCaps?: boolean | undefined; /** - * Specifies the style "Light style 1 - Accent 3" in UI. + * Represents the bold status of font. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle1Accent3 = "LightStyle1Accent3", + bold?: boolean | undefined; /** - * Specifies the style "Light style 1 - Accent 4" in UI. + * Represents the HTML color in the hexadecimal format (e.g., "#FF0000" represents red) or as a named HTML color value (e.g., "red"). + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle1Accent4 = "LightStyle1Accent4", + color?: string | undefined; /** - * Specifies the style "Light style 1 - Accent 5" in UI. + * Represents the double-strikethrough status of the font. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle1Accent5 = "LightStyle1Accent5", + doubleStrikethrough?: boolean | undefined; /** - * Specifies the style "Light style 1 - Accent 6" in UI. + * Represents the italic status of font. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle1Accent6 = "LightStyle1Accent6", + italic?: boolean | undefined; /** - * Specifies the style "Light Style 2" in UI. + * Represents the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle2 = "LightStyle2", + name?: string | undefined; /** - * Specifies the style "Light style 2 - Accent 1" in UI. + * Represents the font size in points (e.g., 11). + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle2Accent1 = "LightStyle2Accent1", + size?: number | undefined; /** - * Specifies the style "Light style 2 - Accent 2" in UI. + * Represents whether the text uses small caps, where lowercase letters are shown as small capital letters. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle2Accent2 = "LightStyle2Accent2", + smallCaps?: boolean | undefined; /** - * Specifies the style "Light style 2 - Accent 3" in UI. + * Represents the strikethrough status of the font. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle2Accent3 = "LightStyle2Accent3", + strikethrough?: boolean | undefined; /** - * Specifies the style "Light style 2 - Accent 4" in UI. + * Represents the subscript status of the font. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle2Accent4 = "LightStyle2Accent4", + subscript?: boolean | undefined; /** - * Specifies the style "Light style 2 - Accent 5" in UI. + * Represents the superscript status of the font. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle2Accent5 = "LightStyle2Accent5", + superscript?: boolean | undefined; /** - * Specifies the style "Light style 2 - Accent 6" in UI. + * Type of underline applied to the font. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle2Accent6 = "LightStyle2Accent6", + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | undefined; + } + /** + * Represents a sequence of one or more characters with the same font attributes. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface TextRun { /** - * Specifies the style "Light Style 3" in UI. + * The font attributes (such as font name, font size, and color) applied to this text run. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle3 = "LightStyle3", + font?: PowerPoint.FontProperties; /** - * Specifies the style "Light style 3 - Accent 1" in UI. + * The text of this text run. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle3Accent1 = "LightStyle3Accent1", + text: string; + } + /** + * Represents a table. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + class TableCell extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Specifies the style "Light style 3 - Accent 2" in UI. + * Gets the collection of borders for the table cell. + * * @remarks * [Api set: PowerPointApi 1.9] */ - lightStyle3Accent2 = "LightStyle3Accent2", + readonly borders: PowerPoint.Borders; /** - * Specifies the style "Light style 3 - Accent 3" in UI. + * Gets the fill color of the table cell. + * * @remarks * [Api set: PowerPointApi 1.9] */ - lightStyle3Accent3 = "LightStyle3Accent3", + readonly fill: PowerPoint.ShapeFill; /** - * Specifies the style "Light style 3 - Accent 4" in UI. + * Gets the font of the table cell. + * * @remarks * [Api set: PowerPointApi 1.9] */ - lightStyle3Accent4 = "LightStyle3Accent4", + readonly font: PowerPoint.ShapeFont; /** - * Specifies the style "Light style 3 - Accent 5" in UI. + * Gets the set of margins in the table cell. + * * @remarks * [Api set: PowerPointApi 1.9] */ - lightStyle3Accent5 = "LightStyle3Accent5", + readonly margins: PowerPoint.Margins; /** - * Specifies the style "Light style 3 - Accent 6" in UI. + * Gets the number of table columns this cell spans across. + Will be greater than or equal to 1. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - lightStyle3Accent6 = "LightStyle3Accent6", + readonly columnCount: number; /** - * Specifies the style "Medium Style 1" in UI. + * Gets the zero-based column index of the cell within the table. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - mediumStyle1 = "MediumStyle1", + readonly columnIndex: number; /** - * Specifies the style "Medium style 1 - Accent 1" in UI. + * Specifies the horizontal alignment of the text in the table cell. Returns `null` if the cell text contains different alignments. + * * @remarks * [Api set: PowerPointApi 1.9] */ - mediumStyle1Accent1 = "MediumStyle1Accent1", + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; /** - * Specifies the style "Medium style 1 - Accent 2" in UI. + * Specifies the indent level of the text in the table cell. Returns `null` if the cell text contains different indent levels. + * * @remarks * [Api set: PowerPointApi 1.9] */ - mediumStyle1Accent2 = "MediumStyle1Accent2", + indentLevel: number | null; /** - * Specifies the style "Medium style 1 - Accent 3" in UI. + * Gets the number of table rows this cell spans across. + Will be greater than or equal to 1. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - mediumStyle1Accent3 = "MediumStyle1Accent3", + readonly rowCount: number; /** - * Specifies the style "Medium style 1 - Accent 4" in UI. + * Gets the zero-based row index of the cell within the table. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - mediumStyle1Accent4 = "MediumStyle1Accent4", + readonly rowIndex: number; /** - * Specifies the style "Medium style 1 - Accent 5" in UI. + * Specifies the text content of the table cell. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - mediumStyle1Accent5 = "MediumStyle1Accent5", + text: string; /** - * Specifies the style "Medium style 1 - Accent 6" in UI. + * Specifies the contents of the table cell as an array of {@link PowerPoint.TextRun} objects. + Each `TextRun` object represents a sequence of one or more characters that share the same font attributes. + * * @remarks * [Api set: PowerPointApi 1.9] */ - mediumStyle1Accent6 = "MediumStyle1Accent6", + textRuns: PowerPoint.TextRun[]; /** - * Specifies the style "Medium Style 2" in UI. + * Specifies the vertical alignment of the text in the table cell. + * * @remarks * [Api set: PowerPointApi 1.9] */ - mediumStyle2 = "MediumStyle2", + verticalAlignment: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; /** - * Specifies the style "Medium style 2 - Accent 1" in UI. + * Resizes the table cell to span across a specified number of rows and columns. + If rowCount or columnCount are greater than 1, the cell will become a merged area. If the cell + is already a merged area and rowCount and columnCount are set to 1, the cell will no longer be + a merged area. + * * @remarks * [Api set: PowerPointApi 1.9] + * + * @param rowCount The number of rows the cell will span across. Must be greater than 0. + * @param columnCount The number of columns the cell will span across. Must be greater than 0. */ - mediumStyle2Accent1 = "MediumStyle2Accent1", + resize(rowCount: number, columnCount: number): void; /** - * Specifies the style "Medium style 2 - Accent 2" in UI. + * Splits the cell into the specified number of rows and columns. + * * @remarks * [Api set: PowerPointApi 1.9] + * + * @param rowCount The number of rows to split into. Must be greater than 0. + * @param columnCount The number of columns to split into. Must be greater than 0. */ - mediumStyle2Accent2 = "MediumStyle2Accent2", + split(rowCount: number, columnCount: number): void; /** - * Specifies the style "Medium style 2 - Accent 3" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - mediumStyle2Accent3 = "MediumStyle2Accent3", + load(options?: PowerPoint.Interfaces.TableCellLoadOptions): PowerPoint.TableCell; /** - * Specifies the style "Medium style 2 - Accent 4" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - mediumStyle2Accent4 = "MediumStyle2Accent4", + load(propertyNames?: string | string[]): PowerPoint.TableCell; /** - * Specifies the style "Medium style 2 - Accent 5" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - mediumStyle2Accent5 = "MediumStyle2Accent5", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TableCell; /** - * Specifies the style "Medium style 2 - Accent 6" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableCell` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableCellData`) that contains shallow copies of any loaded child properties from the original object. */ - mediumStyle2Accent6 = "MediumStyle2Accent6", + toJSON(): PowerPoint.Interfaces.TableCellData; + } + /** + * Represents a collection of table cells. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + class TableCellCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.TableCell[]; /** - * Specifies the style "Medium Style 3" in UI. + * Gets the number of table cells in the collection. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] + * @returns The number of table cells in the collection. */ - mediumStyle3 = "MediumStyle3", + getCount(): OfficeExtension.ClientResult; /** - * Specifies the style "Medium style 3 - Accent 1" in UI. + * Gets the table cell using its zero-based index in the collection. If the `TableCell` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] + * + * @param row Row index value of the table cell to be retrieved, as a zero-based index. + * @param column Column index value of the table cell to be retrieved, as a zero-based index. + * @returns The `TableCell` object. */ - mediumStyle3Accent1 = "MediumStyle3Accent1", + getItemAtOrNullObject(row: number, column: number): PowerPoint.TableCell; /** - * Specifies the style "Medium style 3 - Accent 2" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - mediumStyle3Accent2 = "MediumStyle3Accent2", + load(options?: PowerPoint.Interfaces.TableCellCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableCellCollection; /** - * Specifies the style "Medium style 3 - Accent 3" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - mediumStyle3Accent3 = "MediumStyle3Accent3", + load(propertyNames?: string | string[]): PowerPoint.TableCellCollection; /** - * Specifies the style "Medium style 3 - Accent 4" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - mediumStyle3Accent4 = "MediumStyle3Accent4", + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableCellCollection; /** - * Specifies the style "Medium style 3 - Accent 5" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableCellCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableCellCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - mediumStyle3Accent5 = "MediumStyle3Accent5", + toJSON(): PowerPoint.Interfaces.TableCellCollectionData; + } + /** + * Represents a column in a table. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + class TableColumn extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Specifies the style "Medium style 3 - Accent 6" in UI. + * Returns the index number of the column within the column collection of the table. Zero-indexed. + * * @remarks * [Api set: PowerPointApi 1.9] */ - mediumStyle3Accent6 = "MediumStyle3Accent6", + readonly columnIndex: number; /** - * Specifies the style "Medium Style 4" in UI. + * Retrieves the width of the column in points. If the set column width is less than the minimum width, the column width will be increased to the minimum width. + * * @remarks * [Api set: PowerPointApi 1.9] */ - mediumStyle4 = "MediumStyle4", + width: number; /** - * Specifies the style "Medium style 4 - Accent 1" in UI. + * Deletes the column. + * * @remarks * [Api set: PowerPointApi 1.9] */ - mediumStyle4Accent1 = "MediumStyle4Accent1", + delete(): void; /** - * Specifies the style "Medium style 4 - Accent 2" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - mediumStyle4Accent2 = "MediumStyle4Accent2", + load(options?: PowerPoint.Interfaces.TableColumnLoadOptions): PowerPoint.TableColumn; /** - * Specifies the style "Medium style 4 - Accent 3" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - mediumStyle4Accent3 = "MediumStyle4Accent3", + load(propertyNames?: string | string[]): PowerPoint.TableColumn; /** - * Specifies the style "Medium style 4 - Accent 4" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - mediumStyle4Accent4 = "MediumStyle4Accent4", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TableColumn; /** - * Specifies the style "Medium style 4 - Accent 5" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableColumn` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableColumnData`) that contains shallow copies of any loaded child properties from the original object. */ - mediumStyle4Accent5 = "MediumStyle4Accent5", + toJSON(): PowerPoint.Interfaces.TableColumnData; + } + /** + * Represents a collection of table columns. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + class TableColumnCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.TableColumn[]; /** - * Specifies the style "Medium style 4 - Accent 6" in UI. + * Adds one or more columns to the table. + * * @remarks * [Api set: PowerPointApi 1.9] + * + * @param index Optional. Specifies the zero-based index where the new columns are added. Existing columns starting at the index location are shifted right. If the index value is undefined, null, -1, or greater than the number of columns in the table, the new columns are added at the end of the table. + * @param count Optional. The number of columns to add. If the value is undefined or 0, only one column is added. */ - mediumStyle4Accent6 = "MediumStyle4Accent6", + // eslint-disable-next-line @definitelytyped/redundant-undefined + add(index?: number | null | undefined, count?: number | undefined): void; /** - * Specifies the style "Dark Style 1" in UI. + * Deletes the specified columns from the collection. + * * @remarks * [Api set: PowerPointApi 1.9] + * + * @param columns An array of `TableColumn` objects representing the columns to be deleted. */ - darkStyle1 = "DarkStyle1", + deleteColumns(columns: PowerPoint.TableColumn[]): void; /** - * Specifies the style "Dark style 1 - Accent 1" in UI. + * Gets the number of columns in the collection. + * * @remarks * [Api set: PowerPointApi 1.9] + * @returns The number of columns in the collection. */ - darkStyle1Accent1 = "DarkStyle1Accent1", + getCount(): OfficeExtension.ClientResult; /** - * Specifies the style "Dark style 1 - Accent 2" in UI. + * Gets the column using its zero-based index in the collection. + * * @remarks * [Api set: PowerPointApi 1.9] + * + * @param index Index value of the column to be retrieved, as a zero-based index. + * @returns The column object. */ - darkStyle1Accent2 = "DarkStyle1Accent2", + getItemAt(index: number): PowerPoint.TableColumn; /** - * Specifies the style "Dark style 1 - Accent 3" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - darkStyle1Accent3 = "DarkStyle1Accent3", + load(options?: PowerPoint.Interfaces.TableColumnCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableColumnCollection; /** - * Specifies the style "Dark style 1 - Accent 4" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - darkStyle1Accent4 = "DarkStyle1Accent4", - /** - * Specifies the style "Dark style 1 - Accent 5" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] - */ - darkStyle1Accent5 = "DarkStyle1Accent5", + load(propertyNames?: string | string[]): PowerPoint.TableColumnCollection; /** - * Specifies the style "Dark style 1 - Accent 6" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - darkStyle1Accent6 = "DarkStyle1Accent6", + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableColumnCollection; /** - * Specifies the style "Dark Style 2" in UI. - * @remarks - * [Api set: PowerPointApi 1.9] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableColumnCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableColumnCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - darkStyle2 = "DarkStyle2", + toJSON(): PowerPoint.Interfaces.TableColumnCollectionData; + } + /** + * Represents the available options when clearing a table. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + interface TableClearOptions { /** - * Specifies the style "Dark style 2 - Accent 1/Accent 2" in UI. + * Specifies if both values and formatting of the table should be cleared. + * * @remarks * [Api set: PowerPointApi 1.9] */ - darkStyle2Accent1 = "DarkStyle2Accent1", + all?: boolean; /** - * Specifies the style "Dark style 2 - Accent 3/Accent 4" in UI. + * Specifies if the formatting of the table should be cleared. + * * @remarks * [Api set: PowerPointApi 1.9] */ - darkStyle2Accent2 = "DarkStyle2Accent2", + format?: boolean; /** - * Specifies the style "Dark style 2 - Accent 5/Accent 6" in UI. + * Specifies if the values of the table should be cleared. + * * @remarks * [Api set: PowerPointApi 1.9] */ - darkStyle2Accent3 = "DarkStyle2Accent3", + text?: boolean; } /** - * Represents the available table style options. + * Represents a row in a table. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - class TableStyleOptions extends OfficeExtension.ClientObject { + class TableRow extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - areColumnsBanded: boolean; - /** - * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - areRowsBanded: boolean; - /** - * Specifies if the first column contains special formatting. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - isFirstColumnHighlighted: boolean; - /** - * Specifies if the first row contains special formatting. + * Retrieves the current height of the row in points. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - isFirstRowHighlighted: boolean; + readonly currentHeight: number; /** - * Specifies if the last column contains special formatting. + * Specifies the height of the row in points. If the set row height is less than the minimum height, the row height will be increased to the minimum height. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - isLastColumnHighlighted: boolean; + height: number; /** - * Specifies if the last row contains special formatting. + * Returns the index number of the row within the rows collection of the table. Zero-indexed. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - isLastRowHighlighted: boolean; + readonly rowIndex: number; /** - * Specifies the table style. + * Deletes the row. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - style: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; + delete(): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableStyleOptionsLoadOptions): PowerPoint.TableStyleOptions; + load(options?: PowerPoint.Interfaces.TableRowLoadOptions): PowerPoint.TableRow; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableStyleOptions; + load(propertyNames?: string | string[]): PowerPoint.TableRow; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -185889,1035 +186021,733 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.TableStyleOptions; + }): PowerPoint.TableRow; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableStyleOptions` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableStyleOptionsData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.TableRow` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableRowData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TableStyleOptionsData; + toJSON(): PowerPoint.Interfaces.TableRowData; } /** - * Represents a table. + * Represents a collection of table rows. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - class Table extends OfficeExtension.ClientObject { + class TableRowCollection extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.TableRow[]; /** - * Gets the collection of columns in the table. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - readonly columns: PowerPoint.TableColumnCollection; - /** - * Gets the collection of rows in the table. + * Adds one or more rows to the table. * * @remarks * [Api set: PowerPointApi 1.9] - */ - readonly rows: PowerPoint.TableRowCollection; - /** - * Gets the table style options. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - readonly styleOptions: PowerPoint.TableStyleOptions; - /** - * Gets the number of columns in the table. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - readonly columnCount: number; - /** - * Gets the number of rows in the table. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - readonly rowCount: number; - /** - * Gets all of the values in the table. * - * @remarks - * [Api set: PowerPointApi 1.8] + * @param index Optional. Specifies the zero-based index where the new rows are added. Existing rows starting at the index location are shifted down. If the index value is undefined, null, -1, or greater than the number of rows in the table, the new rows are added at the end of the table. + * @param count Optional. The number of rows to add. If the value is undefined or 0, only one row is added. */ - readonly values: string[][]; + // eslint-disable-next-line @definitelytyped/redundant-undefined + add(index?: number | null | undefined, count?: number | undefined): void; /** - * Clears table values and formatting. + * Deletes the specified rows from the collection. * * @remarks * [Api set: PowerPointApi 1.9] * - * @param options Provides options for clearing the table. - */ - clear(options?: PowerPoint.TableClearOptions): void; - /** - * Gets the cell at the specified `rowIndex` and `columnIndex`. - * - * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param rowIndex The zero-based row index of the cell. - * @param columnIndex The zero-based column index of the cell. - * @returns The cell at the specified row and column. If the cell is part of a merged area and not the top left cell of the merged area, an object with the `isNullObject` property set to `true` is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. - */ - getCellOrNullObject(rowIndex: number, columnIndex: number): PowerPoint.TableCell; - /** - * Gets a collection of cells that represent the merged areas of the table. - * - * @remarks - * [Api set: PowerPointApi 1.8] - * @returns a `TableCellCollection` with cells that represent the merged areas of the table. + * @param rows An array of `TableRow` objects representing the rows to be deleted. */ - getMergedAreas(): PowerPoint.TableCellCollection; + deleteRows(rows: PowerPoint.TableRow[]): void; /** - * Gets the shape object for the table. + * Gets the number of rows in the collection. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] + * @returns The number of rows in the collection. */ - getShape(): PowerPoint.Shape; + getCount(): OfficeExtension.ClientResult; /** - * Creates a merged area starting at the cell specified by rowIndex and columnIndex. The merged area spans across a specified number of rows and columns. + * Gets the row using its zero-based index in the collection. * * @remarks * [Api set: PowerPointApi 1.9] * - * @param rowIndex The zero-based row index of the cell to start the merged area. - * @param columnIndex The zero-based column index of the cell to start the merged area. - * @param rowCount The number of rows to merge with the starting cell. Must be greater than 0. - * @param columnCount The number of columns to merge with the starting cell. Must be greater than 0. + * @param index Index value of the row to be retrieved, as a zero-based index. + * @returns The row object. */ - mergeCells(rowIndex: number, columnIndex: number, rowCount: number, columnCount: number): void; + getItemAt(index: number): PowerPoint.TableRow; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableLoadOptions): PowerPoint.Table; + load(options?: PowerPoint.Interfaces.TableRowCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableRowCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.Table; + load(propertyNames?: string | string[]): PowerPoint.TableRowCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Table; + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableRowCollection; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Table` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.TableRowCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableRowCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - toJSON(): PowerPoint.Interfaces.TableData; + toJSON(): PowerPoint.Interfaces.TableRowCollectionData; } /** - * Provides the table column properties. + * Represents the available built-in table styles. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - interface TableColumnProperties { + enum TableStyle { /** - * Represents the desired width of each column in points, or is undefined. - - When a table is being added, for columns whose width is undefined, - the column width will be calculated by evenly dividing the remaining width - of the table amongst those columns. If the table doesn't have a defined width, - a default column width will be used. - * + * Specifies the style "No style, No grid" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - columnWidth?: number | undefined; - } - /** - * Represents the properties of a merged area of cells in a table. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TableMergedAreaProperties { + noStyleNoGrid = "NoStyleNoGrid", /** - * Specifies the number of columns for the merged cells area. - Must be 1 or greater. - * + * Specifies the style "Themed style 1 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - columnCount: number; + themedStyle1Accent1 = "ThemedStyle1Accent1", /** - * Specifies the zero-based index of the column of the top left cell of the merged area. - * + * Specifies the style "Themed style 1 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - columnIndex: number; + themedStyle1Accent2 = "ThemedStyle1Accent2", /** - * Specifies the number of rows for the merged cells area. - Must be 1 or greater. - * + * Specifies the style "Themed style 1 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - rowCount: number; + themedStyle1Accent3 = "ThemedStyle1Accent3", /** - * Specifies the zero-based index of the row of the top left cell of the merged area. - * + * Specifies the style "Themed style 1 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - rowIndex: number; - } - /** - * Provides the table row properties. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TableRowProperties { + themedStyle1Accent4 = "ThemedStyle1Accent4", /** - * Represents the desired height of each row in points, or is undefined. - - When a table is being added, for rows whose height is undefined, - the row height will be calculated by evenly dividing the remaining height - of the table amongst those rows. If the table doesn't have a defined height, - a default row height will be used. - * + * Specifies the style "Themed style 1 - Accent 5" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - rowHeight?: number | undefined; - } - /** - * Represents the available options when adding a table. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TableAddOptions { + themedStyle1Accent5 = "ThemedStyle1Accent5", /** - * If provided, specifies properties for each column in the table. - The array length must be equal to the number of columns in the table. - Specify an empty object for columns that should use the default formatting. - * + * Specifies the style "Themed style 1 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - columns?: PowerPoint.TableColumnProperties[]; + themedStyle1Accent6 = "ThemedStyle1Accent6", /** - * Specifies the height, in points, of the table. - A default value is used when this parameter isn't provided. - Throws an `InvalidArgument` exception when set with a negative value. - * + * Specifies the style "No style, Table grid" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - height?: number | undefined; + noStyleTableGrid = "NoStyleTableGrid", /** - * Specifies the distance, in points, from the left side of the table to the left side of the slide. - The table is centered horizontally when this parameter isn't provided. - * + * Specifies the style "Themed style 2 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - left?: number | undefined; + themedStyle2Accent1 = "ThemedStyle2Accent1", /** - * If specified, represents an rectangular area where multiple cells appear as a single cell. - * + * Specifies the style "Themed style 2 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - mergedAreas?: PowerPoint.TableMergedAreaProperties[]; + themedStyle2Accent2 = "ThemedStyle2Accent2", /** - * If provided, specifies properties for each row in the table. - The array length must be equal to the number of rows in the table. - Specify an empty object for rows that should use the default formatting. - * + * Specifies the style "Themed style 2 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - rows?: PowerPoint.TableRowProperties[]; + themedStyle2Accent3 = "ThemedStyle2Accent3", /** - * If provided, specifies properties for each cell in the table. - - This should be a 2D array with the same number of rows and columns as the table. - If a cell doesn't require specific formatting, specify an empty object for that cell. - Only the top left cell of a merged are can have properties specified, which will be applied - to the entire merged area. For the other cells in the merged area, an empty object should be provided. - * + * Specifies the style "Themed style 2 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - specificCellProperties?: PowerPoint.TableCellProperties[][]; + themedStyle2Accent4 = "ThemedStyle2Accent4", /** - * Specifies value that represents the table style. - * + * Specifies the style "Themed style 2 - Accent 5" in UI. * @remarks * [Api set: PowerPointApi 1.9] */ - style?: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; + themedStyle2Accent5 = "ThemedStyle2Accent5", /** - * Specifies the distance, in points, from the top edge of the table to the top edge of the slide. - A default value is used when this parameter isn't provided. - * + * Specifies the style "Themed style 2 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - top?: number | undefined; + themedStyle2Accent6 = "ThemedStyle2Accent6", /** - * Specifies the formatting which applies uniformly to all of the table cells. - - To apply specific formatting to individual cells, use `specificCellProperties`. - - If both uniformCellProperties and specificCellProperties are undefined, the default formatting - will be used, and the default table style will be applied. The table will have the same - appearance as when the user adds a table through the PowerPoint UI. - - To provide a plain appearance for the table, set this property to an empty object - and don't specify `specificCellProperties`. - * + * Specifies the style "Light Style 1" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - uniformCellProperties?: PowerPoint.TableCellProperties; + lightStyle1 = "LightStyle1", /** - * If provided, specifies the values for the table. - - When the table contains areas of merged cells, - only the top left cell of each merged area can have a - non-empty string value. The other cells - in the merged area must be an empty string. - * + * Specifies the style "Light style 1 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - values?: string[][]; + lightStyle1Accent1 = "LightStyle1Accent1", /** - * Specifies the width, in points, of the table. - A default value is used when this parameter isn't provided. - Throws an `InvalidArgument` exception when set with a negative value. - * + * Specifies the style "Light style 1 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - width?: number | undefined; - } - /** - * Represents the collection of shapes. - * - * @remarks - * [Api set: PowerPointApi 1.3] - */ - class ShapeCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.Shape[]; + lightStyle1Accent2 = "LightStyle1Accent2", /** - * Adds a geometric shape to the slide. Returns a `Shape` object that represents the new shape. - * + * Specifies the style "Light style 1 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi 1.4] - * - * @param geometricShapeType Specifies the type of the geometric shape. See {@link PowerPoint.GeometricShapeType} for details. - * @param options An optional parameter to specify the additional options such as the position of the shape. - * @returns The newly inserted shape. + * [Api set: PowerPointApi 1.9] */ - addGeometricShape(geometricShapeType: PowerPoint.GeometricShapeType, options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; + lightStyle1Accent3 = "LightStyle1Accent3", /** - * Adds a geometric shape to the slide. Returns a `Shape` object that represents the new shape. - * + * Specifies the style "Light style 1 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi 1.4] - * - * @param geometricShapeType Specifies the type of the geometric shape. See {@link PowerPoint.GeometricShapeType} for details. - * @param options An optional parameter to specify the additional options such as the position of the shape. - * @returns The newly inserted shape. + * [Api set: PowerPointApi 1.9] */ - addGeometricShape(geometricShapeType: "LineInverse" | "Triangle" | "RightTriangle" | "Rectangle" | "Diamond" | "Parallelogram" | "Trapezoid" | "NonIsoscelesTrapezoid" | "Pentagon" | "Hexagon" | "Heptagon" | "Octagon" | "Decagon" | "Dodecagon" | "Star4" | "Star5" | "Star6" | "Star7" | "Star8" | "Star10" | "Star12" | "Star16" | "Star24" | "Star32" | "RoundRectangle" | "Round1Rectangle" | "Round2SameRectangle" | "Round2DiagonalRectangle" | "SnipRoundRectangle" | "Snip1Rectangle" | "Snip2SameRectangle" | "Snip2DiagonalRectangle" | "Plaque" | "Ellipse" | "Teardrop" | "HomePlate" | "Chevron" | "PieWedge" | "Pie" | "BlockArc" | "Donut" | "NoSmoking" | "RightArrow" | "LeftArrow" | "UpArrow" | "DownArrow" | "StripedRightArrow" | "NotchedRightArrow" | "BentUpArrow" | "LeftRightArrow" | "UpDownArrow" | "LeftUpArrow" | "LeftRightUpArrow" | "QuadArrow" | "LeftArrowCallout" | "RightArrowCallout" | "UpArrowCallout" | "DownArrowCallout" | "LeftRightArrowCallout" | "UpDownArrowCallout" | "QuadArrowCallout" | "BentArrow" | "UturnArrow" | "CircularArrow" | "LeftCircularArrow" | "LeftRightCircularArrow" | "CurvedRightArrow" | "CurvedLeftArrow" | "CurvedUpArrow" | "CurvedDownArrow" | "SwooshArrow" | "Cube" | "Can" | "LightningBolt" | "Heart" | "Sun" | "Moon" | "SmileyFace" | "IrregularSeal1" | "IrregularSeal2" | "FoldedCorner" | "Bevel" | "Frame" | "HalfFrame" | "Corner" | "DiagonalStripe" | "Chord" | "Arc" | "LeftBracket" | "RightBracket" | "LeftBrace" | "RightBrace" | "BracketPair" | "BracePair" | "Callout1" | "Callout2" | "Callout3" | "AccentCallout1" | "AccentCallout2" | "AccentCallout3" | "BorderCallout1" | "BorderCallout2" | "BorderCallout3" | "AccentBorderCallout1" | "AccentBorderCallout2" | "AccentBorderCallout3" | "WedgeRectCallout" | "WedgeRRectCallout" | "WedgeEllipseCallout" | "CloudCallout" | "Cloud" | "Ribbon" | "Ribbon2" | "EllipseRibbon" | "EllipseRibbon2" | "LeftRightRibbon" | "VerticalScroll" | "HorizontalScroll" | "Wave" | "DoubleWave" | "Plus" | "FlowChartProcess" | "FlowChartDecision" | "FlowChartInputOutput" | "FlowChartPredefinedProcess" | "FlowChartInternalStorage" | "FlowChartDocument" | "FlowChartMultidocument" | "FlowChartTerminator" | "FlowChartPreparation" | "FlowChartManualInput" | "FlowChartManualOperation" | "FlowChartConnector" | "FlowChartPunchedCard" | "FlowChartPunchedTape" | "FlowChartSummingJunction" | "FlowChartOr" | "FlowChartCollate" | "FlowChartSort" | "FlowChartExtract" | "FlowChartMerge" | "FlowChartOfflineStorage" | "FlowChartOnlineStorage" | "FlowChartMagneticTape" | "FlowChartMagneticDisk" | "FlowChartMagneticDrum" | "FlowChartDisplay" | "FlowChartDelay" | "FlowChartAlternateProcess" | "FlowChartOffpageConnector" | "ActionButtonBlank" | "ActionButtonHome" | "ActionButtonHelp" | "ActionButtonInformation" | "ActionButtonForwardNext" | "ActionButtonBackPrevious" | "ActionButtonEnd" | "ActionButtonBeginning" | "ActionButtonReturn" | "ActionButtonDocument" | "ActionButtonSound" | "ActionButtonMovie" | "Gear6" | "Gear9" | "Funnel" | "MathPlus" | "MathMinus" | "MathMultiply" | "MathDivide" | "MathEqual" | "MathNotEqual" | "CornerTabs" | "SquareTabs" | "PlaqueTabs" | "ChartX" | "ChartStar" | "ChartPlus", options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; + lightStyle1Accent4 = "LightStyle1Accent4", /** - * Create a shape group for several shapes. - * + * Specifies the style "Light style 1 - Accent 5" in UI. * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param values An array of shape IDs or `Shape` objects. - * @returns A `Shape` object that represents the shape group. Use the `Shape.group` property to access the `ShapeGroup` object for the group. + * [Api set: PowerPointApi 1.9] */ - addGroup(values: Array): PowerPoint.Shape; + lightStyle1Accent5 = "LightStyle1Accent5", /** - * Adds a line to the slide. Returns a `Shape` object that represents the new line. - * + * Specifies the style "Light style 1 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi 1.4] - * - * @param connectorType Specifies the connector type of the line. If not provided, `straight` connector type will be used. See {@link PowerPoint.ConnectorType} for details. - * @param options An optional parameter to specify the additional options such as the position of the shape object that contains the line. - * @returns The newly inserted shape. + * [Api set: PowerPointApi 1.9] */ - addLine(connectorType?: PowerPoint.ConnectorType, options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; + lightStyle1Accent6 = "LightStyle1Accent6", /** - * Adds a line to the slide. Returns a `Shape` object that represents the new line. - * + * Specifies the style "Light Style 2" in UI. * @remarks - * [Api set: PowerPointApi 1.4] - * - * @param connectorType Specifies the connector type of the line. If not provided, `straight` connector type will be used. See {@link PowerPoint.ConnectorType} for details. - * @param options An optional parameter to specify the additional options such as the position of the shape object that contains the line. - * @returns The newly inserted shape. + * [Api set: PowerPointApi 1.9] */ - addLine(connectorType?: "Straight" | "Elbow" | "Curve", options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; + lightStyle2 = "LightStyle2", /** - * Adds a table to the slide. Returns a `Shape` object that represents the new table. - Use the `Shape.table` property to get the `Table` object for the shape. - * + * Specifies the style "Light style 2 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param rowCount Number of rows in the table. Must be 1 or greater. - * @param columnCount Number of columns in the table. Must be 1 or greater. - * @param options Provides options describing the new table. - * @returns The newly inserted shape. + * [Api set: PowerPointApi 1.9] */ - addTable(rowCount: number, columnCount: number, options?: PowerPoint.TableAddOptions): PowerPoint.Shape; + lightStyle2Accent1 = "LightStyle2Accent1", /** - * Adds a text box to the slide with the provided text as the content. Returns a `Shape` object that represents the new text box. - * + * Specifies the style "Light style 2 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi 1.4] - * - * @param text Specifies the text that will be shown in the created text box. - * @param options An optional parameter to specify the additional options such as the position of the text box. - * @returns The newly inserted shape. + * [Api set: PowerPointApi 1.9] */ - addTextBox(text: string, options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; + lightStyle2Accent2 = "LightStyle2Accent2", /** - * Gets the number of shapes in the collection. - * + * Specifies the style "Light style 2 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi 1.3] - * @returns The number of shapes in the collection. + * [Api set: PowerPointApi 1.9] */ - getCount(): OfficeExtension.ClientResult; + lightStyle2Accent3 = "LightStyle2Accent3", /** - * Gets a shape using its unique ID. An error is thrown if the shape doesn't exist. - * + * Specifies the style "Light style 2 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param key The ID of the shape. - * @returns The shape with the unique ID. If such a shape doesn't exist, an error is thrown. + * [Api set: PowerPointApi 1.9] */ - getItem(key: string): PowerPoint.Shape; + lightStyle2Accent4 = "LightStyle2Accent4", /** - * Gets a shape using its zero-based index in the collection. An error is thrown if the index is out of range. - * + * Specifies the style "Light style 2 - Accent 5" in UI. * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param index The index of the shape in the collection. - * @returns The shape at the given index. An error is thrown if index is out of range. + * [Api set: PowerPointApi 1.9] */ - getItemAt(index: number): PowerPoint.Shape; + lightStyle2Accent5 = "LightStyle2Accent5", /** - * Gets a shape using its unique ID. If such a shape doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. - * + * Specifies the style "Light style 2 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param id The ID of the shape. - * @returns The shape with the unique ID. If such a shape doesn't exist, an object with an `isNullObject` property set to true is returned. + * [Api set: PowerPointApi 1.9] */ - getItemOrNullObject(id: string): PowerPoint.Shape; + lightStyle2Accent6 = "LightStyle2Accent6", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Specifies the style "Light Style 3" in UI. + * @remarks + * [Api set: PowerPointApi 1.9] */ - load(options?: PowerPoint.Interfaces.ShapeCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.ShapeCollection; + lightStyle3 = "LightStyle3", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Specifies the style "Light style 3 - Accent 1" in UI. + * @remarks + * [Api set: PowerPointApi 1.9] */ - load(propertyNames?: string | string[]): PowerPoint.ShapeCollection; + lightStyle3Accent1 = "LightStyle3Accent1", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Specifies the style "Light style 3 - Accent 2" in UI. + * @remarks + * [Api set: PowerPointApi 1.9] */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.ShapeCollection; + lightStyle3Accent2 = "LightStyle3Accent2", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ShapeCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Specifies the style "Light style 3 - Accent 3" in UI. + * @remarks + * [Api set: PowerPointApi 1.9] */ - toJSON(): PowerPoint.Interfaces.ShapeCollectionData; - } - /** - * Specifies the gradient fill type for a {@link PowerPoint.SlideBackgroundGradientFill}. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - enum SlideBackgroundGradientFillType { + lightStyle3Accent3 = "LightStyle3Accent3", /** - * Unsupported gradient fill. + * Specifies the style "Light style 3 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - unsupported = "Unsupported", + lightStyle3Accent4 = "LightStyle3Accent4", /** - * Linear gradient fill. + * Specifies the style "Light style 3 - Accent 5" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - linear = "Linear", + lightStyle3Accent5 = "LightStyle3Accent5", /** - * Radial gradient fill. + * Specifies the style "Light style 3 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - radial = "Radial", + lightStyle3Accent6 = "LightStyle3Accent6", /** - * Rectangular gradient fill. + * Specifies the style "Medium Style 1" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - rectangular = "Rectangular", + mediumStyle1 = "MediumStyle1", /** - * Path gradient fill. + * Specifies the style "Medium style 1 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - path = "Path", + mediumStyle1Accent1 = "MediumStyle1Accent1", /** - * Shade from title gradient fill. + * Specifies the style "Medium style 1 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - shadeFromTitle = "ShadeFromTitle", - } - /** - * Represents {@link PowerPoint.SlideBackground} gradient fill properties. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - class SlideBackgroundGradientFill extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + mediumStyle1Accent2 = "MediumStyle1Accent2", /** - * Specifies the type of gradient fill. - * + * Specifies the style "Medium style 1 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - type: PowerPoint.SlideBackgroundGradientFillType | "Unsupported" | "Linear" | "Radial" | "Rectangular" | "Path" | "ShadeFromTitle"; + mediumStyle1Accent3 = "MediumStyle1Accent3", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Specifies the style "Medium style 1 - Accent 4" in UI. + * @remarks + * [Api set: PowerPointApi 1.9] */ - load(options?: PowerPoint.Interfaces.SlideBackgroundGradientFillLoadOptions): PowerPoint.SlideBackgroundGradientFill; + mediumStyle1Accent4 = "MediumStyle1Accent4", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Specifies the style "Medium style 1 - Accent 5" in UI. + * @remarks + * [Api set: PowerPointApi 1.9] */ - load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundGradientFill; + mediumStyle1Accent5 = "MediumStyle1Accent5", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Specifies the style "Medium style 1 - Accent 6" in UI. + * @remarks + * [Api set: PowerPointApi 1.9] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.SlideBackgroundGradientFill; + mediumStyle1Accent6 = "MediumStyle1Accent6", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideBackgroundGradientFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundGradientFillData`) that contains shallow copies of any loaded child properties from the original object. + * Specifies the style "Medium Style 2" in UI. + * @remarks + * [Api set: PowerPointApi 1.9] */ - toJSON(): PowerPoint.Interfaces.SlideBackgroundGradientFillData; - } - /** - * Represents the available options for setting a {@link PowerPoint.SlideBackground} gradient fill. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - interface SlideBackgroundGradientFillOptions { + mediumStyle2 = "MediumStyle2", /** - * If provided, specifies the type of gradient fill. - * + * Specifies the style "Medium style 2 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - type?: PowerPoint.SlideBackgroundGradientFillType | "Unsupported" | "Linear" | "Radial" | "Rectangular" | "Path" | "ShadeFromTitle"; - } - /** - * Specifies the pattern fill type for a {@link PowerPoint.SlideBackgroundPatternFill}. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - enum SlideBackgroundPatternFillType { + mediumStyle2Accent1 = "MediumStyle2Accent1", /** - * Unsupported pattern fill. + * Specifies the style "Medium style 2 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - unsupported = "Unsupported", + mediumStyle2Accent2 = "MediumStyle2Accent2", /** - * 5 percent pattern fill. + * Specifies the style "Medium style 2 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent5 = "Percent5", + mediumStyle2Accent3 = "MediumStyle2Accent3", /** - * 10 percent pattern fill. + * Specifies the style "Medium style 2 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent10 = "Percent10", + mediumStyle2Accent4 = "MediumStyle2Accent4", /** - * 20 percent pattern fill. + * Specifies the style "Medium style 2 - Accent 5" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent20 = "Percent20", + mediumStyle2Accent5 = "MediumStyle2Accent5", /** - * 25 percent pattern fill. + * Specifies the style "Medium style 2 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent25 = "Percent25", + mediumStyle2Accent6 = "MediumStyle2Accent6", /** - * 30 percent pattern fill. + * Specifies the style "Medium Style 3" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent30 = "Percent30", + mediumStyle3 = "MediumStyle3", /** - * 40 percent pattern fill. + * Specifies the style "Medium style 3 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent40 = "Percent40", + mediumStyle3Accent1 = "MediumStyle3Accent1", /** - * 50 percent pattern fill. + * Specifies the style "Medium style 3 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent50 = "Percent50", + mediumStyle3Accent2 = "MediumStyle3Accent2", /** - * 60 percent pattern fill. + * Specifies the style "Medium style 3 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent60 = "Percent60", + mediumStyle3Accent3 = "MediumStyle3Accent3", /** - * 70 percent pattern fill. + * Specifies the style "Medium style 3 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent70 = "Percent70", + mediumStyle3Accent4 = "MediumStyle3Accent4", /** - * 75 percent pattern fill. + * Specifies the style "Medium style 3 - Accent 5" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent75 = "Percent75", + mediumStyle3Accent5 = "MediumStyle3Accent5", /** - * 80 percent pattern fill. + * Specifies the style "Medium style 3 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent80 = "Percent80", + mediumStyle3Accent6 = "MediumStyle3Accent6", /** - * 90 percent pattern fill. + * Specifies the style "Medium Style 4" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - percent90 = "Percent90", + mediumStyle4 = "MediumStyle4", /** - * Horizontal pattern fill. + * Specifies the style "Medium style 4 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - horizontal = "Horizontal", + mediumStyle4Accent1 = "MediumStyle4Accent1", /** - * Vertical pattern fill. + * Specifies the style "Medium style 4 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - vertical = "Vertical", + mediumStyle4Accent2 = "MediumStyle4Accent2", /** - * Light horizontal pattern fill. + * Specifies the style "Medium style 4 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - lightHorizontal = "LightHorizontal", + mediumStyle4Accent3 = "MediumStyle4Accent3", /** - * Light vertical pattern fill. + * Specifies the style "Medium style 4 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - lightVertical = "LightVertical", + mediumStyle4Accent4 = "MediumStyle4Accent4", /** - * Dark horizontal pattern fill. + * Specifies the style "Medium style 4 - Accent 5" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - darkHorizontal = "DarkHorizontal", + mediumStyle4Accent5 = "MediumStyle4Accent5", /** - * Dark vertical pattern fill. + * Specifies the style "Medium style 4 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - darkVertical = "DarkVertical", + mediumStyle4Accent6 = "MediumStyle4Accent6", /** - * Narrow horizontal pattern fill. + * Specifies the style "Dark Style 1" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - narrowHorizontal = "NarrowHorizontal", + darkStyle1 = "DarkStyle1", /** - * Narrow vertical pattern fill. + * Specifies the style "Dark style 1 - Accent 1" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - narrowVertical = "NarrowVertical", + darkStyle1Accent1 = "DarkStyle1Accent1", /** - * Dashed horizontal pattern fill. + * Specifies the style "Dark style 1 - Accent 2" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - dashedHorizontal = "DashedHorizontal", + darkStyle1Accent2 = "DarkStyle1Accent2", /** - * Dashed vertical pattern fill. + * Specifies the style "Dark style 1 - Accent 3" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - dashedVertical = "DashedVertical", + darkStyle1Accent3 = "DarkStyle1Accent3", /** - * Cross pattern fill. + * Specifies the style "Dark style 1 - Accent 4" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - cross = "Cross", + darkStyle1Accent4 = "DarkStyle1Accent4", /** - * Downward diagonal pattern fill. + * Specifies the style "Dark style 1 - Accent 5" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - downwardDiagonal = "DownwardDiagonal", + darkStyle1Accent5 = "DarkStyle1Accent5", /** - * Upward diagonal pattern fill. + * Specifies the style "Dark style 1 - Accent 6" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - upwardDiagonal = "UpwardDiagonal", + darkStyle1Accent6 = "DarkStyle1Accent6", /** - * Light downward diagonal pattern fill. + * Specifies the style "Dark Style 2" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - lightDownwardDiagonal = "LightDownwardDiagonal", + darkStyle2 = "DarkStyle2", /** - * Light upward diagonal pattern fill. + * Specifies the style "Dark style 2 - Accent 1/Accent 2" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - lightUpwardDiagonal = "LightUpwardDiagonal", + darkStyle2Accent1 = "DarkStyle2Accent1", /** - * Dark downward diagonal pattern fill. + * Specifies the style "Dark style 2 - Accent 3/Accent 4" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - darkDownwardDiagonal = "DarkDownwardDiagonal", + darkStyle2Accent2 = "DarkStyle2Accent2", /** - * Dark upward diagonal pattern fill. + * Specifies the style "Dark style 2 - Accent 5/Accent 6" in UI. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - darkUpwardDiagonal = "DarkUpwardDiagonal", + darkStyle2Accent3 = "DarkStyle2Accent3", + } + /** + * Represents the available table style settings. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + class TableStyleSettings extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Wide downward diagonal pattern fill. + * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - wideDownwardDiagonal = "WideDownwardDiagonal", + areColumnsBanded: boolean; /** - * Wide upward diagonal pattern fill. + * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - wideUpwardDiagonal = "WideUpwardDiagonal", + areRowsBanded: boolean; /** - * Dashed downward diagonal pattern fill. + * Specifies if the first column contains special formatting. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - dashedDownwardDiagonal = "DashedDownwardDiagonal", + isFirstColumnHighlighted: boolean; /** - * Dashed upward diagonal pattern fill. + * Specifies if the first row contains special formatting. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - dashedUpwardDiagonal = "DashedUpwardDiagonal", + isFirstRowHighlighted: boolean; /** - * Diagonal cross pattern fill. + * Specifies if the last column contains special formatting. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - diagonalCross = "DiagonalCross", + isLastColumnHighlighted: boolean; /** - * Small checker board pattern fill. + * Specifies if the last row contains special formatting. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - smallCheckerBoard = "SmallCheckerBoard", + isLastRowHighlighted: boolean; /** - * Large checker board pattern fill. + * Specifies the table style. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - largeCheckerBoard = "LargeCheckerBoard", + style: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; /** - * Small grid pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - smallGrid = "SmallGrid", + load(options?: PowerPoint.Interfaces.TableStyleSettingsLoadOptions): PowerPoint.TableStyleSettings; /** - * Large grid pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - largeGrid = "LargeGrid", + load(propertyNames?: string | string[]): PowerPoint.TableStyleSettings; /** - * Dotted grid pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - dottedGrid = "DottedGrid", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TableStyleSettings; /** - * Small confetti pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableStyleSettings` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableStyleSettingsData`) that contains shallow copies of any loaded child properties from the original object. */ - smallConfetti = "SmallConfetti", + toJSON(): PowerPoint.Interfaces.TableStyleSettingsData; + } + /** + * Represents a table. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + class Table extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Large confetti pattern fill. + * Gets the collection of columns in the table. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - largeConfetti = "LargeConfetti", + readonly columns: PowerPoint.TableColumnCollection; /** - * Horizontal brick pattern fill. + * Gets the collection of rows in the table. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - horizontalBrick = "HorizontalBrick", + readonly rows: PowerPoint.TableRowCollection; /** - * Diagonal brick pattern fill. + * Gets the table style settings. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - diagonalBrick = "DiagonalBrick", - /** - * Solid diamond pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - solidDiamond = "SolidDiamond", - /** - * Outlined diamond pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - outlinedDiamond = "OutlinedDiamond", - /** - * Dotted diamond pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - dottedDiamond = "DottedDiamond", - /** - * Plaid pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - plaid = "Plaid", - /** - * Sphere pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - sphere = "Sphere", - /** - * Weave pattern fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - weave = "Weave", + readonly styleSettings: PowerPoint.TableStyleSettings; /** - * Divot pattern fill. + * Gets the number of columns in the table. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - divot = "Divot", + readonly columnCount: number; /** - * Shingle pattern fill. + * Gets the number of rows in the table. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - shingle = "Shingle", + readonly rowCount: number; /** - * Wave pattern fill. + * Gets all of the values in the table. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - wave = "Wave", + readonly values: string[][]; /** - * Trellis pattern fill. + * Clears table values and formatting. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] + * + * @param options Provides options for clearing the table. */ - trellis = "Trellis", + clear(options?: PowerPoint.TableClearOptions): void; /** - * Zig zag pattern fill. + * Gets the cell at the specified `rowIndex` and `columnIndex`. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] + * + * @param rowIndex The zero-based row index of the cell. + * @param columnIndex The zero-based column index of the cell. + * @returns The cell at the specified row and column. If the cell is part of a merged area and not the top left cell of the merged area, an object with the `isNullObject` property set to `true` is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. */ - zigZag = "ZigZag", - } - /** - * Represents {@link PowerPoint.SlideBackground} pattern fill properties. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - class SlideBackgroundPatternFill extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + getCellOrNullObject(rowIndex: number, columnIndex: number): PowerPoint.TableCell; /** - * Specifies the background color in HTML color format (e.g., "#FFFFFF" or "white"). + * Gets a collection of cells that represent the merged areas of the table. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] + * @returns a `TableCellCollection` with cells that represent the merged areas of the table. */ - backgroundColor: string; + getMergedAreas(): PowerPoint.TableCellCollection; /** - * Specifies the foreground color in HTML color format (e.g., "#FFA500" or "orange"). + * Gets the shape object for the table. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - foregroundColor: string; + getShape(): PowerPoint.Shape; /** - * Specifies the pattern type. + * Creates a merged area starting at the cell specified by rowIndex and columnIndex. The merged area spans across a specified number of rows and columns. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] + * + * @param rowIndex The zero-based row index of the cell to start the merged area. + * @param columnIndex The zero-based column index of the cell to start the merged area. + * @param rowCount The number of rows to merge with the starting cell. Must be greater than 0. + * @param columnCount The number of columns to merge with the starting cell. Must be greater than 0. */ - pattern: PowerPoint.SlideBackgroundPatternFillType | "Unsupported" | "Percent5" | "Percent10" | "Percent20" | "Percent25" | "Percent30" | "Percent40" | "Percent50" | "Percent60" | "Percent70" | "Percent75" | "Percent80" | "Percent90" | "Horizontal" | "Vertical" | "LightHorizontal" | "LightVertical" | "DarkHorizontal" | "DarkVertical" | "NarrowHorizontal" | "NarrowVertical" | "DashedHorizontal" | "DashedVertical" | "Cross" | "DownwardDiagonal" | "UpwardDiagonal" | "LightDownwardDiagonal" | "LightUpwardDiagonal" | "DarkDownwardDiagonal" | "DarkUpwardDiagonal" | "WideDownwardDiagonal" | "WideUpwardDiagonal" | "DashedDownwardDiagonal" | "DashedUpwardDiagonal" | "DiagonalCross" | "SmallCheckerBoard" | "LargeCheckerBoard" | "SmallGrid" | "LargeGrid" | "DottedGrid" | "SmallConfetti" | "LargeConfetti" | "HorizontalBrick" | "DiagonalBrick" | "SolidDiamond" | "OutlinedDiamond" | "DottedDiamond" | "Plaid" | "Sphere" | "Weave" | "Divot" | "Shingle" | "Wave" | "Trellis" | "ZigZag"; + mergeCells(rowIndex: number, columnIndex: number, rowCount: number, columnCount: number): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.SlideBackgroundPatternFillLoadOptions): PowerPoint.SlideBackgroundPatternFill; + load(options?: PowerPoint.Interfaces.TableLoadOptions): PowerPoint.Table; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundPatternFill; + load(propertyNames?: string | string[]): PowerPoint.Table; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -186926,1119 +186756,1133 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.SlideBackgroundPatternFill; + }): PowerPoint.Table; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideBackgroundPatternFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundPatternFillData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.Table` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.SlideBackgroundPatternFillData; + toJSON(): PowerPoint.Interfaces.TableData; } /** - * Represents the available options for setting a {@link PowerPoint.SlideBackground} pattern fill. + * Represents the fill formatting of a table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - interface SlideBackgroundPatternFillOptions { - /** - * If provided, specifies the background color in HTML color format (e.g., "#FFFFFF" or "white"). - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - backgroundColor?: string; + interface FillProperties { /** - * If provided, specifies the foreground color in HTML color format (e.g., "#FFA500" or "orange"). + * Represents the shape fill color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - foregroundColor?: string; + color?: string | undefined; /** - * If provided, specifies the pattern type. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - pattern?: PowerPoint.SlideBackgroundPatternFillType | "Unsupported" | "Percent5" | "Percent10" | "Percent20" | "Percent25" | "Percent30" | "Percent40" | "Percent50" | "Percent60" | "Percent70" | "Percent75" | "Percent80" | "Percent90" | "Horizontal" | "Vertical" | "LightHorizontal" | "LightVertical" | "DarkHorizontal" | "DarkVertical" | "NarrowHorizontal" | "NarrowVertical" | "DashedHorizontal" | "DashedVertical" | "Cross" | "DownwardDiagonal" | "UpwardDiagonal" | "LightDownwardDiagonal" | "LightUpwardDiagonal" | "DarkDownwardDiagonal" | "DarkUpwardDiagonal" | "WideDownwardDiagonal" | "WideUpwardDiagonal" | "DashedDownwardDiagonal" | "DashedUpwardDiagonal" | "DiagonalCross" | "SmallCheckerBoard" | "LargeCheckerBoard" | "SmallGrid" | "LargeGrid" | "DottedGrid" | "SmallConfetti" | "LargeConfetti" | "HorizontalBrick" | "DiagonalBrick" | "SolidDiamond" | "OutlinedDiamond" | "DottedDiamond" | "Plaid" | "Sphere" | "Weave" | "Divot" | "Shingle" | "Wave" | "Trellis" | "ZigZag"; + transparency?: number | undefined; } /** - * Represents {@link PowerPoint.SlideBackground} picture or texture fill properties. + * Represents the properties for a table cell border. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - class SlideBackgroundPictureOrTextureFill extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + interface BorderProperties { /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). + * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - transparency: number; + color?: string | undefined; /** - * Sets the image used to fill. + * Represents the dash style of the line. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - * - * @param base64EncodedImage A string that is a Base64 encoding of the image data. - */ - setImage(base64EncodedImage: string): void; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * [Api set: PowerPointApi 1.8] */ - load(options?: PowerPoint.Interfaces.SlideBackgroundPictureOrTextureFillLoadOptions): PowerPoint.SlideBackgroundPictureOrTextureFill; + dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundPictureOrTextureFill; + transparency?: number | undefined; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Represents the weight of the line, in points. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.SlideBackgroundPictureOrTextureFill; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideBackgroundPictureOrTextureFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundPictureOrTextureFillData`) that contains shallow copies of any loaded child properties from the original object. + * @remarks + * [Api set: PowerPointApi 1.8] */ - toJSON(): PowerPoint.Interfaces.SlideBackgroundPictureOrTextureFillData; + weight?: number | undefined; } /** - * Represents {@link PowerPoint.SlideBackground} picture or texture fill options. + * Represents the borders of a table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - interface SlideBackgroundPictureOrTextureFillOptions { + interface TableCellBorders { /** - * If provided, specifies the Base64-encoded image data for the fill. + * Represents the bottom border. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - imageBase64?: string; + bottom?: PowerPoint.BorderProperties; /** - * If provided, specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). + * Represents the diagonal border (top-left to bottom-right). * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - transparency: number; - } - /** - * Specifies the fill type for a {@link PowerPoint.SlideBackground}. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - enum SlideBackgroundFillType { + diagonalDown?: PowerPoint.BorderProperties; /** - * Unsupported slide background fill. + * Represents the diagonal border (bottom-left to top-right). + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - unsupported = "Unsupported", - /** - * Specifies that the slide background should have regular solid fill. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - solid = "Solid", + diagonalUp?: PowerPoint.BorderProperties; /** - * Specifies that the slide background should have gradient fill. + * Represents the left border. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - gradient = "Gradient", + left?: PowerPoint.BorderProperties; /** - * Specifies that the slide background should have picture or texture fill. + * Represents the right border. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - pictureOrTexture = "PictureOrTexture", + right?: PowerPoint.BorderProperties; /** - * Specifies that the slide background should have pattern fill. + * Represents the top border. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - pattern = "Pattern", + top?: PowerPoint.BorderProperties; } /** - * Represents {@link PowerPoint.SlideBackground} solid fill properties. + * Represents the margins of a table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - class SlideBackgroundSolidFill extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + interface TableCellMargins { /** - * Specifies the fill color in HTML color format (e.g., "#FFA500" or "orange"). + * Specifies the bottom margin in points. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - color: string; + bottom?: number | undefined; /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). + * Specifies the left margin in points. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - transparency: number; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * [Api set: PowerPointApi 1.8] */ - load(options?: PowerPoint.Interfaces.SlideBackgroundSolidFillLoadOptions): PowerPoint.SlideBackgroundSolidFill; + left?: number | undefined; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies the right margin in points. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundSolidFill; + right?: number | undefined; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies the top margin in points. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.SlideBackgroundSolidFill; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideBackgroundSolidFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundSolidFillData`) that contains shallow copies of any loaded child properties from the original object. + * @remarks + * [Api set: PowerPointApi 1.8] */ - toJSON(): PowerPoint.Interfaces.SlideBackgroundSolidFillData; + top?: number | undefined; } /** - * Represents the available options for setting a {@link PowerPoint.SlideBackground} solid fill. + * Represents the table cell properties to update. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - interface SlideBackgroundSolidFillOptions { + interface TableCellProperties { /** - * If provided, specifies the fill color in HTML color format (e.g., "#FFA500" or "orange"). + * Specifies the border formatting of the table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - color?: string; + borders?: PowerPoint.TableCellBorders; /** - * If provided, specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). + * Specifies the fill formatting of the table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - transparency?: number; - } - /** - * Represents the fill formatting of a slide background object. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - class SlideBackgroundFill extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + fill?: PowerPoint.FillProperties; /** - * Returns the fill type of the slide background. See {@link PowerPoint.SlideBackgroundFillType} for details. + * Specifies the font formatting of the table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - readonly type: PowerPoint.SlideBackgroundFillType | "Unsupported" | "Solid" | "Gradient" | "PictureOrTexture" | "Pattern"; + font?: PowerPoint.FontProperties; /** - * Gets the gradient fill properties. If the fill type is not `gradient`, an object with an `isNullObject` property set to `true` is returned. - For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * Specifies the horizontal alignment of the text in the table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - getGradientFillOrNullObject(): PowerPoint.SlideBackgroundGradientFill; + horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | undefined; /** - * Gets the pattern fill properties. If the fill type is not `pattern`, an object with an `isNullObject` property set to `true` is returned. - For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * Specifies the indent level of the text in the table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - getPatternFillOrNullObject(): PowerPoint.SlideBackgroundPatternFill; + indentLevel?: number | undefined; /** - * Gets the picture or texture fill properties. If the fill type is not `pictureOrTexture`, an object with an `isNullObject` property set to `true` is returned. - For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * Specifies the margin settings in the table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - getPictureOrTextureFillOrNullObject(): PowerPoint.SlideBackgroundPictureOrTextureFill; + margins?: PowerPoint.TableCellMargins; /** - * Gets the solid fill properties. If the fill type is not `solid`, an object with an `isNullObject` property set to `true` is returned. - For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * Specifies the text content of the table cell. + + If a portion of the text requires different formatting, use the `textRuns` property instead. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - getSolidFillOrNullObject(): PowerPoint.SlideBackgroundSolidFill; + text?: string; /** - * Sets the fill formatting of the slide background to a gradient fill. This changes the fill type to `gradient`. + * Specifies the contents of the table cell as an array of {@link TextRun} objects. + Each `TextRun` object represents a sequence of one or more characters that share the same font attributes. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - * - * @param options Options for the gradient fill. + * [Api set: PowerPointApi 1.8] */ - setGradientFill(options?: PowerPoint.SlideBackgroundGradientFillOptions): void; + textRuns?: PowerPoint.TextRun[]; /** - * Sets the fill formatting of the slide background to a pattern fill. This changes the fill type to `pattern`. + * Specifies the vertical alignment of the text in the table cell. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - * - * @param options Options for the pattern fill. + * [Api set: PowerPointApi 1.8] */ - setPatternFill(options?: PowerPoint.SlideBackgroundPatternFillOptions): void; + verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered" | undefined; + } + /** + * Provides the table column properties. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface TableColumnProperties { /** - * Sets the fill formatting of the slide background to a picture or texture fill. This changes the fill type to `pictureOrTexture`. + * Represents the desired width of each column in points, or is undefined. + + When a table is being added, for columns whose width is undefined, + the column width will be calculated by evenly dividing the remaining width + of the table amongst those columns. If the table doesn't have a defined width, + a default column width will be used. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - * - * @param options Options for the picture or texture fill. + * [Api set: PowerPointApi 1.8] */ - setPictureOrTextureFill(options?: PowerPoint.SlideBackgroundPictureOrTextureFillOptions): void; + columnWidth?: number | undefined; + } + /** + * Represents the properties of a merged area of cells in a table. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface TableMergedAreaProperties { /** - * Sets the fill formatting of the slide background to a solid fill. This changes the fill type to `solid`. + * Specifies the number of columns for the merged cells area. + Must be 1 or greater. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - * - * @param options Options for the solid fill. + * [Api set: PowerPointApi 1.8] */ - setSolidFill(options?: PowerPoint.SlideBackgroundSolidFillOptions): void; + columnCount: number; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies the zero-based index of the column of the top left cell of the merged area. * - * @param options Provides options for which properties of the object to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(options?: PowerPoint.Interfaces.SlideBackgroundFillLoadOptions): PowerPoint.SlideBackgroundFill; + columnIndex: number; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies the number of rows for the merged cells area. + Must be 1 or greater. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundFill; + rowCount: number; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies the zero-based index of the row of the top left cell of the merged area. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.SlideBackgroundFill; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideBackgroundFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundFillData`) that contains shallow copies of any loaded child properties from the original object. + * @remarks + * [Api set: PowerPointApi 1.8] */ - toJSON(): PowerPoint.Interfaces.SlideBackgroundFillData; + rowIndex: number; } /** - * Represents a background of a slide. + * Provides the table row properties. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - class SlideBackground extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + interface TableRowProperties { /** - * Returns the fill formatting of the background. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Represents the desired height of each row in points, or is undefined. + + When a table is being added, for rows whose height is undefined, + the row height will be calculated by evenly dividing the remaining height + of the table amongst those rows. If the table doesn't have a defined height, + a default row height will be used. + * + * @remarks + * [Api set: PowerPointApi 1.8] */ - readonly fill: PowerPoint.SlideBackgroundFill; + rowHeight?: number | undefined; + } + /** + * Represents the available options when adding a table. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface TableAddOptions { /** - * Specifies whether the slide layout background fill hides or displays background graphic objects from the slide master. + * If provided, specifies properties for each column in the table. + The array length must be equal to the number of columns in the table. + Specify an empty object for columns that should use the default formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - areBackgroundGraphicsHidden: boolean; + columns?: PowerPoint.TableColumnProperties[]; /** - * Specifies if the slide background follows the slide master background. + * Specifies the height, in points, of the table. + A default value is used when this parameter isn't provided. + Throws an `InvalidArgument` exception when set with a negative value. + + Note: If the table height isn't evenly divisible by the number of rows, PowerPoint sets it to the nearest possible value. + For example, a height of 400 for 3 rows may result in an actual height of 399.9999. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - isMasterBackgroundFollowed: boolean; + height?: number | undefined; /** - * Resets the fill formatting of the slide background. + * Specifies the distance, in points, from the left side of the table to the left side of the slide. + The table is centered horizontally when this parameter isn't provided. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - reset(): void; + left?: number | undefined; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * If specified, represents an rectangular area where multiple cells appear as a single cell. * - * @param options Provides options for which properties of the object to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(options?: PowerPoint.Interfaces.SlideBackgroundLoadOptions): PowerPoint.SlideBackground; + mergedAreas?: PowerPoint.TableMergedAreaProperties[]; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * If provided, specifies properties for each row in the table. + The array length must be equal to the number of rows in the table. + Specify an empty object for rows that should use the default formatting. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNames?: string | string[]): PowerPoint.SlideBackground; + rows?: PowerPoint.TableRowProperties[]; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * If provided, specifies properties for each cell in the table. + + This should be a 2D array with the same number of rows and columns as the table. + If a cell doesn't require specific formatting, specify an empty object for that cell. + Only the top left cell of a merged are can have properties specified, which will be applied + to the entire merged area. For the other cells in the merged area, an empty object should be provided. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.SlideBackground; + specificCellProperties?: PowerPoint.TableCellProperties[][]; /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideBackground` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundData`) that contains shallow copies of any loaded child properties from the original object. + * Specifies value that represents the table style. + * + * @remarks + * [Api set: PowerPointApi 1.9] */ - toJSON(): PowerPoint.Interfaces.SlideBackgroundData; - } - /** - * Represents the available options when getting an image of a slide. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface SlideGetImageOptions { + style?: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; /** - * The desired height of the resulting image in pixels. + * Specifies the distance, in points, from the top edge of the table to the top edge of the slide. + A default value is used when this parameter isn't provided. * * @remarks * [Api set: PowerPointApi 1.8] */ - height?: number; + top?: number | undefined; /** - * The desired width of the resulting image in pixels. + * Specifies the formatting which applies uniformly to all of the table cells. + + To apply specific formatting to individual cells, use `specificCellProperties`. + + If both uniformCellProperties and specificCellProperties are undefined, the default formatting + will be used, and the default table style will be applied. The table will have the same + appearance as when the user adds a table through the PowerPoint UI. + + To provide a plain appearance for the table, set this property to an empty object + and don't specify `specificCellProperties`. * * @remarks * [Api set: PowerPointApi 1.8] */ - width?: number; + uniformCellProperties?: PowerPoint.TableCellProperties; + /** + * If provided, specifies the values for the table. + + When the table contains areas of merged cells, + only the top left cell of each merged area can have a + non-empty string value. The other cells + in the merged area must be an empty string. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + values?: string[][]; + /** + * Specifies the width, in points, of the table. + A default value is used when this parameter isn't provided. + Throws an `InvalidArgument` exception when set with a negative value. + + Note: If the table width isn't evenly divisible by the number of columns, PowerPoint sets it to the nearest possible value. + For example, a width of 400 for 3 columns may result in an actual width of 399.9999. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + width?: number | undefined; } /** - * Represents the background of a slide layout. + * Represents the collection of shapes. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.3] */ - class SlideLayoutBackground extends OfficeExtension.ClientObject { + class ShapeCollection extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.Shape[]; /** - * Returns the fill formatting of the background. + * Adds a geometric shape to the slide. Returns a `Shape` object that represents the new shape. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.4] + * + * @param geometricShapeType Specifies the type of the geometric shape. See {@link PowerPoint.GeometricShapeType} for details. + * @param options An optional parameter to specify the additional options such as the position of the shape. + * @returns The newly inserted shape. */ - readonly fill: PowerPoint.SlideBackgroundFill; + addGeometricShape(geometricShapeType: PowerPoint.GeometricShapeType, options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; /** - * Specifies whether the slide layout background fill hides or displays background graphic objects from the slide master. + * Adds a geometric shape to the slide. Returns a `Shape` object that represents the new shape. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.4] + * + * @param geometricShapeType Specifies the type of the geometric shape. See {@link PowerPoint.GeometricShapeType} for details. + * @param options An optional parameter to specify the additional options such as the position of the shape. + * @returns The newly inserted shape. */ - areBackgroundGraphicsHidden: boolean; + addGeometricShape(geometricShapeType: "LineInverse" | "Triangle" | "RightTriangle" | "Rectangle" | "Diamond" | "Parallelogram" | "Trapezoid" | "NonIsoscelesTrapezoid" | "Pentagon" | "Hexagon" | "Heptagon" | "Octagon" | "Decagon" | "Dodecagon" | "Star4" | "Star5" | "Star6" | "Star7" | "Star8" | "Star10" | "Star12" | "Star16" | "Star24" | "Star32" | "RoundRectangle" | "Round1Rectangle" | "Round2SameRectangle" | "Round2DiagonalRectangle" | "SnipRoundRectangle" | "Snip1Rectangle" | "Snip2SameRectangle" | "Snip2DiagonalRectangle" | "Plaque" | "Ellipse" | "Teardrop" | "HomePlate" | "Chevron" | "PieWedge" | "Pie" | "BlockArc" | "Donut" | "NoSmoking" | "RightArrow" | "LeftArrow" | "UpArrow" | "DownArrow" | "StripedRightArrow" | "NotchedRightArrow" | "BentUpArrow" | "LeftRightArrow" | "UpDownArrow" | "LeftUpArrow" | "LeftRightUpArrow" | "QuadArrow" | "LeftArrowCallout" | "RightArrowCallout" | "UpArrowCallout" | "DownArrowCallout" | "LeftRightArrowCallout" | "UpDownArrowCallout" | "QuadArrowCallout" | "BentArrow" | "UturnArrow" | "CircularArrow" | "LeftCircularArrow" | "LeftRightCircularArrow" | "CurvedRightArrow" | "CurvedLeftArrow" | "CurvedUpArrow" | "CurvedDownArrow" | "SwooshArrow" | "Cube" | "Can" | "LightningBolt" | "Heart" | "Sun" | "Moon" | "SmileyFace" | "IrregularSeal1" | "IrregularSeal2" | "FoldedCorner" | "Bevel" | "Frame" | "HalfFrame" | "Corner" | "DiagonalStripe" | "Chord" | "Arc" | "LeftBracket" | "RightBracket" | "LeftBrace" | "RightBrace" | "BracketPair" | "BracePair" | "Callout1" | "Callout2" | "Callout3" | "AccentCallout1" | "AccentCallout2" | "AccentCallout3" | "BorderCallout1" | "BorderCallout2" | "BorderCallout3" | "AccentBorderCallout1" | "AccentBorderCallout2" | "AccentBorderCallout3" | "WedgeRectCallout" | "WedgeRRectCallout" | "WedgeEllipseCallout" | "CloudCallout" | "Cloud" | "Ribbon" | "Ribbon2" | "EllipseRibbon" | "EllipseRibbon2" | "LeftRightRibbon" | "VerticalScroll" | "HorizontalScroll" | "Wave" | "DoubleWave" | "Plus" | "FlowChartProcess" | "FlowChartDecision" | "FlowChartInputOutput" | "FlowChartPredefinedProcess" | "FlowChartInternalStorage" | "FlowChartDocument" | "FlowChartMultidocument" | "FlowChartTerminator" | "FlowChartPreparation" | "FlowChartManualInput" | "FlowChartManualOperation" | "FlowChartConnector" | "FlowChartPunchedCard" | "FlowChartPunchedTape" | "FlowChartSummingJunction" | "FlowChartOr" | "FlowChartCollate" | "FlowChartSort" | "FlowChartExtract" | "FlowChartMerge" | "FlowChartOfflineStorage" | "FlowChartOnlineStorage" | "FlowChartMagneticTape" | "FlowChartMagneticDisk" | "FlowChartMagneticDrum" | "FlowChartDisplay" | "FlowChartDelay" | "FlowChartAlternateProcess" | "FlowChartOffpageConnector" | "ActionButtonBlank" | "ActionButtonHome" | "ActionButtonHelp" | "ActionButtonInformation" | "ActionButtonForwardNext" | "ActionButtonBackPrevious" | "ActionButtonEnd" | "ActionButtonBeginning" | "ActionButtonReturn" | "ActionButtonDocument" | "ActionButtonSound" | "ActionButtonMovie" | "Gear6" | "Gear9" | "Funnel" | "MathPlus" | "MathMinus" | "MathMultiply" | "MathDivide" | "MathEqual" | "MathNotEqual" | "CornerTabs" | "SquareTabs" | "PlaqueTabs" | "ChartX" | "ChartStar" | "ChartPlus", options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; /** - * Specifies if the slide layout background follows the slide master background. + * Create a shape group for several shapes. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] + * + * @param values An array of shape IDs or `Shape` objects. + * @returns A `Shape` object that represents the shape group. Use the `Shape.group` property to access the `ShapeGroup` object for the group. */ - isMasterBackgroundFollowed: boolean; + addGroup(values: Array): PowerPoint.Shape; /** - * Resets the fill formatting of the slide layout background. + * Adds a line to the slide. Returns a `Shape` object that represents the new line. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - reset(): void; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * [Api set: PowerPointApi 1.4] * - * @param options Provides options for which properties of the object to load. + * @param connectorType Specifies the connector type of the line. If not provided, `straight` connector type will be used. See {@link PowerPoint.ConnectorType} for details. + * @param options An optional parameter to specify the additional options such as the position of the shape object that contains the line. + * @returns The newly inserted shape. */ - load(options?: PowerPoint.Interfaces.SlideLayoutBackgroundLoadOptions): PowerPoint.SlideLayoutBackground; + addLine(connectorType?: PowerPoint.ConnectorType, options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Adds a line to the slide. Returns a `Shape` object that represents the new line. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.SlideLayoutBackground; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * @remarks + * [Api set: PowerPointApi 1.4] * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.SlideLayoutBackground; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideLayoutBackground` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideLayoutBackgroundData`) that contains shallow copies of any loaded child properties from the original object. + * @param connectorType Specifies the connector type of the line. If not provided, `straight` connector type will be used. See {@link PowerPoint.ConnectorType} for details. + * @param options An optional parameter to specify the additional options such as the position of the shape object that contains the line. + * @returns The newly inserted shape. */ - toJSON(): PowerPoint.Interfaces.SlideLayoutBackgroundData; - } - /** - * Specifies the type of a slide layout. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - enum SlideLayoutType { + addLine(connectorType?: "Straight" | "Elbow" | "Curve", options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; /** - * Blank layout. + * Adds a table to the slide. Returns a `Shape` object that represents the new table. + Use the `Shape.table` property to get the `Table` object for the shape. + * * @remarks * [Api set: PowerPointApi 1.8] + * + * @param rowCount Number of rows in the table. Must be 1 or greater. + * @param columnCount Number of columns in the table. Must be 1 or greater. + * @param options Provides options describing the new table. + * @returns The newly inserted shape. */ - blank = "Blank", + addTable(rowCount: number, columnCount: number, options?: PowerPoint.TableAddOptions): PowerPoint.Shape; /** - * Chart layout. + * Adds a text box to the slide with the provided text as the content. Returns a `Shape` object that represents the new text box. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] + * + * @param text Specifies the text that will be shown in the created text box. + * @param options An optional parameter to specify the additional options such as the position of the text box. + * @returns The newly inserted shape. */ - chart = "Chart", + addTextBox(text: string, options?: PowerPoint.ShapeAddOptions): PowerPoint.Shape; /** - * Chart and text layout. + * Gets the number of shapes in the collection. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.3] + * @returns The number of shapes in the collection. */ - chartAndText = "ChartAndText", + getCount(): OfficeExtension.ClientResult; /** - * ClipArt and text layout. + * Gets a shape using its unique ID. An error is thrown if the shape doesn't exist. + * * @remarks - * [Api set: PowerPointApi 1.8] - */ - clipArtAndText = "ClipArtAndText", + * [Api set: PowerPointApi 1.3] + * + * @param key The ID of the shape. + * @returns The shape with the unique ID. If such a shape doesn't exist, an error is thrown. + */ + getItem(key: string): PowerPoint.Shape; /** - * ClipArt and vertical text layout. + * Gets a shape using its zero-based index in the collection. An error is thrown if the index is out of range. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.3] + * + * @param index The index of the shape in the collection. + * @returns The shape at the given index. An error is thrown if index is out of range. */ - clipArtAndVerticalText = "ClipArtAndVerticalText", + getItemAt(index: number): PowerPoint.Shape; /** - * Comparison layout. + * Gets a shape using its unique ID. If such a shape doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.3] + * + * @param id The ID of the shape. + * @returns The shape with the unique ID. If such a shape doesn't exist, an object with an `isNullObject` property set to true is returned. */ - comparison = "Comparison", + getItemOrNullObject(id: string): PowerPoint.Shape; /** - * Content with caption layout. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - contentWithCaption = "ContentWithCaption", + load(options?: PowerPoint.Interfaces.ShapeCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.ShapeCollection; /** - * Custom layout. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - custom = "Custom", + load(propertyNames?: string | string[]): PowerPoint.ShapeCollection; /** - * Four objects layout. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - fourObjects = "FourObjects", + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.ShapeCollection; /** - * Large object layout. - * @remarks - * [Api set: PowerPointApi 1.8] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.ShapeCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - largeObject = "LargeObject", + toJSON(): PowerPoint.Interfaces.ShapeCollectionData; + } + /** + * Specifies the gradient fill type for a {@link PowerPoint.SlideBackgroundGradientFill}. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + enum SlideBackgroundGradientFillType { /** - * MediaClip and text layout. + * Unsupported gradient fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - mediaClipAndText = "MediaClipAndText", + unsupported = "Unsupported", /** - * Mixed layout. + * Linear gradient fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - mixed = "Mixed", + linear = "Linear", /** - * Object layout. + * Radial gradient fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - object = "Object", + radial = "Radial", /** - * Object and text layout. + * Rectangular gradient fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - objectAndText = "ObjectAndText", + rectangular = "Rectangular", /** - * Object and two objects layout. + * Path gradient fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - objectAndTwoObjects = "ObjectAndTwoObjects", + path = "Path", /** - * Object over text layout. + * Shade from title gradient fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - objectOverText = "ObjectOverText", + shadeFromTitle = "ShadeFromTitle", + } + /** + * Represents {@link PowerPoint.SlideBackground} gradient fill properties. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + class SlideBackgroundGradientFill extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Organization chart layout. + * Specifies the type of gradient fill. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - organizationChart = "OrganizationChart", + type: PowerPoint.SlideBackgroundGradientFillType | "Unsupported" | "Linear" | "Radial" | "Rectangular" | "Path" | "ShadeFromTitle"; /** - * Picture with caption layout. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - pictureWithCaption = "PictureWithCaption", + load(options?: PowerPoint.Interfaces.SlideBackgroundGradientFillLoadOptions): PowerPoint.SlideBackgroundGradientFill; /** - * Section header layout. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - sectionHeader = "SectionHeader", + load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundGradientFill; /** - * Table layout. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - table = "Table", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.SlideBackgroundGradientFill; /** - * Text layout. - * @remarks - * [Api set: PowerPointApi 1.8] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.SlideBackgroundGradientFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundGradientFillData`) that contains shallow copies of any loaded child properties from the original object. */ - text = "Text", + toJSON(): PowerPoint.Interfaces.SlideBackgroundGradientFillData; + } + /** + * Represents the available options for setting a {@link PowerPoint.SlideBackground} gradient fill. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + interface SlideBackgroundGradientFillOptions { /** - * Text and chart layout. + * If provided, specifies the type of gradient fill. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - textAndChart = "TextAndChart", + type?: PowerPoint.SlideBackgroundGradientFillType | "Unsupported" | "Linear" | "Radial" | "Rectangular" | "Path" | "ShadeFromTitle"; + } + /** + * Specifies the pattern fill type for a {@link PowerPoint.SlideBackgroundPatternFill}. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + enum SlideBackgroundPatternFillType { /** - * Text and ClipArt layout. + * Unsupported pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - textAndClipArt = "TextAndClipArt", + unsupported = "Unsupported", /** - * Text and MediaClip layout. + * 5 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - textAndMediaClip = "TextAndMediaClip", + percent5 = "Percent5", /** - * Text and object layout. + * 10 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - textAndObject = "TextAndObject", + percent10 = "Percent10", /** - * Text and two objects layout. + * 20 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - textAndTwoObjects = "TextAndTwoObjects", + percent20 = "Percent20", /** - * Text over object layout. + * 25 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - textOverObject = "TextOverObject", + percent25 = "Percent25", /** - * Title layout. + * 30 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - title = "Title", + percent30 = "Percent30", /** - * Title only layout. + * 40 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - titleOnly = "TitleOnly", + percent40 = "Percent40", /** - * Two-column text layout. + * 50 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - twoColumnText = "TwoColumnText", + percent50 = "Percent50", /** - * Two objects layout. + * 60 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - twoObjects = "TwoObjects", + percent60 = "Percent60", /** - * Two objects and object layout. + * 70 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - twoObjectsAndObject = "TwoObjectsAndObject", + percent70 = "Percent70", /** - * Two objects and text layout. + * 75 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - twoObjectsAndText = "TwoObjectsAndText", + percent75 = "Percent75", /** - * Two objects over text layout. + * 80 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - twoObjectsOverText = "TwoObjectsOverText", + percent80 = "Percent80", /** - * Vertical text layout. + * 90 percent pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - verticalText = "VerticalText", + percent90 = "Percent90", /** - * Vertical title and text layout. + * Horizontal pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - verticalTitleAndText = "VerticalTitleAndText", + horizontal = "Horizontal", /** - * Vertical title and text over chart layout. + * Vertical pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - verticalTitleAndTextOverChart = "VerticalTitleAndTextOverChart", - } - /** - * Specifies the theme colors used in PowerPoint. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - enum ThemeColor { + vertical = "Vertical", /** - * Specifies a mixed theme color. + * Light horizontal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - mixed = "Mixed", + lightHorizontal = "LightHorizontal", /** - * Specifies no theme color. + * Light vertical pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - none = "None", + lightVertical = "LightVertical", /** - * Specifies the Accent 1 theme color. + * Dark horizontal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - accent1 = "Accent1", + darkHorizontal = "DarkHorizontal", /** - * Specifies the Accent 2 theme color. + * Dark vertical pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - accent2 = "Accent2", + darkVertical = "DarkVertical", /** - * Specifies the Accent 3 theme color. + * Narrow horizontal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - accent3 = "Accent3", + narrowHorizontal = "NarrowHorizontal", /** - * Specifies the Accent 4 theme color. + * Narrow vertical pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - accent4 = "Accent4", + narrowVertical = "NarrowVertical", /** - * Specifies the Accent 5 theme color. + * Dashed horizontal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - accent5 = "Accent5", + dashedHorizontal = "DashedHorizontal", /** - * Specifies the Accent 6 theme color. + * Dashed vertical pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - accent6 = "Accent6", + dashedVertical = "DashedVertical", /** - * Specifies the Dark 1 theme color. + * Cross pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - dark1 = "Dark1", + cross = "Cross", /** - * Specifies the Dark 2 theme color. + * Downward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - dark2 = "Dark2", + downwardDiagonal = "DownwardDiagonal", /** - * Specifies the clicked hyperlink theme color. + * Upward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - followedHyperlink = "FollowedHyperlink", + upwardDiagonal = "UpwardDiagonal", /** - * Specifies the hyperlink theme color. + * Light downward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - hyperlink = "Hyperlink", + lightDownwardDiagonal = "LightDownwardDiagonal", /** - * Specifies the Light 1 theme color. + * Light upward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - light1 = "Light1", + lightUpwardDiagonal = "LightUpwardDiagonal", /** - * Specifies the Light 2 theme color. + * Dark downward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - light2 = "Light2", - } - /** - * Represents a theme color scheme. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - class ThemeColorScheme extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + darkDownwardDiagonal = "DarkDownwardDiagonal", /** - * Gets the color value for the specified `ThemeColor`. - * + * Dark upward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta - * - * @param color The theme color. - * @returns The color value in #RRGGBB format (e.g., "FFA500"). */ - getThemeColor(color: PowerPoint.ThemeColor): OfficeExtension.ClientResult; + darkUpwardDiagonal = "DarkUpwardDiagonal", /** - * Gets the color value for the specified `ThemeColor`. - * + * Wide downward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta - * - * @param color The theme color. - * @returns The color value in #RRGGBB format (e.g., "FFA500"). */ - getThemeColor(color: "Mixed" | "None" | "Accent1" | "Accent2" | "Accent3" | "Accent4" | "Accent5" | "Accent6" | "Dark1" | "Dark2" | "FollowedHyperlink" | "Hyperlink" | "Light1" | "Light2"): OfficeExtension.ClientResult; + wideDownwardDiagonal = "WideDownwardDiagonal", /** - * Sets the color value for the specified `ThemeColor`. - * + * Wide upward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta - * - * @param color The theme color. - * @param rgbColor The color value in #RRGGBB format (e.g., "FFA500") or as a named HTML color (e.g., "orange"). */ - setThemeColor(color: PowerPoint.ThemeColor, rgbColor: string): void; + wideUpwardDiagonal = "WideUpwardDiagonal", /** - * Sets the color value for the specified `ThemeColor`. - * + * Dashed downward diagonal pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta - * - * @param color The theme color. - * @param rgbColor The color value in #RRGGBB format (e.g., "FFA500") or as a named HTML color (e.g., "orange"). */ - setThemeColor(color: "Mixed" | "None" | "Accent1" | "Accent2" | "Accent3" | "Accent4" | "Accent5" | "Accent6" | "Dark1" | "Dark2" | "FollowedHyperlink" | "Hyperlink" | "Light1" | "Light2", rgbColor: string): void; + dashedDownwardDiagonal = "DashedDownwardDiagonal", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ThemeColorScheme` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ThemeColorSchemeData`) that contains shallow copies of any loaded child properties from the original object. + * Dashed upward diagonal pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - toJSON(): { - [key: string]: string; - }; - } - /** - * Represents the layout of a slide. - * - * @remarks - * [Api set: PowerPointApi 1.3] - */ - class SlideLayout extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + dashedUpwardDiagonal = "DashedUpwardDiagonal", /** - * Gets the background of the slide layout. - * + * Diagonal cross pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - readonly background: PowerPoint.SlideLayoutBackground; + diagonalCross = "DiagonalCross", /** - * Returns a collection of custom XML parts in the slide layout. - * + * Small checker board pattern fill. * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly customXmlParts: PowerPoint.CustomXmlPartCollection; + smallCheckerBoard = "SmallCheckerBoard", /** - * Returns a collection of shapes in the slide layout. - * + * Large checker board pattern fill. * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly shapes: PowerPoint.ShapeCollection; + largeCheckerBoard = "LargeCheckerBoard", /** - * Returns the `ThemeColorScheme` of the slide layout. - * + * Small grid pattern fill. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - readonly themeColorScheme: PowerPoint.ThemeColorScheme; + smallGrid = "SmallGrid", /** - * Gets the unique ID of the slide layout. - * + * Large grid pattern fill. * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly id: string; + largeGrid = "LargeGrid", /** - * Gets the name of the slide layout. - * + * Dotted grid pattern fill. * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly name: string; + dottedGrid = "DottedGrid", /** - * Returns the type of the slide layout. - * + * Small confetti pattern fill. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly type: PowerPoint.SlideLayoutType | "Blank" | "Chart" | "ChartAndText" | "ClipArtAndText" | "ClipArtAndVerticalText" | "Comparison" | "ContentWithCaption" | "Custom" | "FourObjects" | "LargeObject" | "MediaClipAndText" | "Mixed" | "Object" | "ObjectAndText" | "ObjectAndTwoObjects" | "ObjectOverText" | "OrganizationChart" | "PictureWithCaption" | "SectionHeader" | "Table" | "Text" | "TextAndChart" | "TextAndClipArt" | "TextAndMediaClip" | "TextAndObject" | "TextAndTwoObjects" | "TextOverObject" | "Title" | "TitleOnly" | "TwoColumnText" | "TwoObjects" | "TwoObjectsAndObject" | "TwoObjectsAndText" | "TwoObjectsOverText" | "VerticalText" | "VerticalTitleAndText" | "VerticalTitleAndTextOverChart"; + smallConfetti = "SmallConfetti", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Large confetti pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(options?: PowerPoint.Interfaces.SlideLayoutLoadOptions): PowerPoint.SlideLayout; + largeConfetti = "LargeConfetti", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Horizontal brick pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNames?: string | string[]): PowerPoint.SlideLayout; + horizontalBrick = "HorizontalBrick", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Diagonal brick pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.SlideLayout; + diagonalBrick = "DiagonalBrick", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideLayout` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideLayoutData`) that contains shallow copies of any loaded child properties from the original object. + * Solid diamond pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - toJSON(): PowerPoint.Interfaces.SlideLayoutData; - } - /** - * Represents the collection of layouts provided by the Slide Master for slides. - * - * @remarks - * [Api set: PowerPointApi 1.3] - */ - class SlideLayoutCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.SlideLayout[]; + solidDiamond = "SolidDiamond", /** - * Gets the number of layouts in the collection. - * + * Outlined diamond pattern fill. * @remarks - * [Api set: PowerPointApi 1.3] - * @returns The number of layouts in the collection. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - getCount(): OfficeExtension.ClientResult; + outlinedDiamond = "OutlinedDiamond", /** - * Gets a layout using its unique ID. - * + * Dotted diamond pattern fill. * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param key The ID of the layout. - * @returns The layout with the unique ID. If such a layout doesn't exist, an error is thrown. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - getItem(key: string): PowerPoint.SlideLayout; + dottedDiamond = "DottedDiamond", /** - * Gets a layout using its zero-based index in the collection. - * + * Plaid pattern fill. * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param index The index of the layout in the collection. - * @returns The layout at the given index. An error is thrown if index is out of range. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - getItemAt(index: number): PowerPoint.SlideLayout; + plaid = "Plaid", /** - * Gets a layout using its unique ID. If such a layout doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, - see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. - * + * Sphere pattern fill. * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param id The ID of the layout. - * @returns The layout with the unique ID. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - getItemOrNullObject(id: string): PowerPoint.SlideLayout; + sphere = "Sphere", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Weave pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(options?: PowerPoint.Interfaces.SlideLayoutCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.SlideLayoutCollection; + weave = "Weave", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Divot pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNames?: string | string[]): PowerPoint.SlideLayoutCollection; + divot = "Divot", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Shingle pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.SlideLayoutCollection; + shingle = "Shingle", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideLayoutCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideLayoutCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Wave pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - toJSON(): PowerPoint.Interfaces.SlideLayoutCollectionData; + wave = "Wave", + /** + * Trellis pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + trellis = "Trellis", + /** + * Zig zag pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + zigZag = "ZigZag", } /** - * Represents the background of a slide master. + * Represents {@link PowerPoint.SlideBackground} pattern fill properties. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - class SlideMasterBackground extends OfficeExtension.ClientObject { + class SlideBackgroundPatternFill extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Returns the fill formatting of the background. + * Specifies the background color in HTML color format (e.g., "#FFFFFF" or "white"). * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - readonly fill: PowerPoint.SlideBackgroundFill; + backgroundColor: string; + /** + * Specifies the foreground color in HTML color format (e.g., "#FFA500" or "orange"). + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + foregroundColor: string; + /** + * Specifies the pattern type. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + pattern: PowerPoint.SlideBackgroundPatternFillType | "Unsupported" | "Percent5" | "Percent10" | "Percent20" | "Percent25" | "Percent30" | "Percent40" | "Percent50" | "Percent60" | "Percent70" | "Percent75" | "Percent80" | "Percent90" | "Horizontal" | "Vertical" | "LightHorizontal" | "LightVertical" | "DarkHorizontal" | "DarkVertical" | "NarrowHorizontal" | "NarrowVertical" | "DashedHorizontal" | "DashedVertical" | "Cross" | "DownwardDiagonal" | "UpwardDiagonal" | "LightDownwardDiagonal" | "LightUpwardDiagonal" | "DarkDownwardDiagonal" | "DarkUpwardDiagonal" | "WideDownwardDiagonal" | "WideUpwardDiagonal" | "DashedDownwardDiagonal" | "DashedUpwardDiagonal" | "DiagonalCross" | "SmallCheckerBoard" | "LargeCheckerBoard" | "SmallGrid" | "LargeGrid" | "DottedGrid" | "SmallConfetti" | "LargeConfetti" | "HorizontalBrick" | "DiagonalBrick" | "SolidDiamond" | "OutlinedDiamond" | "DottedDiamond" | "Plaid" | "Sphere" | "Weave" | "Divot" | "Shingle" | "Wave" | "Trellis" | "ZigZag"; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.SlideMasterBackgroundLoadOptions): PowerPoint.SlideMasterBackground; + load(options?: PowerPoint.Interfaces.SlideBackgroundPatternFillLoadOptions): PowerPoint.SlideBackgroundPatternFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.SlideMasterBackground; + load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundPatternFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -188047,85 +187891,86 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.SlideMasterBackground; + }): PowerPoint.SlideBackgroundPatternFill; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideMasterBackground` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideMasterBackgroundData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.SlideBackgroundPatternFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundPatternFillData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.SlideMasterBackgroundData; + toJSON(): PowerPoint.Interfaces.SlideBackgroundPatternFillData; } /** - * Represents the Slide Master of a slide. + * Represents the available options for setting a {@link PowerPoint.SlideBackground} pattern fill. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - class SlideMaster extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + interface SlideBackgroundPatternFillOptions { /** - * Gets the background of the Slide Master. + * If provided, specifies the background color in HTML color format (e.g., "#FFFFFF" or "white"). * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - readonly background: PowerPoint.SlideMasterBackground; - /** - * Returns a collection of custom XML parts in the Slide Master. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - readonly customXmlParts: PowerPoint.CustomXmlPartCollection; + backgroundColor?: string; /** - * Gets the collection of layouts provided by the Slide Master for slides. + * If provided, specifies the foreground color in HTML color format (e.g., "#FFA500" or "orange"). * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly layouts: PowerPoint.SlideLayoutCollection; + foregroundColor?: string; /** - * Returns a collection of shapes in the Slide Master. + * If provided, specifies the pattern type. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly shapes: PowerPoint.ShapeCollection; + pattern?: PowerPoint.SlideBackgroundPatternFillType | "Unsupported" | "Percent5" | "Percent10" | "Percent20" | "Percent25" | "Percent30" | "Percent40" | "Percent50" | "Percent60" | "Percent70" | "Percent75" | "Percent80" | "Percent90" | "Horizontal" | "Vertical" | "LightHorizontal" | "LightVertical" | "DarkHorizontal" | "DarkVertical" | "NarrowHorizontal" | "NarrowVertical" | "DashedHorizontal" | "DashedVertical" | "Cross" | "DownwardDiagonal" | "UpwardDiagonal" | "LightDownwardDiagonal" | "LightUpwardDiagonal" | "DarkDownwardDiagonal" | "DarkUpwardDiagonal" | "WideDownwardDiagonal" | "WideUpwardDiagonal" | "DashedDownwardDiagonal" | "DashedUpwardDiagonal" | "DiagonalCross" | "SmallCheckerBoard" | "LargeCheckerBoard" | "SmallGrid" | "LargeGrid" | "DottedGrid" | "SmallConfetti" | "LargeConfetti" | "HorizontalBrick" | "DiagonalBrick" | "SolidDiamond" | "OutlinedDiamond" | "DottedDiamond" | "Plaid" | "Sphere" | "Weave" | "Divot" | "Shingle" | "Wave" | "Trellis" | "ZigZag"; + } + /** + * Represents {@link PowerPoint.SlideBackground} picture or texture fill properties. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + class SlideBackgroundPictureOrTextureFill extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Returns the `ThemeColorScheme` of the Slide Master. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - readonly themeColorScheme: PowerPoint.ThemeColorScheme; + transparency: number; /** - * Gets the unique ID of the Slide Master. + * Sets the image used to fill. * * @remarks - * [Api set: PowerPointApi 1.3] - */ - readonly id: string; - /** - * Gets the unique name of the Slide Master. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta * - * @remarks - * [Api set: PowerPointApi 1.3] + * @param base64EncodedImage A string that is a Base64 encoding of the image data. */ - readonly name: string; + setImage(base64EncodedImage: string): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.SlideMasterLoadOptions): PowerPoint.SlideMaster; + load(options?: PowerPoint.Interfaces.SlideBackgroundPictureOrTextureFillLoadOptions): PowerPoint.SlideBackgroundPictureOrTextureFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.SlideMaster; + load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundPictureOrTextureFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -188134,303 +187979,266 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.SlideMaster; + }): PowerPoint.SlideBackgroundPictureOrTextureFill; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideMaster` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideMasterData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.SlideBackgroundPictureOrTextureFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundPictureOrTextureFillData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.SlideMasterData; + toJSON(): PowerPoint.Interfaces.SlideBackgroundPictureOrTextureFillData; } /** - * Represents a single tag in the slide. + * Represents {@link PowerPoint.SlideBackground} picture or texture fill options. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - class Tag extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + interface SlideBackgroundPictureOrTextureFillOptions { /** - * Gets the unique ID of the tag. The `key` is unique within the owning `TagCollection` and always stored as uppercase letters within the document. + * If provided, specifies the Base64-encoded image data for the fill. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly key: string; + imageBase64?: string; /** - * Gets the value of the tag. + * If provided, specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - value: string; + transparency: number; + } + /** + * Specifies the fill type for a {@link PowerPoint.SlideBackground}. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + enum SlideBackgroundFillType { /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Unsupported slide background fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(options?: PowerPoint.Interfaces.TagLoadOptions): PowerPoint.Tag; + unsupported = "Unsupported", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Specifies that the slide background should have regular solid fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNames?: string | string[]): PowerPoint.Tag; + solid = "Solid", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Specifies that the slide background should have gradient fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Tag; + gradient = "Gradient", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Tag` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TagData`) that contains shallow copies of any loaded child properties from the original object. + * Specifies that the slide background should have picture or texture fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - toJSON(): PowerPoint.Interfaces.TagData; + pictureOrTexture = "PictureOrTexture", + /** + * Specifies that the slide background should have pattern fill. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + pattern = "Pattern", } /** - * Represents the collection of tags. + * Represents {@link PowerPoint.SlideBackground} solid fill properties. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - class TagCollection extends OfficeExtension.ClientObject { + class SlideBackgroundSolidFill extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.Tag[]; - /** - * Adds a new tag at the end of the collection. If the `key` already exists in the collection, the value of the existing tag will be replaced with the given `value`. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param key The unique ID of a tag, which is unique within this `TagCollection`. 'key' parameter is case-insensitive, but it's always capitalized when saved in the document. - * @param value The value of the tag. - */ - add(key: string, value: string): void; - /** - * Deletes the tag with the given `key` in this collection. Does nothing if the `key` doesn't exist. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param key The unique ID of a tag, which is unique within this `TagCollection`. `key` parameter is case-insensitive. - */ - delete(key: string): void; - /** - * Gets the number of tags in the collection. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * @returns The number of tags in the collection. - */ - getCount(): OfficeExtension.ClientResult; - /** - * Gets a tag using its unique ID. An error is thrown if the tag doesn't exist. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param key The ID of the tag. - * @returns The tag with the unique ID. If such a tag doesn't exist, an error is thrown. - */ - getItem(key: string): PowerPoint.Tag; /** - * Gets a tag using its zero-based index in the collection. An error is thrown if the index is out of range. + * Specifies the fill color in HTML color format (e.g., "#FFA500" or "orange"). * * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param index The index of the tag in the collection. - * @returns The tag at the given index. An error is thrown if index is out of range. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - getItemAt(index: number): PowerPoint.Tag; + color: string; /** - * Gets a tag using its unique ID. If such a tag doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). * * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param key The ID of the tag. - * @returns The tag with the unique ID. If such a tag doesn't exist, an object with an `isNullObject` property set to true is returned. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - getItemOrNullObject(key: string): PowerPoint.Tag; + transparency: number; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TagCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TagCollection; + load(options?: PowerPoint.Interfaces.SlideBackgroundSolidFillLoadOptions): PowerPoint.SlideBackgroundSolidFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TagCollection; + load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundSolidFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TagCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.SlideBackgroundSolidFill; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TagCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TagCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Whereas the original `PowerPoint.SlideBackgroundSolidFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundSolidFillData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TagCollectionData; + toJSON(): PowerPoint.Interfaces.SlideBackgroundSolidFillData; } /** - * Represents a single slide of a presentation. + * Represents the available options for setting a {@link PowerPoint.SlideBackground} solid fill. * * @remarks - * [Api set: PowerPointApi 1.2] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - class Slide extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + interface SlideBackgroundSolidFillOptions { /** - * Gets the background of the slide. + * If provided, specifies the fill color in HTML color format (e.g., "#FFA500" or "orange"). * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - readonly background: PowerPoint.SlideBackground; - /** - * Returns a collection of custom XML parts in the slide. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - readonly customXmlParts: PowerPoint.CustomXmlPartCollection; - /** - * Returns a collection of hyperlinks in the slide. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - readonly hyperlinks: PowerPoint.HyperlinkCollection; - /** - * Gets the layout of the slide. - * - * @remarks - * [Api set: PowerPointApi 1.3] - */ - readonly layout: PowerPoint.SlideLayout; - /** - * Returns a collection of shapes in the slide. - * - * @remarks - * [Api set: PowerPointApi 1.3] - */ - readonly shapes: PowerPoint.ShapeCollection; + color?: string; /** - * Gets the `SlideMaster` object that represents the slide's default content. + * If provided, specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly slideMaster: PowerPoint.SlideMaster; + transparency?: number; + } + /** + * Represents the fill formatting of a slide background object. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + class SlideBackgroundFill extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Returns a collection of tags in the slide. + * Returns the fill type of the slide background. See {@link PowerPoint.SlideBackgroundFillType} for details. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly tags: PowerPoint.TagCollection; + readonly type: PowerPoint.SlideBackgroundFillType | "Unsupported" | "Solid" | "Gradient" | "PictureOrTexture" | "Pattern"; /** - * Returns the `ThemeColorScheme` of the slide. + * Gets the gradient fill properties. If the fill type is not `gradient`, an object with an `isNullObject` property set to `true` is returned. + For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - readonly themeColorScheme: PowerPoint.ThemeColorScheme; + getGradientFillOrNullObject(): PowerPoint.SlideBackgroundGradientFill; /** - * Gets the unique ID of the slide. + * Gets the pattern fill properties. If the fill type is not `pattern`, an object with an `isNullObject` property set to `true` is returned. + For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.2] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly id: string; + getPatternFillOrNullObject(): PowerPoint.SlideBackgroundPatternFill; /** - * Returns the zero-based index of the slide representing its position in the presentation. + * Gets the picture or texture fill properties. If the fill type is not `pictureOrTexture`, an object with an `isNullObject` property set to `true` is returned. + For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly index: number; + getPictureOrTextureFillOrNullObject(): PowerPoint.SlideBackgroundPictureOrTextureFill; /** - * Applies the specified layout to the slide, changing its design and structure according to the chosen layout. + * Gets the solid fill properties. If the fill type is not `solid`, an object with an `isNullObject` property set to `true` is returned. + For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param slideLayout The layout to be applied to the slide. This is typically an instance of a predefined layout from the slide master. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - applyLayout(slideLayout: PowerPoint.SlideLayout): void; + getSolidFillOrNullObject(): PowerPoint.SlideBackgroundSolidFill; /** - * Deletes the slide from the presentation. Does nothing if the slide doesn't exist. + * Sets the fill formatting of the slide background to a gradient fill. This changes the fill type to `gradient`. * * @remarks - * [Api set: PowerPointApi 1.2] - */ - delete(): void; - /** - * Exports the slide to its own presentation file, returned as Base64-encoded data. + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta * - * @remarks - * [Api set: PowerPointApi 1.8] - * - * This method is optimized to export a single slide. Exporting multiple slides can impact performance. + * @param options Options for the gradient fill. */ - exportAsBase64(): OfficeExtension.ClientResult; + setGradientFill(options?: PowerPoint.SlideBackgroundGradientFillOptions): void; /** - * Renders an image of the slide. The image is scaled to fit into the desired dimensions. - If width and height aren't specified, the true size of the slide is used. If only one - of either width or height is specified, the other will be calculated to preserve aspect ratio. + * Sets the fill formatting of the slide background to a pattern fill. This changes the fill type to `pattern`. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta * - * @param options Optional. Options to specify the desired size of the slide image. - * @returns A Base64-encoded string of the slide image in PNG format. + * @param options Options for the pattern fill. */ - getImageAsBase64(options?: PowerPoint.SlideGetImageOptions): OfficeExtension.ClientResult; + setPatternFill(options?: PowerPoint.SlideBackgroundPatternFillOptions): void; /** - * Moves the slide to a new position within the presentation. + * Sets the fill formatting of the slide background to a picture or texture fill. This changes the fill type to `pictureOrTexture`. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta * - * @param slideIndex The zero-based index where the slide should be moved. + * @param options Options for the picture or texture fill. */ - moveTo(slideIndex: number): void; + setPictureOrTextureFill(options?: PowerPoint.SlideBackgroundPictureOrTextureFillOptions): void; /** - * Selects the specified shapes. Existing shape selection is replaced with the new selection. + * Sets the fill formatting of the slide background to a solid fill. This changes the fill type to `solid`. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta * - * @param shapeIds List of shape IDs to select in the slide. If the list is empty, the selection is cleared. + * @param options Options for the solid fill. */ - setSelectedShapes(shapeIds: string[]): void; + setSolidFill(options?: PowerPoint.SlideBackgroundSolidFillOptions): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.SlideLoadOptions): PowerPoint.Slide; + load(options?: PowerPoint.Interfaces.SlideBackgroundFillLoadOptions): PowerPoint.SlideBackgroundFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.Slide; + load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -188439,198 +188247,158 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.Slide; + }): PowerPoint.SlideBackgroundFill; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Slide` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.SlideBackgroundFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundFillData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.SlideData; + toJSON(): PowerPoint.Interfaces.SlideBackgroundFillData; } /** - * Represents the format of an image. + * Represents a background of a slide. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - enum ShapeGetImageFormatType { + class SlideBackground extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * The picture is in PNG format. + * Returns the fill formatting of the background. + * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - png = "Png", - } - /** - * Represents the available options when getting an image of a shape. - The image is scaled to fit into the desired dimensions. If width and height aren't specified, the true size of the shape is used. - If only one of either width or height is specified, the other will be calculated to preserve aspect ratio. - The resulting dimensions will automatically be clamped to the maximum supported size if too large. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - interface ShapeGetImageOptions { + readonly fill: PowerPoint.SlideBackgroundFill; /** - * The desired format of the resulting image. + * Specifies whether the slide layout background fill hides or displays background graphic objects from the slide master. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - format?: PowerPoint.ShapeGetImageFormatType | "Png"; + areBackgroundGraphicsHidden: boolean; /** - * The desired height of the resulting image in pixels. This value will automatically be clamped to the maximum supported size if too large. - Throws an `InvalidArgument` exception when set with a non-positive integer. + * Specifies if the slide background follows the slide master background. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - height?: number; + isMasterBackgroundFollowed: boolean; /** - * The desired width of the resulting image in pixels. This value will automatically be clamped to the maximum supported size if too large. - Throws an `InvalidArgument` exception when set with a non-positive integer. + * Resets the fill formatting of the slide background. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - width?: number; - } - /** - * Represents a collection of shapes. - * - * @remarks - * [Api set: PowerPointApi 1.5] - */ - class ShapeScopedCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.Shape[]; - /** - * Gets the number of shapes in the collection. - * - * @remarks - * [Api set: PowerPointApi 1.5] - * @returns The number of shapes in the collection. - */ - getCount(): OfficeExtension.ClientResult; - /** - * Gets a shape using its unique ID. An error is thrown if the shape doesn't exist. - * - * @remarks - * [Api set: PowerPointApi 1.5] - * - * @param key The ID of the shape. - * @returns The shape with the unique ID. If such a shape doesn't exist, an error is thrown. - */ - getItem(key: string): PowerPoint.Shape; - /** - * Gets a shape using its zero-based index in the collection. An error is thrown if the index is out of range. - * - * @remarks - * [Api set: PowerPointApi 1.5] - * - * @param index The index of the shape in the collection. - * @returns The shape at the given index. An error is thrown if index is out of range. - */ - getItemAt(index: number): PowerPoint.Shape; - /** - * Gets a shape using its unique ID. If such a shape doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. - * - * @remarks - * [Api set: PowerPointApi 1.5] - * - * @param id The ID of the shape. - * @returns The shape with the unique ID. If such a shape doesn't exist, an object with an `isNullObject` property set to true is returned. - */ - getItemOrNullObject(id: string): PowerPoint.Shape; - /** - * Groups all shapes in this collection into a single shape. - If the collection contains fewer than two shapes, then this method returns the `GeneralException` error. - * - * @remarks - * [Api set: PowerPointApi 1.8] - * @returns The newly created grouped shape as a {@link PowerPoint.Shape}. - */ - group(): PowerPoint.Shape; + reset(): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.ShapeScopedCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.ShapeScopedCollection; + load(options?: PowerPoint.Interfaces.SlideBackgroundLoadOptions): PowerPoint.SlideBackground; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.ShapeScopedCollection; + load(propertyNames?: string | string[]): PowerPoint.SlideBackground; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.ShapeScopedCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.SlideBackground; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ShapeScopedCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeScopedCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Whereas the original `PowerPoint.SlideBackground` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideBackgroundData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.ShapeScopedCollectionData; + toJSON(): PowerPoint.Interfaces.SlideBackgroundData; } /** - * Represents a shape group inside a presentation. To get the corresponding Shape object, use `ShapeGroup.shape`. + * Represents the available options when getting an image of a slide. * * @remarks * [Api set: PowerPointApi 1.8] */ - class ShapeGroup extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + interface SlideGetImageOptions { /** - * Returns the `Shape` object associated with the group. + * The desired height of the resulting image in pixels. * * @remarks * [Api set: PowerPointApi 1.8] */ - readonly shape: PowerPoint.Shape; + height?: number; /** - * Returns the collection of `Shape` objects in the group. + * The desired width of the resulting image in pixels. * * @remarks * [Api set: PowerPointApi 1.8] */ - readonly shapes: PowerPoint.ShapeScopedCollection; + width?: number; + } + /** + * Represents the background of a slide layout. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + class SlideLayoutBackground extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Gets the unique ID of the shape group. + * Returns the fill formatting of the background. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - readonly id: string; + readonly fill: PowerPoint.SlideBackgroundFill; /** - * Ungroups any grouped shapes in the specified shape group. + * Specifies whether the slide layout background fill hides or displays background graphic objects from the slide master. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - ungroup(): void; + areBackgroundGraphicsHidden: boolean; + /** + * Specifies if the slide layout background follows the slide master background. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + isMasterBackgroundFollowed: boolean; + /** + * Resets the fill formatting of the slide layout background. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + reset(): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.ShapeGroupLoadOptions): PowerPoint.ShapeGroup; + load(options?: PowerPoint.Interfaces.SlideLayoutBackgroundLoadOptions): PowerPoint.SlideLayoutBackground; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.ShapeGroup; + load(propertyNames?: string | string[]): PowerPoint.SlideLayoutBackground; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -188639,702 +188407,1203 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ShapeGroup; + }): PowerPoint.SlideLayoutBackground; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ShapeGroup` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeGroupData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.SlideLayoutBackground` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideLayoutBackgroundData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.ShapeGroupData; + toJSON(): PowerPoint.Interfaces.SlideLayoutBackgroundData; } /** - * Specifies the style for a line. + * Specifies the type of a slide layout. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - enum ShapeLineStyle { + enum SlideLayoutType { /** - * Single line. + * Blank layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - single = "Single", + blank = "Blank", /** - * Thick line with a thin line on each side. + * Chart layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - thickBetweenThin = "ThickBetweenThin", + chart = "Chart", /** - * Thick line next to thin line. For horizontal lines, the thick line is above the thin line. For vertical lines, the thick line is to the left of the thin line. + * Chart and text layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - thickThin = "ThickThin", + chartAndText = "ChartAndText", /** - * Thick line next to thin line. For horizontal lines, the thick line is below the thin line. For vertical lines, the thick line is to the right of the thin line. + * ClipArt and text layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - thinThick = "ThinThick", + clipArtAndText = "ClipArtAndText", /** - * Two thin lines. + * ClipArt and vertical text layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - thinThin = "ThinThin", - } - /** - * Represents the line formatting for the shape object. For images and geometric shapes, line formatting represents the border of the shape. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - class ShapeLineFormat extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + clipArtAndVerticalText = "ClipArtAndVerticalText", /** - * Represents the line color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). - * + * Comparison layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - color: string; + comparison = "Comparison", /** - * Represents the dash style of the line. Returns null when the line isn't visible or there are inconsistent dash styles. See {@link PowerPoint.ShapeLineDashStyle} for details. - * + * Content with caption layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - dashStyle: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot"; + contentWithCaption = "ContentWithCaption", /** - * Represents the line style of the shape. Returns null when the line isn't visible or there are inconsistent styles. See {@link PowerPoint.ShapeLineStyle} for details. - * + * Custom layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - style: PowerPoint.ShapeLineStyle | "Single" | "ThickBetweenThin" | "ThickThin" | "ThinThick" | "ThinThin"; + custom = "Custom", /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). Returns null when the shape has inconsistent transparencies. - * + * Four objects layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - transparency: number; + fourObjects = "FourObjects", /** - * Specifies if the line formatting of a shape element is visible. Returns `null` when the shape has inconsistent visibilities. - * + * Large object layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - visible: boolean; + largeObject = "LargeObject", /** - * Represents the weight of the line, in points. Returns `null` when the line isn't visible or there are inconsistent line weights. - * + * MediaClip and text layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - weight: number; + mediaClipAndText = "MediaClipAndText", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Mixed layout. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(options?: PowerPoint.Interfaces.ShapeLineFormatLoadOptions): PowerPoint.ShapeLineFormat; + mixed = "Mixed", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Object layout. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNames?: string | string[]): PowerPoint.ShapeLineFormat; + object = "Object", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Object and text layout. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.ShapeLineFormat; + objectAndText = "ObjectAndText", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ShapeLineFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeLineFormatData`) that contains shallow copies of any loaded child properties from the original object. + * Object and two objects layout. + * @remarks + * [Api set: PowerPointApi 1.8] */ - toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; - } - /** - * Determines the type of automatic sizing allowed. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ShapeAutoSize { + objectAndTwoObjects = "ObjectAndTwoObjects", /** - * No autosizing. + * Object over text layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeNone = "AutoSizeNone", + objectOverText = "ObjectOverText", /** - * The text is adjusted to fit the shape. + * Organization chart layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeTextToFitShape = "AutoSizeTextToFitShape", + organizationChart = "OrganizationChart", /** - * The shape is adjusted to fit the text. + * Picture with caption layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeShapeToFitText = "AutoSizeShapeToFitText", + pictureWithCaption = "PictureWithCaption", /** - * A combination of automatic sizing schemes are used. + * Section header layout. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeMixed = "AutoSizeMixed", - } - /** - * Specifies the style of a bullet. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - enum BulletStyle { + sectionHeader = "SectionHeader", /** - * Style is unsupported. + * Table layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - unsupported = "Unsupported", + table = "Table", /** - * Lowercase alphabetical characters with a period. + * Text layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - alphabetLowercasePeriod = "AlphabetLowercasePeriod", + text = "Text", /** - * Uppercase alphabetical characters with a period. + * Text and chart layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - alphabetUppercasePeriod = "AlphabetUppercasePeriod", + textAndChart = "TextAndChart", /** - * Arabic numerals with closing parenthesis. + * Text and ClipArt layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - arabicNumeralParenthesisRight = "ArabicNumeralParenthesisRight", + textAndClipArt = "TextAndClipArt", /** - * Arabic numerals with a period. + * Text and MediaClip layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - arabicNumeralPeriod = "ArabicNumeralPeriod", + textAndMediaClip = "TextAndMediaClip", /** - * Lowercase Roman numerals with both parentheses. + * Text and object layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - romanLowercaseParenthesesBoth = "RomanLowercaseParenthesesBoth", + textAndObject = "TextAndObject", /** - * Lowercase Roman numerals with closing parenthesis. + * Text and two objects layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - romanLowercaseParenthesisRight = "RomanLowercaseParenthesisRight", + textAndTwoObjects = "TextAndTwoObjects", /** - * Lowercase Roman numerals with period. + * Text over object layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - romanLowercasePeriod = "RomanLowercasePeriod", + textOverObject = "TextOverObject", /** - * Uppercase Roman numerals with period. + * Title layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - romanUppercasePeriod = "RomanUppercasePeriod", + title = "Title", /** - * Lowercase alphabetical characters with both parentheses. + * Title only layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - alphabetLowercaseParenthesesBoth = "AlphabetLowercaseParenthesesBoth", + titleOnly = "TitleOnly", /** - * Lowercase alphabetical characters with closing parenthesis. + * Two-column text layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - alphabetLowercaseParenthesisRight = "AlphabetLowercaseParenthesisRight", + twoColumnText = "TwoColumnText", /** - * Uppercase alphabetical characters with both parentheses. + * Two objects layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - alphabetUppercaseParenthesesBoth = "AlphabetUppercaseParenthesesBoth", + twoObjects = "TwoObjects", /** - * Uppercase alphabetical characters with closing parenthesis. + * Two objects and object layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - alphabetUppercaseParenthesisRight = "AlphabetUppercaseParenthesisRight", + twoObjectsAndObject = "TwoObjectsAndObject", /** - * Arabic numerals with both parentheses. + * Two objects and text layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - arabicNumeralParenthesesBoth = "ArabicNumeralParenthesesBoth", + twoObjectsAndText = "TwoObjectsAndText", /** - * Arabic numerals. + * Two objects over text layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - arabicNumeralPlain = "ArabicNumeralPlain", + twoObjectsOverText = "TwoObjectsOverText", /** - * Uppercase Roman numerals with both parentheses. + * Vertical text layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - romanUppercaseParenthesesBoth = "RomanUppercaseParenthesesBoth", + verticalText = "VerticalText", /** - * Uppercase Roman numerals with closing parenthesis. + * Vertical title and text layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - romanUppercaseParenthesisRight = "RomanUppercaseParenthesisRight", + verticalTitleAndText = "VerticalTitleAndText", /** - * Simplified Chinese without a period. + * Vertical title and text over chart layout. * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - simplifiedChinesePlain = "SimplifiedChinesePlain", + verticalTitleAndTextOverChart = "VerticalTitleAndTextOverChart", + } + /** + * Specifies the theme colors used in PowerPoint. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + enum ThemeColor { /** - * Simplified Chinese with a period. + * Specifies a mixed theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - simplifiedChinesePeriod = "SimplifiedChinesePeriod", + mixed = "Mixed", /** - * Double-byte circled number for values up to 10. + * Specifies no theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - circleNumberDoubleBytePlain = "CircleNumberDoubleBytePlain", + none = "None", /** - * Text colored number with same color circle drawn around it. + * Specifies the Accent 1 theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - circleNumberWideDoubleByteWhitePlain = "CircleNumberWideDoubleByteWhitePlain", + accent1 = "Accent1", /** - * Shadow color number with circular background of normal text color. + * Specifies the Accent 2 theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - circleNumberWideDoubleByteBlackPlain = "CircleNumberWideDoubleByteBlackPlain", + accent2 = "Accent2", /** - * Traditional Chinese without a period. + * Specifies the Accent 3 theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - traditionalChinesePlain = "TraditionalChinesePlain", + accent3 = "Accent3", /** - * Traditional Chinese with a period. + * Specifies the Accent 4 theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - traditionalChinesePeriod = "TraditionalChinesePeriod", + accent4 = "Accent4", /** - * Arabic alphabet with a dash. + * Specifies the Accent 5 theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - arabicAlphabetDash = "ArabicAlphabetDash", + accent5 = "Accent5", /** - * Arabic Abjad alphabet with a dash. + * Specifies the Accent 6 theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - arabicAbjadDash = "ArabicAbjadDash", + accent6 = "Accent6", /** - * Hebrew alphabet with a dash. + * Specifies the Dark 1 theme color. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - hebrewAlphabetDash = "HebrewAlphabetDash", + dark1 = "Dark1", + /** + * Specifies the Dark 2 theme color. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + dark2 = "Dark2", + /** + * Specifies the clicked hyperlink theme color. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + followedHyperlink = "FollowedHyperlink", + /** + * Specifies the hyperlink theme color. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + hyperlink = "Hyperlink", + /** + * Specifies the Light 1 theme color. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + light1 = "Light1", + /** + * Specifies the Light 2 theme color. + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + light2 = "Light2", + } + /** + * Represents a theme color scheme. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + class ThemeColorScheme extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Gets the color value for the specified `ThemeColor`. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param color The theme color. + * @returns The color value in #RRGGBB format (e.g., "FFA500"). + */ + getThemeColor(color: PowerPoint.ThemeColor): OfficeExtension.ClientResult; + /** + * Gets the color value for the specified `ThemeColor`. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param color The theme color. + * @returns The color value in #RRGGBB format (e.g., "FFA500"). + */ + getThemeColor(color: "Mixed" | "None" | "Accent1" | "Accent2" | "Accent3" | "Accent4" | "Accent5" | "Accent6" | "Dark1" | "Dark2" | "FollowedHyperlink" | "Hyperlink" | "Light1" | "Light2"): OfficeExtension.ClientResult; + /** + * Sets the color value for the specified `ThemeColor`. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param color The theme color. + * @param rgbColor The color value in #RRGGBB format (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + */ + setThemeColor(color: PowerPoint.ThemeColor, rgbColor: string): void; + /** + * Sets the color value for the specified `ThemeColor`. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param color The theme color. + * @param rgbColor The color value in #RRGGBB format (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + */ + setThemeColor(color: "Mixed" | "None" | "Accent1" | "Accent2" | "Accent3" | "Accent4" | "Accent5" | "Accent6" | "Dark1" | "Dark2" | "FollowedHyperlink" | "Hyperlink" | "Light1" | "Light2", rgbColor: string): void; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.ThemeColorScheme` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ThemeColorSchemeData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): { + [key: string]: string; + }; + } + /** + * Represents the layout of a slide. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + class SlideLayout extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Gets the background of the slide layout. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + readonly background: PowerPoint.SlideLayoutBackground; + /** + * Returns a collection of custom XML parts in the slide layout. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + readonly customXmlParts: PowerPoint.CustomXmlPartCollection; + /** + * Returns a collection of shapes in the slide layout. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly shapes: PowerPoint.ShapeCollection; + /** + * Returns the `ThemeColorScheme` of the slide layout. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + readonly themeColorScheme: PowerPoint.ThemeColorScheme; + /** + * Gets the unique ID of the slide layout. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly id: string; + /** + * Gets the name of the slide layout. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly name: string; + /** + * Returns the type of the slide layout. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + readonly type: PowerPoint.SlideLayoutType | "Blank" | "Chart" | "ChartAndText" | "ClipArtAndText" | "ClipArtAndVerticalText" | "Comparison" | "ContentWithCaption" | "Custom" | "FourObjects" | "LargeObject" | "MediaClipAndText" | "Mixed" | "Object" | "ObjectAndText" | "ObjectAndTwoObjects" | "ObjectOverText" | "OrganizationChart" | "PictureWithCaption" | "SectionHeader" | "Table" | "Text" | "TextAndChart" | "TextAndClipArt" | "TextAndMediaClip" | "TextAndObject" | "TextAndTwoObjects" | "TextOverObject" | "Title" | "TitleOnly" | "TwoColumnText" | "TwoObjects" | "TwoObjectsAndObject" | "TwoObjectsAndText" | "TwoObjectsOverText" | "VerticalText" | "VerticalTitleAndText" | "VerticalTitleAndTextOverChart"; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.SlideLayoutLoadOptions): PowerPoint.SlideLayout; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.SlideLayout; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.SlideLayout; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.SlideLayout` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideLayoutData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.SlideLayoutData; + } + /** + * Represents the collection of layouts provided by the Slide Master for slides. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + class SlideLayoutCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.SlideLayout[]; + /** + * Gets the number of layouts in the collection. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * @returns The number of layouts in the collection. + */ + getCount(): OfficeExtension.ClientResult; + /** + * Gets a layout using its unique ID. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * + * @param key The ID of the layout. + * @returns The layout with the unique ID. If such a layout doesn't exist, an error is thrown. + */ + getItem(key: string): PowerPoint.SlideLayout; + /** + * Gets a layout using its zero-based index in the collection. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * + * @param index The index of the layout in the collection. + * @returns The layout at the given index. An error is thrown if index is out of range. + */ + getItemAt(index: number): PowerPoint.SlideLayout; + /** + * Gets a layout using its unique ID. If such a layout doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, + see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * + * @param id The ID of the layout. + * @returns The layout with the unique ID. + */ + getItemOrNullObject(id: string): PowerPoint.SlideLayout; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.SlideLayoutCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.SlideLayoutCollection; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.SlideLayoutCollection; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.SlideLayoutCollection; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.SlideLayoutCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideLayoutCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + */ + toJSON(): PowerPoint.Interfaces.SlideLayoutCollectionData; + } + /** + * Represents the background of a slide master. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + class SlideMasterBackground extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Returns the fill formatting of the background. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + readonly fill: PowerPoint.SlideBackgroundFill; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.SlideMasterBackgroundLoadOptions): PowerPoint.SlideMasterBackground; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.SlideMasterBackground; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.SlideMasterBackground; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.SlideMasterBackground` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideMasterBackgroundData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.SlideMasterBackgroundData; + } + /** + * Represents the Slide Master of a slide. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + class SlideMaster extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Gets the background of the Slide Master. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + readonly background: PowerPoint.SlideMasterBackground; + /** + * Returns a collection of custom XML parts in the Slide Master. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + readonly customXmlParts: PowerPoint.CustomXmlPartCollection; + /** + * Gets the collection of layouts provided by the Slide Master for slides. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly layouts: PowerPoint.SlideLayoutCollection; /** - * Japanese/Korean numbers without a period. + * Returns a collection of shapes in the Slide Master. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly shapes: PowerPoint.ShapeCollection; + /** + * Returns the `ThemeColorScheme` of the Slide Master. + * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - kanjiKoreanPlain = "KanjiKoreanPlain", + readonly themeColorScheme: PowerPoint.ThemeColorScheme; /** - * Japanese/Korean numbers with a period. + * Gets the unique ID of the Slide Master. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly id: string; + /** + * Gets the unique name of the Slide Master. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly name: string; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.SlideMasterLoadOptions): PowerPoint.SlideMaster; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.SlideMaster; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.SlideMaster; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.SlideMaster` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideMasterData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.SlideMasterData; + } + /** + * Represents a single tag in the slide. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + class Tag extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Gets the unique ID of the tag. The `key` is unique within the owning `TagCollection` and always stored as uppercase letters within the document. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly key: string; + /** + * Gets the value of the tag. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + value: string; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.TagLoadOptions): PowerPoint.Tag; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.Tag; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Tag; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.Tag` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TagData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.TagData; + } + /** + * Represents the collection of tags. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + class TagCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.Tag[]; + /** + * Adds a new tag at the end of the collection. If the `key` already exists in the collection, the value of the existing tag will be replaced with the given `value`. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * + * @param key The unique ID of a tag, which is unique within this `TagCollection`. 'key' parameter is case-insensitive, but it's always capitalized when saved in the document. + * @param value The value of the tag. + */ + add(key: string, value: string): void; + /** + * Deletes the tag with the given `key` in this collection. Does nothing if the `key` doesn't exist. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * + * @param key The unique ID of a tag, which is unique within this `TagCollection`. `key` parameter is case-insensitive. + */ + delete(key: string): void; + /** + * Gets the number of tags in the collection. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * @returns The number of tags in the collection. + */ + getCount(): OfficeExtension.ClientResult; + /** + * Gets a tag using its unique ID. An error is thrown if the tag doesn't exist. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * + * @param key The ID of the tag. + * @returns The tag with the unique ID. If such a tag doesn't exist, an error is thrown. + */ + getItem(key: string): PowerPoint.Tag; + /** + * Gets a tag using its zero-based index in the collection. An error is thrown if the index is out of range. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * + * @param index The index of the tag in the collection. + * @returns The tag at the given index. An error is thrown if index is out of range. + */ + getItemAt(index: number): PowerPoint.Tag; + /** + * Gets a tag using its unique ID. If such a tag doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * + * @remarks + * [Api set: PowerPointApi 1.3] + * + * @param key The ID of the tag. + * @returns The tag with the unique ID. If such a tag doesn't exist, an object with an `isNullObject` property set to true is returned. + */ + getItemOrNullObject(key: string): PowerPoint.Tag; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.TagCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TagCollection; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.TagCollection; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TagCollection; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TagCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TagCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + */ + toJSON(): PowerPoint.Interfaces.TagCollectionData; + } + /** + * Represents a single slide of a presentation. + * + * @remarks + * [Api set: PowerPointApi 1.2] + */ + class Slide extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Gets the background of the slide. + * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - kanjiKoreanPeriod = "KanjiKoreanPeriod", + readonly background: PowerPoint.SlideBackground; + /** + * Returns a collection of custom XML parts in the slide. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + readonly customXmlParts: PowerPoint.CustomXmlPartCollection; + /** + * Returns a collection of hyperlinks in the slide. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + readonly hyperlinks: PowerPoint.HyperlinkCollection; + /** + * Gets the layout of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly layout: PowerPoint.SlideLayout; + /** + * Returns a collection of shapes in the slide. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly shapes: PowerPoint.ShapeCollection; + /** + * Gets the `SlideMaster` object that represents the slide's default content. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly slideMaster: PowerPoint.SlideMaster; + /** + * Returns a collection of tags in the slide. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly tags: PowerPoint.TagCollection; /** - * Double-byte Arabic numbering scheme (no punctuation). + * Returns the `ThemeColorScheme` of the slide. + * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - arabicDoubleBytePlain = "ArabicDoubleBytePlain", + readonly themeColorScheme: PowerPoint.ThemeColorScheme; /** - * Double-byte Arabic numbering scheme with double-byte period. + * Gets the unique ID of the slide. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.2] */ - arabicDoubleBytePeriod = "ArabicDoubleBytePeriod", + readonly id: string; /** - * Thai alphabet with a period. + * Returns the zero-based index of the slide representing its position in the presentation. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - thaiAlphabetPeriod = "ThaiAlphabetPeriod", + readonly index: number; /** - * Thai alphabet with closing parenthesis. + * Applies the specified layout to the slide, changing its design and structure according to the chosen layout. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] + * + * @param slideLayout The layout to be applied to the slide. This is typically an instance of a predefined layout from the slide master. */ - thaiAlphabetParenthesisRight = "ThaiAlphabetParenthesisRight", + applyLayout(slideLayout: PowerPoint.SlideLayout): void; /** - * Thai alphabet with both parentheses. + * Deletes the slide from the presentation. Does nothing if the slide doesn't exist. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.2] */ - thaiAlphabetParenthesesBoth = "ThaiAlphabetParenthesesBoth", + delete(): void; /** - * Thai numerals with a period. + * Exports the slide to its own presentation file, returned as Base64-encoded data. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] + * + * This method is optimized to export a single slide. Exporting multiple slides can impact performance. */ - thaiNumeralPeriod = "ThaiNumeralPeriod", + exportAsBase64(): OfficeExtension.ClientResult; /** - * Thai numerals with closing parenthesis. + * Renders an image of the slide. The image is scaled to fit into the desired dimensions. + If width and height aren't specified, the true size of the slide is used. If only one + of either width or height is specified, the other will be calculated to preserve aspect ratio. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] + * + * @param options Optional. Options to specify the desired size of the slide image. + * @returns A Base64-encoded string of the slide image in PNG format. */ - thaiNumeralParenthesisRight = "ThaiNumeralParenthesisRight", + getImageAsBase64(options?: PowerPoint.SlideGetImageOptions): OfficeExtension.ClientResult; /** - * Thai numerals with both parentheses. + * Moves the slide to a new position within the presentation. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] + * + * @param slideIndex The zero-based index where the slide should be moved. */ - thaiNumeralParenthesesBoth = "ThaiNumeralParenthesesBoth", + moveTo(slideIndex: number): void; /** - * Hindi alphabet (vowels) with a period. + * Selects the specified shapes. Existing shape selection is replaced with the new selection. + * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.5] + * + * @param shapeIds List of shape IDs to select in the slide. If the list is empty, the selection is cleared. */ - hindiAlphabetPeriod = "HindiAlphabetPeriod", + setSelectedShapes(shapeIds: string[]): void; /** - * Hindi numerals with a period. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - hindiNumeralPeriod = "HindiNumeralPeriod", + load(options?: PowerPoint.Interfaces.SlideLoadOptions): PowerPoint.Slide; /** - * Kanji Simplified Chinese with double-byte period. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - kanjiSimplifiedChineseDoubleBytePeriod = "KanjiSimplifiedChineseDoubleBytePeriod", + load(propertyNames?: string | string[]): PowerPoint.Slide; /** - * Hindi numerals with closing parenthesis. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - hindiNumeralParenthesisRight = "HindiNumeralParenthesisRight", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Slide; /** - * Hindi alphabet (consonants) with a period. - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.Slide` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideData`) that contains shallow copies of any loaded child properties from the original object. */ - hindiAlphabet1Period = "HindiAlphabet1Period", + toJSON(): PowerPoint.Interfaces.SlideData; } /** - * Specifies the type of a bullet. + * Represents the format of an image. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - enum BulletType { + enum ShapeGetImageFormatType { /** - * Type is unsupported. + * The picture is in PNG format. * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - unsupported = "Unsupported", + png = "Png", + } + /** + * Represents the available options when getting an image of a shape. + The image is scaled to fit into the desired dimensions. If width and height aren't specified, the true size of the shape is used. + If only one of either width or height is specified, the other will be calculated to preserve aspect ratio. + The resulting dimensions will automatically be clamped to the maximum supported size if too large. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + interface ShapeGetImageOptions { /** - * No bullets. + * The desired format of the resulting image. + * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - none = "None", + format?: PowerPoint.ShapeGetImageFormatType | "Png"; /** - * Numbered bullet (e.g., 1, 2, 3 or a, b, c). + * The desired height of the resulting image in pixels. This value will automatically be clamped to the maximum supported size if too large. + Throws an `InvalidArgument` exception when set with a non-positive integer. + * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - numbered = "Numbered", + height?: number; /** - * Symbol-based bullet (e.g., disc, circle, square). + * The desired width of the resulting image in pixels. This value will automatically be clamped to the maximum supported size if too large. + Throws an `InvalidArgument` exception when set with a non-positive integer. + * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - unnumbered = "Unnumbered", + width?: number; } /** - * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. + * Represents a collection of shapes. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - class BulletFormat extends OfficeExtension.ClientObject { + class ShapeScopedCollection extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.Shape[]; /** - * Specifies the style of the bullets in the paragraph. See {@link PowerPoint.BulletStyle} for details. - Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - style: PowerPoint.BulletStyle | "Unsupported" | "AlphabetLowercasePeriod" | "AlphabetUppercasePeriod" | "ArabicNumeralParenthesisRight" | "ArabicNumeralPeriod" | "RomanLowercaseParenthesesBoth" | "RomanLowercaseParenthesisRight" | "RomanLowercasePeriod" | "RomanUppercasePeriod" | "AlphabetLowercaseParenthesesBoth" | "AlphabetLowercaseParenthesisRight" | "AlphabetUppercaseParenthesesBoth" | "AlphabetUppercaseParenthesisRight" | "ArabicNumeralParenthesesBoth" | "ArabicNumeralPlain" | "RomanUppercaseParenthesesBoth" | "RomanUppercaseParenthesisRight" | "SimplifiedChinesePlain" | "SimplifiedChinesePeriod" | "CircleNumberDoubleBytePlain" | "CircleNumberWideDoubleByteWhitePlain" | "CircleNumberWideDoubleByteBlackPlain" | "TraditionalChinesePlain" | "TraditionalChinesePeriod" | "ArabicAlphabetDash" | "ArabicAbjadDash" | "HebrewAlphabetDash" | "KanjiKoreanPlain" | "KanjiKoreanPeriod" | "ArabicDoubleBytePlain" | "ArabicDoubleBytePeriod" | "ThaiAlphabetPeriod" | "ThaiAlphabetParenthesisRight" | "ThaiAlphabetParenthesesBoth" | "ThaiNumeralPeriod" | "ThaiNumeralParenthesisRight" | "ThaiNumeralParenthesesBoth" | "HindiAlphabetPeriod" | "HindiNumeralPeriod" | "KanjiSimplifiedChineseDoubleBytePeriod" | "HindiNumeralParenthesisRight" | "HindiAlphabet1Period" | null; - /** - * Specifies the type of the bullets in the paragraph. See {@link PowerPoint.BulletType} for details. - Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. + * Gets the number of shapes in the collection. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.5] + * @returns The number of shapes in the collection. */ - type: PowerPoint.BulletType | "Unsupported" | "None" | "Numbered" | "Unnumbered" | null; + getCount(): OfficeExtension.ClientResult; /** - * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. + * Gets a shape using its unique ID. An error is thrown if the shape doesn't exist. * * @remarks - * [Api set: PowerPointApi 1.4] - */ - visible: boolean | null; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * [Api set: PowerPointApi 1.5] * - * @param options Provides options for which properties of the object to load. + * @param key The ID of the shape. + * @returns The shape with the unique ID. If such a shape doesn't exist, an error is thrown. */ - load(options?: PowerPoint.Interfaces.BulletFormatLoadOptions): PowerPoint.BulletFormat; + getItem(key: string): PowerPoint.Shape; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Gets a shape using its zero-based index in the collection. An error is thrown if the index is out of range. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.BulletFormat; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * @remarks + * [Api set: PowerPointApi 1.5] * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.BulletFormat; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.BulletFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BulletFormatData`) that contains shallow copies of any loaded child properties from the original object. + * @param index The index of the shape in the collection. + * @returns The shape at the given index. An error is thrown if index is out of range. */ - toJSON(): PowerPoint.Interfaces.BulletFormatData; - } - /** - * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - class ParagraphFormat extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + getItemAt(index: number): PowerPoint.Shape; /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. + * Gets a shape using its unique ID. If such a shape doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.4] - */ - readonly bulletFormat: PowerPoint.BulletFormat; - /** - * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. + * [Api set: PowerPointApi 1.5] * - * @remarks - * [Api set: PowerPointApi 1.4] + * @param id The ID of the shape. + * @returns The shape with the unique ID. If such a shape doesn't exist, an object with an `isNullObject` property set to true is returned. */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + getItemOrNullObject(id: string): PowerPoint.Shape; /** - * Represents the indent level of the paragraph. + * Groups all shapes in this collection into a single shape. + If the collection contains fewer than two shapes, then this method returns the `GeneralException` error. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] + * @returns The newly created grouped shape as a {@link PowerPoint.Shape}. */ - indentLevel: number; + group(): PowerPoint.Shape; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.ParagraphFormatLoadOptions): PowerPoint.ParagraphFormat; + load(options?: PowerPoint.Interfaces.ShapeScopedCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.ShapeScopedCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.ParagraphFormat; + load(propertyNames?: string | string[]): PowerPoint.ShapeScopedCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.ParagraphFormat; + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.ShapeScopedCollection; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ParagraphFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ParagraphFormatData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.ShapeScopedCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeScopedCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - toJSON(): PowerPoint.Interfaces.ParagraphFormatData; + toJSON(): PowerPoint.Interfaces.ShapeScopedCollectionData; } /** - * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. + * Represents a shape group inside a presentation. To get the corresponding Shape object, use `ShapeGroup.shape`. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - class TextRange extends OfficeExtension.ClientObject { + class ShapeGroup extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Returns a `ShapeFont` object that represents the font attributes for the text range. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - readonly font: PowerPoint.ShapeFont; - /** - * Represents the paragraph format of the text range. See {@link PowerPoint.ParagraphFormat} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - readonly paragraphFormat: PowerPoint.ParagraphFormat; - /** - * Gets or sets the length of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. - * - * @remarks - * [Api set: PowerPointApi 1.5] - */ - length: number; - /** - * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * Returns the `Shape` object associated with the group. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.8] */ - start: number; + readonly shape: PowerPoint.Shape; /** - * Represents the plain text content of the text range. + * Returns the collection of `Shape` objects in the group. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - text: string; + readonly shapes: PowerPoint.ShapeScopedCollection; /** - * Returns the parent {@link PowerPoint.TextFrame} object that holds this `TextRange`. + * Gets the creation ID of the shape group. Returns `null` if the shape group has no creation ID. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - getParentTextFrame(): PowerPoint.TextFrame; + readonly creationId: string | null; /** - * Returns a `TextRange` object for the substring in the given range. + * Gets the unique ID of the shape group. * * @remarks - * [Api set: PowerPointApi 1.4] - * - * @param start The zero-based index of the first character to get from the text range. - * @param length Optional. The number of characters to be returned in the new text range. If length is omitted, all the characters from start to the end of the text range's last paragraph will be returned. + * [Api set: PowerPointApi 1.8] */ - getSubstring(start: number, length?: number): PowerPoint.TextRange; + readonly id: string; /** - * Selects this `TextRange` in the current view. + * Ungroups any grouped shapes in the specified shape group. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.8] */ - setSelected(): void; + ungroup(): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TextRangeLoadOptions): PowerPoint.TextRange; + load(options?: PowerPoint.Interfaces.ShapeGroupLoadOptions): PowerPoint.ShapeGroup; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TextRange; + load(propertyNames?: string | string[]): PowerPoint.ShapeGroup; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -189343,111 +189612,114 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.TextRange; + }): PowerPoint.ShapeGroup; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TextRange` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TextRangeData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.ShapeGroup` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeGroupData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TextRangeData; + toJSON(): PowerPoint.Interfaces.ShapeGroupData; } /** - * Represents the text frame of a shape object. + * Specifies the style for a line. * * @remarks * [Api set: PowerPointApi 1.4] */ - class TextFrame extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + enum ShapeLineStyle { /** - * Represents the text that is attached to a shape in the text frame, and properties and methods for manipulating the text. See {@link PowerPoint.TextRange} for details. - * + * Single line. * @remarks * [Api set: PowerPointApi 1.4] */ - readonly textRange: PowerPoint.TextRange; + single = "Single", /** - * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. - * + * Thick line with a thin line on each side. * @remarks * [Api set: PowerPointApi 1.4] */ - autoSizeSetting: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; + thickBetweenThin = "ThickBetweenThin", /** - * Represents the bottom margin, in points, of the text frame. - * + * Thick line next to thin line. For horizontal lines, the thick line is above the thin line. For vertical lines, the thick line is to the left of the thin line. * @remarks * [Api set: PowerPointApi 1.4] */ - bottomMargin: number; + thickThin = "ThickThin", /** - * Specifies if the text frame contains text. - * + * Thick line next to thin line. For horizontal lines, the thick line is below the thin line. For vertical lines, the thick line is to the right of the thin line. * @remarks * [Api set: PowerPointApi 1.4] */ - readonly hasText: boolean; + thinThick = "ThinThick", /** - * Represents the left margin, in points, of the text frame. - * + * Two thin lines. * @remarks * [Api set: PowerPointApi 1.4] */ - leftMargin: number; + thinThin = "ThinThin", + } + /** + * Represents the line formatting for the shape object. For images and geometric shapes, line formatting represents the border of the shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class ShapeLineFormat extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Represents the right margin, in points, of the text frame. + * Represents the line color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). * * @remarks * [Api set: PowerPointApi 1.4] */ - rightMargin: number; + color: string; /** - * Represents the top margin, in points, of the text frame. + * Represents the dash style of the line. Returns null when the line isn't visible or there are inconsistent dash styles. See {@link PowerPoint.ShapeLineDashStyle} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - topMargin: number; + dashStyle: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot"; /** - * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. + * Represents the line style of the shape. Returns null when the line isn't visible or there are inconsistent styles. See {@link PowerPoint.ShapeLineStyle} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - verticalAlignment: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + style: PowerPoint.ShapeLineStyle | "Single" | "ThickBetweenThin" | "ThickThin" | "ThinThick" | "ThinThin"; /** - * Determines whether lines break automatically to fit text inside the shape. + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). Returns null when the shape has inconsistent transparencies. * * @remarks * [Api set: PowerPointApi 1.4] */ - wordWrap: boolean; + transparency: number; /** - * Deletes all the text in the text frame. + * Specifies if the line formatting of a shape element is visible. Returns `null` when the shape has inconsistent visibilities. * * @remarks * [Api set: PowerPointApi 1.4] */ - deleteText(): void; + visible: boolean; /** - * Returns the parent {@link PowerPoint.Shape} object that holds this `TextFrame`. + * Represents the weight of the line, in points. Returns `null` when the line isn't visible or there are inconsistent line weights. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.4] */ - getParentShape(): PowerPoint.Shape; + weight: number; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TextFrameLoadOptions): PowerPoint.TextFrame; + load(options?: PowerPoint.Interfaces.ShapeLineFormatLoadOptions): PowerPoint.ShapeLineFormat; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TextFrame; + load(propertyNames?: string | string[]): PowerPoint.ShapeLineFormat; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -189456,12 +189728,12 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.TextFrame; + }): PowerPoint.ShapeLineFormat; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TextFrame` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TextFrameData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.ShapeLineFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeLineFormatData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TextFrameData; + toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } /** * Use with `setZOrder` to move the specified shape up or down the collection's z-order, which shifts it in front of or behind other shapes. @@ -189504,6 +189776,14 @@ declare namespace PowerPoint { class Shape extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; + /** + * Returns an `Adjustments` object that contains adjustment values for all the adjustments in this shape. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + readonly adjustments: PowerPoint.Adjustments; /** * Returns a collection of custom XML parts in the shape. * @@ -189563,6 +189843,14 @@ declare namespace PowerPoint { * [Api set: PowerPointApi 1.4] */ readonly textFrame: PowerPoint.TextFrame; + /** + * Gets the creation ID of the shape. Returns `null` if the shape has no creation ID. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + readonly creationId: string | null; /** * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. * @@ -189726,6 +190014,17 @@ declare namespace PowerPoint { * @beta */ getTextFrameOrNullObject(): PowerPoint.TextFrame; + /** + * Sets a hyperlink on this `Shape` with the specified options. This will delete any existing hyperlink on this `Shape`. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param options Optional. The options for the hyperlink. + * @returns The newly created {@link PowerPoint.Hyperlink} object. + */ + setHyperlink(options?: PowerPoint.HyperlinkAddOptions): PowerPoint.Hyperlink; /** * Moves the specified shape up or down the collection's z-order, which shifts it in front of or behind other shapes. * @@ -190094,6 +190393,18 @@ declare namespace PowerPoint { * Keys have a maximum length of 255 characters. If the argument exceeds 255 characters, then this method returns the `InvalidArgument` error. */ getItem(key: string): PowerPoint.CustomProperty; + /** + * Gets a `CustomProperty` by its zero-based index in the collection. + Throws an `InvalidArgument` exception when the index is out of range. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + * + * @param index The index of the custom property in the collection. + * @returns The custom property at the given index. + */ + getItemAt(index: number): PowerPoint.CustomProperty; /** * Gets a `CustomProperty` by its key. If the `CustomProperty` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. @@ -190616,125 +190927,75 @@ declare namespace PowerPoint { } namespace Interfaces { /** - * Provides ways to load properties of only a subset of members of a collection. - */ - interface CollectionLoadOptions { - /** - * Specify the number of items in the queried collection to be included in the result. - */ - $top?: number; - /** - * Specify the number of items in the collection that are to be skipped and not included in the result. If top is specified, the selection of result will start after skipping the specified number of items. - */ - $skip?: number; - } - /** An interface for updating data on the `CustomXmlPartScopedCollection` object, for use in `customXmlPartScopedCollection.set({ ... })`. */ - interface CustomXmlPartScopedCollectionUpdateData { - items?: PowerPoint.Interfaces.CustomXmlPartData[]; - } - /** An interface for updating data on the `CustomXmlPartCollection` object, for use in `customXmlPartCollection.set({ ... })`. */ - interface CustomXmlPartCollectionUpdateData { - items?: PowerPoint.Interfaces.CustomXmlPartData[]; - } - /** An interface for updating data on the `Hyperlink` object, for use in `hyperlink.set({ ... })`. */ - interface HyperlinkUpdateData { - /** - * Specifies the URL target of the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - address?: string; - /** - * Specifies the string displayed when hovering over the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - screenTip?: string; - } - /** An interface for updating data on the `HyperlinkCollection` object, for use in `hyperlinkCollection.set({ ... })`. */ - interface HyperlinkCollectionUpdateData { - items?: PowerPoint.Interfaces.HyperlinkData[]; - } - /** An interface for updating data on the `Border` object, for use in `border.set({ ... })`. */ - interface BorderUpdateData { - /** - * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - color?: string | undefined; - /** - * Represents the dash style of the line. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; - /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - transparency?: number | undefined; - /** - * Represents the weight of the line, in points. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - weight?: number | undefined; - } - /** An interface for updating data on the `Margins` object, for use in `margins.set({ ... })`. */ - interface MarginsUpdateData { + * Provides ways to load properties of only a subset of members of a collection. + */ + interface CollectionLoadOptions { /** - * Specifies the bottom margin in points. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - bottom?: number | undefined; + * Specify the number of items in the queried collection to be included in the result. + */ + $top?: number; /** - * Specifies the left margin in points. + * Specify the number of items in the collection that are to be skipped and not included in the result. If top is specified, the selection of result will start after skipping the specified number of items. + */ + $skip?: number; + } + /** An interface for updating data on the `CustomXmlPartScopedCollection` object, for use in `customXmlPartScopedCollection.set({ ... })`. */ + interface CustomXmlPartScopedCollectionUpdateData { + items?: PowerPoint.Interfaces.CustomXmlPartData[]; + } + /** An interface for updating data on the `CustomXmlPartCollection` object, for use in `customXmlPartCollection.set({ ... })`. */ + interface CustomXmlPartCollectionUpdateData { + items?: PowerPoint.Interfaces.CustomXmlPartData[]; + } + /** An interface for updating data on the `HyperlinkScopedCollection` object, for use in `hyperlinkScopedCollection.set({ ... })`. */ + interface HyperlinkScopedCollectionUpdateData { + items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface for updating data on the `BulletFormat` object, for use in `bulletFormat.set({ ... })`. */ + interface BulletFormatUpdateData { + /** + * Specifies the style of the bullets in the paragraph. See {@link PowerPoint.BulletStyle} for details. + Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - left?: number | undefined; + style?: PowerPoint.BulletStyle | "Unsupported" | "AlphabetLowercasePeriod" | "AlphabetUppercasePeriod" | "ArabicNumeralParenthesisRight" | "ArabicNumeralPeriod" | "RomanLowercaseParenthesesBoth" | "RomanLowercaseParenthesisRight" | "RomanLowercasePeriod" | "RomanUppercasePeriod" | "AlphabetLowercaseParenthesesBoth" | "AlphabetLowercaseParenthesisRight" | "AlphabetUppercaseParenthesesBoth" | "AlphabetUppercaseParenthesisRight" | "ArabicNumeralParenthesesBoth" | "ArabicNumeralPlain" | "RomanUppercaseParenthesesBoth" | "RomanUppercaseParenthesisRight" | "SimplifiedChinesePlain" | "SimplifiedChinesePeriod" | "CircleNumberDoubleBytePlain" | "CircleNumberWideDoubleByteWhitePlain" | "CircleNumberWideDoubleByteBlackPlain" | "TraditionalChinesePlain" | "TraditionalChinesePeriod" | "ArabicAlphabetDash" | "ArabicAbjadDash" | "HebrewAlphabetDash" | "KanjiKoreanPlain" | "KanjiKoreanPeriod" | "ArabicDoubleBytePlain" | "ArabicDoubleBytePeriod" | "ThaiAlphabetPeriod" | "ThaiAlphabetParenthesisRight" | "ThaiAlphabetParenthesesBoth" | "ThaiNumeralPeriod" | "ThaiNumeralParenthesisRight" | "ThaiNumeralParenthesesBoth" | "HindiAlphabetPeriod" | "HindiNumeralPeriod" | "KanjiSimplifiedChineseDoubleBytePeriod" | "HindiNumeralParenthesisRight" | "HindiAlphabet1Period" | null; /** - * Specifies the right margin in points. + * Specifies the type of the bullets in the paragraph. See {@link PowerPoint.BulletType} for details. + Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - right?: number | undefined; + type?: PowerPoint.BulletType | "Unsupported" | "None" | "Numbered" | "Unnumbered" | null; /** - * Specifies the top margin in points. + * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - top?: number | undefined; + visible?: boolean | null; } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - interface ShapeFillUpdateData { + /** An interface for updating data on the `ParagraphFormat` object, for use in `paragraphFormat.set({ ... })`. */ + interface ParagraphFormatUpdateData { /** - * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - foregroundColor?: string; + horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * Represents the indent level of the paragraph. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - transparency?: number; + indentLevel?: number; } /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ interface ShapeFontUpdateData { @@ -190821,55 +191082,233 @@ declare namespace PowerPoint { - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.8] + */ + smallCaps?: boolean | null; + /** + * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Strikethrough** attribute. + + - `false`: None of the text has the **Strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + strikethrough?: boolean | null; + /** + * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Subscript** attribute. + + - `false`: None of the text has the **Subscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + subscript?: boolean | null; + /** + * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Superscript** attribute. + + - `false`: None of the text has the **Superscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + superscript?: boolean | null; + /** + * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; + } + /** An interface for updating data on the `TextFrame` object, for use in `textFrame.set({ ... })`. */ + interface TextFrameUpdateData { + /** + * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + autoSizeSetting?: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; + /** + * Represents the bottom margin, in points, of the text frame. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bottomMargin?: number; + /** + * Represents the left margin, in points, of the text frame. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + leftMargin?: number; + /** + * Represents the right margin, in points, of the text frame. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + rightMargin?: number; + /** + * Represents the top margin, in points, of the text frame. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + topMargin?: number; + /** + * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + /** + * Determines whether lines break automatically to fit text inside the shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wordWrap?: boolean; + } + /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ + interface TextRangeUpdateData { + /** + * Gets or sets the length of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. + * + * @remarks + * [Api set: PowerPointApi 1.5] + */ + length?: number; + /** + * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * + * @remarks + * [Api set: PowerPointApi 1.5] + */ + start?: number; + /** + * Represents the plain text content of the text range. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + text?: string; + } + /** An interface for updating data on the `Hyperlink` object, for use in `hyperlink.set({ ... })`. */ + interface HyperlinkUpdateData { + /** + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + address?: string; + /** + * Specifies the string displayed when hovering over the hyperlink. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + screenTip?: string; + } + /** An interface for updating data on the `HyperlinkCollection` object, for use in `hyperlinkCollection.set({ ... })`. */ + interface HyperlinkCollectionUpdateData { + items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface for updating data on the `Border` object, for use in `border.set({ ... })`. */ + interface BorderUpdateData { + /** + * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + color?: string | undefined; + /** + * Represents the dash style of the line. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; + /** + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + transparency?: number | undefined; + /** + * Represents the weight of the line, in points. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + weight?: number | undefined; + } + /** An interface for updating data on the `Margins` object, for use in `margins.set({ ... })`. */ + interface MarginsUpdateData { + /** + * Specifies the bottom margin in points. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + bottom?: number | undefined; + /** + * Specifies the left margin in points. + * + * @remarks + * [Api set: PowerPointApi 1.9] */ - smallCaps?: boolean | null; + left?: number | undefined; /** - * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Strikethrough** attribute. - - - `false`: None of the text has the **Strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. + * Specifies the right margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - strikethrough?: boolean | null; + right?: number | undefined; /** - * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Subscript** attribute. - - - `false`: None of the text has the **Subscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. + * Specifies the top margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - subscript?: boolean | null; + top?: number | undefined; + } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + interface ShapeFillUpdateData { /** - * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Superscript** attribute. - - - `false`: None of the text has the **Superscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - superscript?: boolean | null; + foregroundColor?: string; /** - * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. * * @remarks * [Api set: PowerPointApi 1.4] */ - underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; + transparency?: number; } /** An interface for updating data on the `TableCell` object, for use in `tableCell.set({ ... })`. */ interface TableCellUpdateData { @@ -190942,62 +191381,55 @@ declare namespace PowerPoint { interface TableRowCollectionUpdateData { items?: PowerPoint.Interfaces.TableRowData[]; } - /** An interface for updating data on the `TableStyleOptions` object, for use in `tableStyleOptions.set({ ... })`. */ - interface TableStyleOptionsUpdateData { + /** An interface for updating data on the `TableStyleSettings` object, for use in `tableStyleSettings.set({ ... })`. */ + interface TableStyleSettingsUpdateData { /** * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ areColumnsBanded?: boolean; /** * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ areRowsBanded?: boolean; /** * Specifies if the first column contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isFirstColumnHighlighted?: boolean; /** * Specifies if the first row contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isFirstRowHighlighted?: boolean; /** * Specifies if the last column contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isLastColumnHighlighted?: boolean; /** * Specifies if the last row contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isLastRowHighlighted?: boolean; /** * Specifies the table style. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ style?: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; } @@ -191146,40 +191578,262 @@ declare namespace PowerPoint { * Represents the dash style of the line. Returns null when the line isn't visible or there are inconsistent dash styles. See {@link PowerPoint.ShapeLineDashStyle} for details. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.4] + */ + dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot"; + /** + * Represents the line style of the shape. Returns null when the line isn't visible or there are inconsistent styles. See {@link PowerPoint.ShapeLineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + style?: PowerPoint.ShapeLineStyle | "Single" | "ThickBetweenThin" | "ThickThin" | "ThinThick" | "ThinThin"; + /** + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). Returns null when the shape has inconsistent transparencies. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + transparency?: number; + /** + * Specifies if the line formatting of a shape element is visible. Returns `null` when the shape has inconsistent visibilities. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + visible?: boolean; + /** + * Represents the weight of the line, in points. Returns `null` when the line isn't visible or there are inconsistent line weights. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + weight?: number; + } + /** An interface for updating data on the `Shape` object, for use in `shape.set({ ... })`. */ + interface ShapeUpdateData { + /** + * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + height?: number; + /** + * The distance, in points, from the left side of the shape to the left side of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + left?: number; + /** + * Specifies the name of this shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Specifies the rotation, in degrees, of the shape around the z-axis. + A positive value indicates clockwise rotation, and a negative value indicates counterclockwise rotation. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + rotation?: number; + /** + * The distance, in points, from the top edge of the shape to the top edge of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + top?: number; + /** + * Specifies if the shape is visible. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + visible?: boolean; + /** + * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + width?: number; + } + /** An interface for updating data on the `BindingCollection` object, for use in `bindingCollection.set({ ... })`. */ + interface BindingCollectionUpdateData { + items?: PowerPoint.Interfaces.BindingData[]; + } + /** An interface for updating data on the `CustomProperty` object, for use in `customProperty.set({ ... })`. */ + interface CustomPropertyUpdateData { + /** + * The value of the custom property. + If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + value?: boolean | Date | number | string; + } + /** An interface for updating data on the `CustomPropertyCollection` object, for use in `customPropertyCollection.set({ ... })`. */ + interface CustomPropertyCollectionUpdateData { + items?: PowerPoint.Interfaces.CustomPropertyData[]; + } + /** An interface for updating data on the `DocumentProperties` object, for use in `documentProperties.set({ ... })`. */ + interface DocumentPropertiesUpdateData { + /** + * The author of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + author?: string; + /** + * The category of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + category?: string; + /** + * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + comments?: string; + /** + * The company of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + company?: string; + /** + * The keywords of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + keywords?: string; + /** + * The manager of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + manager?: string; + /** + * The revision number of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + revisionNumber?: number; + /** + * The subject of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + subject?: string; + /** + * The title of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + title?: string; + } + /** An interface for updating data on the `PageSetup` object, for use in `pageSetup.set({ ... })`. */ + interface PageSetupUpdateData { + /** + * Specifies the height of the slides in the presentation, in points. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + slideHeight?: number; + /** + * Specifies the width of the slides in the presentation, in points. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot"; + slideWidth?: number; + } + /** An interface for updating data on the `SlideCollection` object, for use in `slideCollection.set({ ... })`. */ + interface SlideCollectionUpdateData { + items?: PowerPoint.Interfaces.SlideData[]; + } + /** An interface for updating data on the `SlideScopedCollection` object, for use in `slideScopedCollection.set({ ... })`. */ + interface SlideScopedCollectionUpdateData { + items?: PowerPoint.Interfaces.SlideData[]; + } + /** An interface for updating data on the `SlideMasterCollection` object, for use in `slideMasterCollection.set({ ... })`. */ + interface SlideMasterCollectionUpdateData { + items?: PowerPoint.Interfaces.SlideMasterData[]; + } + /** An interface describing the data returned by calling `presentation.toJSON()`. */ + interface PresentationData { /** - * Represents the line style of the shape. Returns null when the line isn't visible or there are inconsistent styles. See {@link PowerPoint.ShapeLineStyle} for details. + * Gets the ID of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - style?: PowerPoint.ShapeLineStyle | "Single" | "ThickBetweenThin" | "ThickThin" | "ThinThick" | "ThinThin"; + id?: string; + title?: string; + } + /** An interface describing the data returned by calling `adjustments.toJSON()`. */ + interface AdjustmentsData { /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). Returns null when the shape has inconsistent transparencies. + * Specifies the number of adjustment points. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - transparency?: number; + count?: number; + } + /** An interface describing the data returned by calling `customXmlPart.toJSON()`. */ + interface CustomXmlPartData { /** - * Specifies if the line formatting of a shape element is visible. Returns `null` when the shape has inconsistent visibilities. + * The ID of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - visible?: boolean; + id?: string; /** - * Represents the weight of the line, in points. Returns `null` when the line isn't visible or there are inconsistent line weights. + * The namespace URI of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - weight?: number; + namespaceUri?: string; } - /** An interface for updating data on the `BulletFormat` object, for use in `bulletFormat.set({ ... })`. */ - interface BulletFormatUpdateData { + /** An interface describing the data returned by calling `customXmlPartScopedCollection.toJSON()`. */ + interface CustomXmlPartScopedCollectionData { + items?: PowerPoint.Interfaces.CustomXmlPartData[]; + } + /** An interface describing the data returned by calling `customXmlPartCollection.toJSON()`. */ + interface CustomXmlPartCollectionData { + items?: PowerPoint.Interfaces.CustomXmlPartData[]; + } + /** An interface describing the data returned by calling `hyperlinkScopedCollection.toJSON()`. */ + interface HyperlinkScopedCollectionData { + items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface describing the data returned by calling `bulletFormat.toJSON()`. */ + interface BulletFormatData { /** * Specifies the style of the bullets in the paragraph. See {@link PowerPoint.BulletStyle} for details. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. @@ -191206,8 +191860,8 @@ declare namespace PowerPoint { */ visible?: boolean | null; } - /** An interface for updating data on the `ParagraphFormat` object, for use in `paragraphFormat.set({ ... })`. */ - interface ParagraphFormatUpdateData { + /** An interface describing the data returned by calling `paragraphFormat.toJSON()`. */ + interface ParagraphFormatData { /** * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. * @@ -191224,290 +191878,250 @@ declare namespace PowerPoint { */ indentLevel?: number; } - /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ - interface TextRangeUpdateData { - /** - * Gets or sets the length of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. - * - * @remarks - * [Api set: PowerPointApi 1.5] - */ - length?: number; + /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ + interface ShapeFontData { /** - * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: + + - `true`: All the text has the **All Caps** attribute. + + - `false`: None of the text has the **All Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.8] */ - start?: number; + allCaps?: boolean | null; /** - * Represents the plain text content of the text range. + * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: + + - `true`: All the text is bold. + + - `false`: None of the text is bold. + + - `null`: Returned if some, but not all, of the text is bold. * * @remarks * [Api set: PowerPointApi 1.4] */ - text?: string; - } - /** An interface for updating data on the `TextFrame` object, for use in `textFrame.set({ ... })`. */ - interface TextFrameUpdateData { + bold?: boolean | null; /** - * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. + * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. * * @remarks * [Api set: PowerPointApi 1.4] */ - autoSizeSetting?: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; + color?: string | null; /** - * Represents the bottom margin, in points, of the text frame. + * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Double strikethrough** attribute. + + - `false`: None of the text has the **Double strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - bottomMargin?: number; + doubleStrikethrough?: boolean | null; /** - * Represents the left margin, in points, of the text frame. + * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: + + - `true`: All the text is italicized. + + - `false`: None of the text is italicized. + + - `null`: Returned if some, but not all, of the text is italicized. * * @remarks * [Api set: PowerPointApi 1.4] */ - leftMargin?: number; + italic?: boolean | null; /** - * Represents the right margin, in points, of the text frame. + * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. * * @remarks * [Api set: PowerPointApi 1.4] */ - rightMargin?: number; + name?: string | null; /** - * Represents the top margin, in points, of the text frame. + * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. * * @remarks * [Api set: PowerPointApi 1.4] */ - topMargin?: number; + size?: number | null; /** - * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. + * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: + + - `true`: All the text has the **Small Caps** attribute. + + - `false`: None of the text has the **Small Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + smallCaps?: boolean | null; /** - * Determines whether lines break automatically to fit text inside the shape. + * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Strikethrough** attribute. + + - `false`: None of the text has the **Strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - wordWrap?: boolean; - } - /** An interface for updating data on the `Shape` object, for use in `shape.set({ ... })`. */ - interface ShapeUpdateData { + strikethrough?: boolean | null; /** - * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Subscript** attribute. + + - `false`: None of the text has the **Subscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - height?: number; + subscript?: boolean | null; /** - * The distance, in points, from the left side of the shape to the left side of the slide. + * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Superscript** attribute. + + - `false`: None of the text has the **Superscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - left?: number; + superscript?: boolean | null; /** - * Specifies the name of this shape. + * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - name?: string; - /** - * Specifies the rotation, in degrees, of the shape around the z-axis. - A positive value indicates clockwise rotation, and a negative value indicates counterclockwise rotation. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - rotation?: number; + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; + } + /** An interface describing the data returned by calling `textFrame.toJSON()`. */ + interface TextFrameData { /** - * The distance, in points, from the top edge of the shape to the top edge of the slide. + * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. * * @remarks * [Api set: PowerPointApi 1.4] */ - top?: number; - /** - * Specifies if the shape is visible. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - visible?: boolean; + autoSizeSetting?: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; /** - * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * Represents the bottom margin, in points, of the text frame. * * @remarks * [Api set: PowerPointApi 1.4] */ - width?: number; - } - /** An interface for updating data on the `BindingCollection` object, for use in `bindingCollection.set({ ... })`. */ - interface BindingCollectionUpdateData { - items?: PowerPoint.Interfaces.BindingData[]; - } - /** An interface for updating data on the `CustomProperty` object, for use in `customProperty.set({ ... })`. */ - interface CustomPropertyUpdateData { - /** - * The value of the custom property. - If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - value?: boolean | Date | number | string; - } - /** An interface for updating data on the `CustomPropertyCollection` object, for use in `customPropertyCollection.set({ ... })`. */ - interface CustomPropertyCollectionUpdateData { - items?: PowerPoint.Interfaces.CustomPropertyData[]; - } - /** An interface for updating data on the `DocumentProperties` object, for use in `documentProperties.set({ ... })`. */ - interface DocumentPropertiesUpdateData { - /** - * The author of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - author?: string; - /** - * The category of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - category?: string; + bottomMargin?: number; /** - * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. + * Specifies if the text frame contains text. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - comments?: string; + hasText?: boolean; /** - * The company of the presentation. + * Represents the left margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - company?: string; + leftMargin?: number; /** - * The keywords of the presentation. + * Represents the right margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - keywords?: string; + rightMargin?: number; /** - * The manager of the presentation. + * Represents the top margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - manager?: string; + topMargin?: number; /** - * The revision number of the presentation. + * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - revisionNumber?: number; + verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; /** - * The subject of the presentation. + * Determines whether lines break automatically to fit text inside the shape. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - subject?: string; + wordWrap?: boolean; + } + /** An interface describing the data returned by calling `textRange.toJSON()`. */ + interface TextRangeData { /** - * The title of the presentation. + * Gets or sets the length of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] */ - title?: string; - } - /** An interface for updating data on the `PageSetup` object, for use in `pageSetup.set({ ... })`. */ - interface PageSetupUpdateData { + length?: number; /** - * Specifies the height of the slides in the presentation, in points. + * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.5] */ - slideHeight?: number; + start?: number; /** - * Specifies the width of the slides in the presentation, in points. + * Represents the plain text content of the text range. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.4] */ - slideWidth?: number; - } - /** An interface for updating data on the `SlideCollection` object, for use in `slideCollection.set({ ... })`. */ - interface SlideCollectionUpdateData { - items?: PowerPoint.Interfaces.SlideData[]; - } - /** An interface for updating data on the `SlideScopedCollection` object, for use in `slideScopedCollection.set({ ... })`. */ - interface SlideScopedCollectionUpdateData { - items?: PowerPoint.Interfaces.SlideData[]; - } - /** An interface for updating data on the `SlideMasterCollection` object, for use in `slideMasterCollection.set({ ... })`. */ - interface SlideMasterCollectionUpdateData { - items?: PowerPoint.Interfaces.SlideMasterData[]; + text?: string; } - /** An interface describing the data returned by calling `presentation.toJSON()`. */ - interface PresentationData { + /** An interface describing the data returned by calling `hyperlink.toJSON()`. */ + interface HyperlinkData { /** - * Gets the ID of the presentation. + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.6] */ - id?: string; - title?: string; - } - /** An interface describing the data returned by calling `customXmlPart.toJSON()`. */ - interface CustomXmlPartData { + address?: string; /** - * The ID of the custom XML part. + * Specifies the string displayed when hovering over the hyperlink. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - id?: string; + screenTip?: string; /** - * The namespace URI of the custom XML part. + * Returns the type of object that the hyperlink is applied to. See {@link PowerPoint.HyperlinkType} for details. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - namespaceUri?: string; - } - /** An interface describing the data returned by calling `customXmlPartScopedCollection.toJSON()`. */ - interface CustomXmlPartScopedCollectionData { - items?: PowerPoint.Interfaces.CustomXmlPartData[]; - } - /** An interface describing the data returned by calling `customXmlPartCollection.toJSON()`. */ - interface CustomXmlPartCollectionData { - items?: PowerPoint.Interfaces.CustomXmlPartData[]; + type?: PowerPoint.HyperlinkType | "TextRange" | "Shape"; } /** An interface describing the data returned by calling `placeholderFormat.toJSON()`. */ interface PlaceholderFormatData { @@ -191527,23 +192141,6 @@ declare namespace PowerPoint { */ type?: PowerPoint.PlaceholderType | "Unsupported" | "Date" | "SlideNumber" | "Footer" | "Header" | "Title" | "Body" | "CenterTitle" | "Subtitle" | "VerticalTitle" | "VerticalBody" | "Content" | "Chart" | "Table" | "OnlinePicture" | "SmartArt" | "Media" | "VerticalContent" | "Picture" | "Cameo"; } - /** An interface describing the data returned by calling `hyperlink.toJSON()`. */ - interface HyperlinkData { - /** - * Specifies the URL target of the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - address?: string; - /** - * Specifies the string displayed when hovering over the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - screenTip?: string; - } /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ interface HyperlinkCollectionData { items?: PowerPoint.Interfaces.HyperlinkData[]; @@ -191603,174 +192200,39 @@ declare namespace PowerPoint { * * @remarks * [Api set: PowerPointApi 1.9] - */ - right?: number | undefined; - /** - * Specifies the top margin in points. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - top?: number | undefined; - } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - interface ShapeFillData { - /** - * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - foregroundColor?: string; - /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - transparency?: number; - /** - * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - type?: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; - } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - interface ShapeFontData { - /** - * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: - - - `true`: All the text has the **All Caps** attribute. - - - `false`: None of the text has the **All Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - allCaps?: boolean | null; - /** - * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: - - - `true`: All the text is bold. - - - `false`: None of the text is bold. - - - `null`: Returned if some, but not all, of the text is bold. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean | null; - /** - * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string | null; - /** - * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Double strikethrough** attribute. - - - `false`: None of the text has the **Double strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - doubleStrikethrough?: boolean | null; - /** - * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: - - - `true`: All the text is italicized. - - - `false`: None of the text is italicized. - - - `null`: Returned if some, but not all, of the text is italicized. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean | null; - /** - * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string | null; - /** - * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number | null; - /** - * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: - - - `true`: All the text has the **Small Caps** attribute. - - - `false`: None of the text has the **Small Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - smallCaps?: boolean | null; - /** - * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Strikethrough** attribute. - - - `false`: None of the text has the **Strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. + */ + right?: number | undefined; + /** + * Specifies the top margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - strikethrough?: boolean | null; + top?: number | undefined; + } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + interface ShapeFillData { /** - * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Subscript** attribute. - - - `false`: None of the text has the **Subscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. + * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subscript?: boolean | null; + foregroundColor?: string; /** - * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Superscript** attribute. - - - `false`: None of the text has the **Superscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - superscript?: boolean | null; + transparency?: number; /** - * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; + type?: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; } /** An interface describing the data returned by calling `tableCell.toJSON()`. */ interface TableCellData { @@ -191894,62 +192356,55 @@ declare namespace PowerPoint { interface TableRowCollectionData { items?: PowerPoint.Interfaces.TableRowData[]; } - /** An interface describing the data returned by calling `tableStyleOptions.toJSON()`. */ - interface TableStyleOptionsData { + /** An interface describing the data returned by calling `tableStyleSettings.toJSON()`. */ + interface TableStyleSettingsData { /** * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ areColumnsBanded?: boolean; /** * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ areRowsBanded?: boolean; /** * Specifies if the first column contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isFirstColumnHighlighted?: boolean; /** * Specifies if the first row contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isFirstRowHighlighted?: boolean; /** * Specifies if the last column contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isLastColumnHighlighted?: boolean; /** * Specifies if the last row contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isLastRowHighlighted?: boolean; /** * Specifies the table style. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ style?: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; } @@ -192190,6 +192645,14 @@ declare namespace PowerPoint { } /** An interface describing the data returned by calling `shapeGroup.toJSON()`. */ interface ShapeGroupData { + /** + * Gets the creation ID of the shape group. Returns `null` if the shape group has no creation ID. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + creationId?: string | null; /** * Gets the unique ID of the shape group. * @@ -192243,500 +192706,806 @@ declare namespace PowerPoint { */ weight?: number; } - /** An interface describing the data returned by calling `bulletFormat.toJSON()`. */ - interface BulletFormatData { + /** An interface describing the data returned by calling `shape.toJSON()`. */ + interface ShapeData { /** - * Specifies the style of the bullets in the paragraph. See {@link PowerPoint.BulletStyle} for details. - Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. + * Gets the creation ID of the shape. Returns `null` if the shape has no creation ID. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - style?: PowerPoint.BulletStyle | "Unsupported" | "AlphabetLowercasePeriod" | "AlphabetUppercasePeriod" | "ArabicNumeralParenthesisRight" | "ArabicNumeralPeriod" | "RomanLowercaseParenthesesBoth" | "RomanLowercaseParenthesisRight" | "RomanLowercasePeriod" | "RomanUppercasePeriod" | "AlphabetLowercaseParenthesesBoth" | "AlphabetLowercaseParenthesisRight" | "AlphabetUppercaseParenthesesBoth" | "AlphabetUppercaseParenthesisRight" | "ArabicNumeralParenthesesBoth" | "ArabicNumeralPlain" | "RomanUppercaseParenthesesBoth" | "RomanUppercaseParenthesisRight" | "SimplifiedChinesePlain" | "SimplifiedChinesePeriod" | "CircleNumberDoubleBytePlain" | "CircleNumberWideDoubleByteWhitePlain" | "CircleNumberWideDoubleByteBlackPlain" | "TraditionalChinesePlain" | "TraditionalChinesePeriod" | "ArabicAlphabetDash" | "ArabicAbjadDash" | "HebrewAlphabetDash" | "KanjiKoreanPlain" | "KanjiKoreanPeriod" | "ArabicDoubleBytePlain" | "ArabicDoubleBytePeriod" | "ThaiAlphabetPeriod" | "ThaiAlphabetParenthesisRight" | "ThaiAlphabetParenthesesBoth" | "ThaiNumeralPeriod" | "ThaiNumeralParenthesisRight" | "ThaiNumeralParenthesesBoth" | "HindiAlphabetPeriod" | "HindiNumeralPeriod" | "KanjiSimplifiedChineseDoubleBytePeriod" | "HindiNumeralParenthesisRight" | "HindiAlphabet1Period" | null; + creationId?: string | null; /** - * Specifies the type of the bullets in the paragraph. See {@link PowerPoint.BulletType} for details. - Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. + * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + height?: number; + /** + * Gets the unique ID of the shape. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + id?: string; + /** + * The distance, in points, from the left side of the shape to the left side of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + left?: number; + /** + * Returns the level of the specified shape. + + - A level of 0 means the shape isn't part of a group. + + - A level of 1 means the shape is part of a top-level group. + + - A level greater than 1 indicates the shape is a nested group. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + level?: number; + /** + * Specifies the name of this shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Specifies the rotation, in degrees, of the shape around the z-axis. + A positive value indicates clockwise rotation, and a negative value indicates counterclockwise rotation. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - type?: PowerPoint.BulletType | "Unsupported" | "None" | "Numbered" | "Unnumbered" | null; + rotation?: number; /** - * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. + * The distance, in points, from the top edge of the shape to the top edge of the slide. * * @remarks * [Api set: PowerPointApi 1.4] */ - visible?: boolean | null; - } - /** An interface describing the data returned by calling `paragraphFormat.toJSON()`. */ - interface ParagraphFormatData { + top?: number; /** - * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. + * Returns the type of this shape. See {@link PowerPoint.ShapeType} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + type?: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox"; + /** + * Specifies if the shape is visible. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + visible?: boolean; + /** + * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + width?: number; + /** + * Returns the z-order position of the shape, with 0 representing the bottom of the order stack. Every shape on a slide has a unique z-order, but + each slide also has a unique z-order stack, so two shapes on separate slides could have the same z-order number. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + zOrderPosition?: number; + } + /** An interface describing the data returned by calling `binding.toJSON()`. */ + interface BindingData { + /** + * Represents the binding identifier. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + id?: string; + /** + * Returns the type of the binding. See `BindingType` for details. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + type?: PowerPoint.BindingType | "Shape"; + } + /** An interface describing the data returned by calling `bindingCollection.toJSON()`. */ + interface BindingCollectionData { + items?: PowerPoint.Interfaces.BindingData[]; + } + /** An interface describing the data returned by calling `customProperty.toJSON()`. */ + interface CustomPropertyData { + /** + * The string that uniquely identifies the custom property. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + key?: string; + /** + * The type of the value used for the custom property. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + type?: PowerPoint.DocumentPropertyType | "Boolean" | "Date" | "Number" | "String"; + /** + * The value of the custom property. + If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + value?: boolean | Date | number | string; + } + /** An interface describing the data returned by calling `customPropertyCollection.toJSON()`. */ + interface CustomPropertyCollectionData { + items?: PowerPoint.Interfaces.CustomPropertyData[]; + } + /** An interface describing the data returned by calling `documentProperties.toJSON()`. */ + interface DocumentPropertiesData { + /** + * The author of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + author?: string; + /** + * The category of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + category?: string; + /** + * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + comments?: string; + /** + * The company of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + company?: string; + /** + * The creation date of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + creationDate?: Date; + /** + * The keywords of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + keywords?: string; + /** + * The last author of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + lastAuthor?: string; /** - * Represents the indent level of the paragraph. + * The manager of the presentation. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.7] */ - indentLevel?: number; - } - /** An interface describing the data returned by calling `textRange.toJSON()`. */ - interface TextRangeData { + manager?: string; /** - * Gets or sets the length of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. + * The revision number of the presentation. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - length?: number; + revisionNumber?: number; /** - * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * The subject of the presentation. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - start?: number; + subject?: string; /** - * Represents the plain text content of the text range. + * The title of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - text?: string; + title?: string; } - /** An interface describing the data returned by calling `textFrame.toJSON()`. */ - interface TextFrameData { + /** An interface describing the data returned by calling `pageSetup.toJSON()`. */ + interface PageSetupData { /** - * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. + * Specifies the height of the slides in the presentation, in points. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - autoSizeSetting?: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; + slideHeight?: number; /** - * Represents the bottom margin, in points, of the text frame. + * Specifies the width of the slides in the presentation, in points. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - bottomMargin?: number; + slideWidth?: number; + } + /** An interface describing the data returned by calling `slideCollection.toJSON()`. */ + interface SlideCollectionData { + items?: PowerPoint.Interfaces.SlideData[]; + } + /** An interface describing the data returned by calling `slideScopedCollection.toJSON()`. */ + interface SlideScopedCollectionData { + items?: PowerPoint.Interfaces.SlideData[]; + } + /** An interface describing the data returned by calling `slideMasterCollection.toJSON()`. */ + interface SlideMasterCollectionData { + items?: PowerPoint.Interfaces.SlideMasterData[]; + } + /** + * @remarks + * [Api set: PowerPointApi 1.0] + */ + interface PresentationLoadOptions { /** - * Specifies if the text frame contains text. - * - * @remarks - * [Api set: PowerPointApi 1.4] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - hasText?: boolean; + $all?: boolean; /** - * Represents the left margin, in points, of the text frame. + * Returns the page setup information whose properties control slide setup attributes for the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - leftMargin?: number; + pageSetup?: PowerPoint.Interfaces.PageSetupLoadOptions; /** - * Represents the right margin, in points, of the text frame. + * Gets the properties of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - rightMargin?: number; + properties?: PowerPoint.Interfaces.DocumentPropertiesLoadOptions; /** - * Represents the top margin, in points, of the text frame. + * Gets the ID of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - topMargin?: number; + id?: boolean; + title?: boolean; + } + /** + * Represents the adjustment values for a shape. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + interface AdjustmentsLoadOptions { /** - * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + $all?: boolean; /** - * Determines whether lines break automatically to fit text inside the shape. + * Specifies the number of adjustment points. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - wordWrap?: boolean; + count?: boolean; } - /** An interface describing the data returned by calling `shape.toJSON()`. */ - interface ShapeData { + /** + * Represents a custom XML part object. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + interface CustomXmlPartLoadOptions { /** - * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + */ + $all?: boolean; + /** + * The ID of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - height?: number; + id?: boolean; /** - * Gets the unique ID of the shape. + * The namespace URI of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.7] */ - id?: string; + namespaceUri?: boolean; + } + /** + * A scoped collection of custom XML parts. + A scoped collection is the result of some operation (such as filtering by namespace). + A scoped collection cannot be scoped any further. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + interface CustomXmlPartScopedCollectionLoadOptions { /** - * The distance, in points, from the left side of the shape to the left side of the slide. + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + */ + $all?: boolean; + /** + * For EACH ITEM in the collection: The ID of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - left?: number; + id?: boolean; /** - * Returns the level of the specified shape. - - - A level of 0 means the shape isn't part of a group. - - - A level of 1 means the shape is part of a top-level group. - - - A level greater than 1 indicates the shape is a nested group. + * For EACH ITEM in the collection: The namespace URI of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - level?: number; + namespaceUri?: boolean; + } + /** + * A collection of custom XML parts. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + interface CustomXmlPartCollectionLoadOptions { /** - * Specifies the name of this shape. + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + */ + $all?: boolean; + /** + * For EACH ITEM in the collection: The ID of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - name?: string; + id?: boolean; /** - * Specifies the rotation, in degrees, of the shape around the z-axis. - A positive value indicates clockwise rotation, and a negative value indicates counterclockwise rotation. + * For EACH ITEM in the collection: The namespace URI of the custom XML part. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.7] */ - rotation?: number; + namespaceUri?: boolean; + } + /** + * Represents a scoped collection of hyperlinks. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + interface HyperlinkScopedCollectionLoadOptions { /** - * The distance, in points, from the top edge of the shape to the top edge of the slide. + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + */ + $all?: boolean; + /** + * For EACH ITEM in the collection: Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] */ - top?: number; + address?: boolean; /** - * Returns the type of this shape. See {@link PowerPoint.ShapeType} for details. + * For EACH ITEM in the collection: Specifies the string displayed when hovering over the hyperlink. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] */ - type?: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox"; + screenTip?: boolean; /** - * Specifies if the shape is visible. + * For EACH ITEM in the collection: Returns the type of object that the hyperlink is applied to. See {@link PowerPoint.HyperlinkType} for details. * * @remarks * [Api set: PowerPointApi BETA (PREVIEW ONLY)] * @beta */ - visible?: boolean; + type?: boolean; + } + /** + * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + interface BulletFormatLoadOptions { /** - * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. - * - * @remarks - * [Api set: PowerPointApi 1.4] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - width?: number; + $all?: boolean; /** - * Returns the z-order position of the shape, with 0 representing the bottom of the order stack. Every shape on a slide has a unique z-order, but - each slide also has a unique z-order stack, so two shapes on separate slides could have the same z-order number. + * Specifies the style of the bullets in the paragraph. See {@link PowerPoint.BulletStyle} for details. + Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - zOrderPosition?: number; - } - /** An interface describing the data returned by calling `binding.toJSON()`. */ - interface BindingData { + style?: boolean; /** - * Represents the binding identifier. + * Specifies the type of the bullets in the paragraph. See {@link PowerPoint.BulletType} for details. + Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - id?: string; + type?: boolean; /** - * Returns the type of the binding. See `BindingType` for details. + * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - type?: PowerPoint.BindingType | "Shape"; - } - /** An interface describing the data returned by calling `bindingCollection.toJSON()`. */ - interface BindingCollectionData { - items?: PowerPoint.Interfaces.BindingData[]; + visible?: boolean; } - /** An interface describing the data returned by calling `customProperty.toJSON()`. */ - interface CustomPropertyData { + /** + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + interface ParagraphFormatLoadOptions { /** - * The string that uniquely identifies the custom property. - * - * @remarks - * [Api set: PowerPointApi 1.7] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - key?: string; + $all?: boolean; /** - * The type of the value used for the custom property. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bulletFormat?: PowerPoint.Interfaces.BulletFormatLoadOptions; + /** + * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - type?: PowerPoint.DocumentPropertyType | "Boolean" | "Date" | "Number" | "String"; + horizontalAlignment?: boolean; /** - * The value of the custom property. - If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * Represents the indent level of the paragraph. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - value?: boolean | Date | number | string; - } - /** An interface describing the data returned by calling `customPropertyCollection.toJSON()`. */ - interface CustomPropertyCollectionData { - items?: PowerPoint.Interfaces.CustomPropertyData[]; + indentLevel?: boolean; } - /** An interface describing the data returned by calling `documentProperties.toJSON()`. */ - interface DocumentPropertiesData { + /** + * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + interface ShapeFontLoadOptions { /** - * The author of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - author?: string; + $all?: boolean; /** - * The category of the presentation. + * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: + + - `true`: All the text has the **All Caps** attribute. + + - `false`: None of the text has the **All Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.8] */ - category?: string; + allCaps?: boolean; /** - * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. + * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: + + - `true`: All the text is bold. + + - `false`: None of the text is bold. + + - `null`: Returned if some, but not all, of the text is bold. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - comments?: string; + bold?: boolean; /** - * The company of the presentation. + * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - company?: string; + color?: boolean; /** - * The creation date of the presentation. + * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Double strikethrough** attribute. + + - `false`: None of the text has the **Double strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.8] */ - creationDate?: Date; + doubleStrikethrough?: boolean; /** - * The keywords of the presentation. + * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: + + - `true`: All the text is italicized. + + - `false`: None of the text is italicized. + + - `null`: Returned if some, but not all, of the text is italicized. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - keywords?: string; + italic?: boolean; /** - * The last author of the presentation. + * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - lastAuthor?: string; + name?: boolean; /** - * The manager of the presentation. + * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - manager?: string; + size?: boolean; /** - * The revision number of the presentation. + * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: + + - `true`: All the text has the **Small Caps** attribute. + + - `false`: None of the text has the **Small Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.8] */ - revisionNumber?: number; + smallCaps?: boolean; /** - * The subject of the presentation. + * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Strikethrough** attribute. + + - `false`: None of the text has the **Strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.8] */ - subject?: string; + strikethrough?: boolean; /** - * The title of the presentation. + * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Subscript** attribute. + + - `false`: None of the text has the **Subscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.8] */ - title?: string; - } - /** An interface describing the data returned by calling `pageSetup.toJSON()`. */ - interface PageSetupData { + subscript?: boolean; /** - * Specifies the height of the slides in the presentation, in points. + * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Superscript** attribute. + + - `false`: None of the text has the **Superscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.8] */ - slideHeight?: number; + superscript?: boolean; /** - * Specifies the width of the slides in the presentation, in points. + * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.4] */ - slideWidth?: number; - } - /** An interface describing the data returned by calling `slideCollection.toJSON()`. */ - interface SlideCollectionData { - items?: PowerPoint.Interfaces.SlideData[]; - } - /** An interface describing the data returned by calling `slideScopedCollection.toJSON()`. */ - interface SlideScopedCollectionData { - items?: PowerPoint.Interfaces.SlideData[]; - } - /** An interface describing the data returned by calling `slideMasterCollection.toJSON()`. */ - interface SlideMasterCollectionData { - items?: PowerPoint.Interfaces.SlideMasterData[]; + underline?: boolean; } /** + * Represents the text frame of a shape object. + * * @remarks - * [Api set: PowerPointApi 1.0] + * [Api set: PowerPointApi 1.4] */ - interface PresentationLoadOptions { + interface TextFrameLoadOptions { /** Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; /** - * Returns the page setup information whose properties control slide setup attributes for the presentation. + * Represents the text that is attached to a shape in the text frame, and properties and methods for manipulating the text. See {@link PowerPoint.TextRange} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textRange?: PowerPoint.Interfaces.TextRangeLoadOptions; + /** + * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.4] */ - pageSetup?: PowerPoint.Interfaces.PageSetupLoadOptions; + autoSizeSetting?: boolean; /** - * Gets the properties of the presentation. + * Represents the bottom margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - properties?: PowerPoint.Interfaces.DocumentPropertiesLoadOptions; + bottomMargin?: boolean; /** - * Gets the ID of the presentation. + * Specifies if the text frame contains text. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.4] */ - id?: boolean; - title?: boolean; - } - /** - * Represents a custom XML part object. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - interface CustomXmlPartLoadOptions { + hasText?: boolean; /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + * Represents the left margin, in points, of the text frame. + * + * @remarks + * [Api set: PowerPointApi 1.4] */ - $all?: boolean; + leftMargin?: boolean; /** - * The ID of the custom XML part. + * Represents the right margin, in points, of the text frame. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + rightMargin?: boolean; + /** + * Represents the top margin, in points, of the text frame. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + topMargin?: boolean; + /** + * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - id?: boolean; + verticalAlignment?: boolean; /** - * The namespace URI of the custom XML part. + * Determines whether lines break automatically to fit text inside the shape. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - namespaceUri?: boolean; + wordWrap?: boolean; } /** - * A scoped collection of custom XML parts. - A scoped collection is the result of some operation (such as filtering by namespace). - A scoped collection cannot be scoped any further. + * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - interface CustomXmlPartScopedCollectionLoadOptions { + interface TextRangeLoadOptions { /** Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; /** - * For EACH ITEM in the collection: The ID of the custom XML part. + * Returns a `ShapeFont` object that represents the font attributes for the text range. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + font?: PowerPoint.Interfaces.ShapeFontLoadOptions; + /** + * Represents the paragraph format of the text range. See {@link PowerPoint.ParagraphFormat} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + paragraphFormat?: PowerPoint.Interfaces.ParagraphFormatLoadOptions; + /** + * Gets or sets the length of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] */ - id?: boolean; + length?: boolean; /** - * For EACH ITEM in the collection: The namespace URI of the custom XML part. + * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] */ - namespaceUri?: boolean; + start?: boolean; + /** + * Represents the plain text content of the text range. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + text?: boolean; } /** - * A collection of custom XML parts. + * Represents a single hyperlink. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - interface CustomXmlPartCollectionLoadOptions { + interface HyperlinkLoadOptions { /** Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; /** - * For EACH ITEM in the collection: The ID of the custom XML part. + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - id?: boolean; + address?: boolean; /** - * For EACH ITEM in the collection: The namespace URI of the custom XML part. + * Specifies the string displayed when hovering over the hyperlink. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - namespaceUri?: boolean; + screenTip?: boolean; + /** + * Returns the type of object that the hyperlink is applied to. See {@link PowerPoint.HyperlinkType} for details. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + type?: boolean; } /** * Represents the properties of a `placeholder` shape. @@ -192766,56 +193535,38 @@ declare namespace PowerPoint { type?: boolean; } /** - * Represents a single hyperlink. + * Represents a collection of hyperlinks. * * @remarks * [Api set: PowerPointApi 1.6] */ - interface HyperlinkLoadOptions { + interface HyperlinkCollectionLoadOptions { /** Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; /** - * Specifies the URL target of the hyperlink. + * For EACH ITEM in the collection: Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. * * @remarks * [Api set: PowerPointApi 1.6] */ address?: boolean; /** - * Specifies the string displayed when hovering over the hyperlink. + * For EACH ITEM in the collection: Specifies the string displayed when hovering over the hyperlink. * * @remarks * [Api set: PowerPointApi 1.6] */ screenTip?: boolean; - } - /** - * Represents a collection of hyperlinks. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - interface HyperlinkCollectionLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * For EACH ITEM in the collection: Specifies the URL target of the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - address?: boolean; /** - * For EACH ITEM in the collection: Specifies the string displayed when hovering over the hyperlink. + * For EACH ITEM in the collection: Returns the type of object that the hyperlink is applied to. See {@link PowerPoint.HyperlinkType} for details. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - screenTip?: boolean; + type?: boolean; } /** * Represents the properties for a table cell border. @@ -192984,150 +193735,6 @@ declare namespace PowerPoint { */ type?: boolean; } - /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface ShapeFontLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: - - - `true`: All the text has the **All Caps** attribute. - - - `false`: None of the text has the **All Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - allCaps?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: - - - `true`: All the text is bold. - - - `false`: None of the text is bold. - - - `null`: Returned if some, but not all, of the text is bold. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Double strikethrough** attribute. - - - `false`: None of the text has the **Double strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - doubleStrikethrough?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: - - - `true`: All the text is italicized. - - - `false`: None of the text is italicized. - - - `null`: Returned if some, but not all, of the text is italicized. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: - - - `true`: All the text has the **Small Caps** attribute. - - - `false`: None of the text has the **Small Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - smallCaps?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Strikethrough** attribute. - - - `false`: None of the text has the **Strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - strikethrough?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Subscript** attribute. - - - `false`: None of the text has the **Subscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - subscript?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Superscript** attribute. - - - `false`: None of the text has the **Superscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - superscript?: boolean; - /** - * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - underline?: boolean; - } /** * Represents a table. * @@ -193459,13 +194066,12 @@ declare namespace PowerPoint { rowIndex?: boolean; } /** - * Represents the available table style options. + * Represents the available table style settings. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - interface TableStyleOptionsLoadOptions { + interface TableStyleSettingsLoadOptions { /** Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ @@ -193474,56 +194080,49 @@ declare namespace PowerPoint { * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ areColumnsBanded?: boolean; /** * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ areRowsBanded?: boolean; /** * Specifies if the first column contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isFirstColumnHighlighted?: boolean; /** * Specifies if the first row contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isFirstRowHighlighted?: boolean; /** * Specifies if the last column contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isLastColumnHighlighted?: boolean; /** * Specifies if the last row contains special formatting. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ isLastRowHighlighted?: boolean; /** * Specifies the table style. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ style?: boolean; } @@ -193539,13 +194138,12 @@ declare namespace PowerPoint { */ $all?: boolean; /** - * Gets the table style options. + * Gets the table style settings. * * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta + * [Api set: PowerPointApi 1.9] */ - styleOptions?: PowerPoint.Interfaces.TableStyleOptionsLoadOptions; + styleSettings?: PowerPoint.Interfaces.TableStyleSettingsLoadOptions; /** * Gets the number of columns in the table. * @@ -193579,6 +194177,14 @@ declare namespace PowerPoint { Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; + /** + * For EACH ITEM in the collection: Returns an `Adjustments` object that contains adjustment values for all the adjustments in this shape. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + adjustments?: PowerPoint.Interfaces.AdjustmentsLoadOptions; /** * For EACH ITEM in the collection: Returns the fill formatting of this shape. * @@ -193624,6 +194230,14 @@ declare namespace PowerPoint { * [Api set: PowerPointApi 1.4] */ textFrame?: PowerPoint.Interfaces.TextFrameLoadOptions; + /** + * For EACH ITEM in the collection: Gets the creation ID of the shape. Returns `null` if the shape has no creation ID. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + creationId?: boolean; /** * For EACH ITEM in the collection: Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. * @@ -194163,6 +194777,14 @@ declare namespace PowerPoint { Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; + /** + * For EACH ITEM in the collection: Returns an `Adjustments` object that contains adjustment values for all the adjustments in this shape. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + adjustments?: PowerPoint.Interfaces.AdjustmentsLoadOptions; /** * For EACH ITEM in the collection: Returns the fill formatting of this shape. * @@ -194208,6 +194830,14 @@ declare namespace PowerPoint { * [Api set: PowerPointApi 1.5] */ textFrame?: PowerPoint.Interfaces.TextFrameLoadOptions; + /** + * For EACH ITEM in the collection: Gets the creation ID of the shape. Returns `null` if the shape has no creation ID. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + creationId?: boolean; /** * For EACH ITEM in the collection: Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. * @@ -194314,6 +194944,14 @@ declare namespace PowerPoint { * [Api set: PowerPointApi 1.8] */ shape?: PowerPoint.Interfaces.ShapeLoadOptions; + /** + * Gets the creation ID of the shape group. Returns `null` if the shape group has no creation ID. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + creationId?: boolean; /** * Gets the unique ID of the shape group. * @@ -194377,211 +195015,24 @@ declare namespace PowerPoint { weight?: boolean; } /** - * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface BulletFormatLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Specifies the style of the bullets in the paragraph. See {@link PowerPoint.BulletStyle} for details. - Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - style?: boolean; - /** - * Specifies the type of the bullets in the paragraph. See {@link PowerPoint.BulletType} for details. - Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet formatting properties. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - type?: boolean; - /** - * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - visible?: boolean; - } - /** - * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface ParagraphFormatLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bulletFormat?: PowerPoint.Interfaces.BulletFormatLoadOptions; - /** - * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - horizontalAlignment?: boolean; - /** - * Represents the indent level of the paragraph. - * - * @remarks - * [Api set: PowerPointApi BETA (PREVIEW ONLY)] - * @beta - */ - indentLevel?: boolean; - } - /** - * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface TextRangeLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Returns a `ShapeFont` object that represents the font attributes for the text range. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - font?: PowerPoint.Interfaces.ShapeFontLoadOptions; - /** - * Represents the paragraph format of the text range. See {@link PowerPoint.ParagraphFormat} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - paragraphFormat?: PowerPoint.Interfaces.ParagraphFormatLoadOptions; - /** - * Gets or sets the length of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. - * - * @remarks - * [Api set: PowerPointApi 1.5] - */ - length?: boolean; - /** - * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. - * - * @remarks - * [Api set: PowerPointApi 1.5] - */ - start?: boolean; - /** - * Represents the plain text content of the text range. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - text?: boolean; - } - /** - * Represents the text frame of a shape object. + * Represents a single shape in the slide. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.3] */ - interface TextFrameLoadOptions { + interface ShapeLoadOptions { /** Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; /** - * Represents the text that is attached to a shape in the text frame, and properties and methods for manipulating the text. See {@link PowerPoint.TextRange} for details. + * Returns an `Adjustments` object that contains adjustment values for all the adjustments in this shape. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta */ - textRange?: PowerPoint.Interfaces.TextRangeLoadOptions; - /** - * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - autoSizeSetting?: boolean; - /** - * Represents the bottom margin, in points, of the text frame. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bottomMargin?: boolean; - /** - * Specifies if the text frame contains text. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - hasText?: boolean; - /** - * Represents the left margin, in points, of the text frame. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - leftMargin?: boolean; - /** - * Represents the right margin, in points, of the text frame. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - rightMargin?: boolean; - /** - * Represents the top margin, in points, of the text frame. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - topMargin?: boolean; - /** - * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - verticalAlignment?: boolean; - /** - * Determines whether lines break automatically to fit text inside the shape. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - wordWrap?: boolean; - } - /** - * Represents a single shape in the slide. - * - * @remarks - * [Api set: PowerPointApi 1.3] - */ - interface ShapeLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; + adjustments?: PowerPoint.Interfaces.AdjustmentsLoadOptions; /** * Returns the fill formatting of this shape. * @@ -194627,6 +195078,14 @@ declare namespace PowerPoint { * [Api set: PowerPointApi 1.4] */ textFrame?: PowerPoint.Interfaces.TextFrameLoadOptions; + /** + * Gets the creation ID of the shape. Returns `null` if the shape has no creation ID. + * + * @remarks + * [Api set: PowerPointApi BETA (PREVIEW ONLY)] + * @beta + */ + creationId?: boolean; /** * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. * diff --git a/types/office-js/index.d.ts b/types/office-js/index.d.ts index b900dd7e045c85d..29c95c72385909f 100644 --- a/types/office-js/index.d.ts +++ b/types/office-js/index.d.ts @@ -128006,2585 +128006,2464 @@ declare namespace PowerPoint { toJSON(): PowerPoint.Interfaces.CustomXmlPartCollectionData; } /** - * Specifies the type of a placeholder. + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - enum PlaceholderType { - /** - * The placeholder is unsupported. - * @remarks - * [Api set: PowerPointApi 1.8] - */ - unsupported = "Unsupported", - /** - * The placeholder is for a date. - * @remarks - * [Api set: PowerPointApi 1.8] - */ - date = "Date", + enum ParagraphHorizontalAlignment { /** - * The placeholder is for a slide number. + * Align text to the left margin. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - slideNumber = "SlideNumber", + left = "Left", /** - * The placeholder is for a footer. + * Align text in the center. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - footer = "Footer", + center = "Center", /** - * The placeholder is for a header. + * Align text to the right margin. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - header = "Header", + right = "Right", /** - * The placeholder is for a title. + * Align text so that it's justified across the whole line. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - title = "Title", + justify = "Justify", /** - * The placeholder is for a body. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - body = "Body", + justifyLow = "JustifyLow", /** - * The placeholder is for a center title. + * Distributes the text words across an entire text line. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - centerTitle = "CenterTitle", + distributed = "Distributed", /** - * The placeholder is for a subtitle. + * Distributes Thai text specially, because each character is treated as a word. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subtitle = "Subtitle", + thaiDistributed = "ThaiDistributed", + } + /** + * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class BulletFormat extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * The placeholder is for a vertical title. + * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - verticalTitle = "VerticalTitle", + visible: boolean | null; /** - * The placeholder is for a vertical body. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - verticalBody = "VerticalBody", + load(options?: PowerPoint.Interfaces.BulletFormatLoadOptions): PowerPoint.BulletFormat; /** - * The placeholder is for generic content. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - content = "Content", + load(propertyNames?: string | string[]): PowerPoint.BulletFormat; /** - * The placeholder is for a chart. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - chart = "Chart", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.BulletFormat; /** - * The placeholder is for a table. - * @remarks - * [Api set: PowerPointApi 1.8] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.BulletFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BulletFormatData`) that contains shallow copies of any loaded child properties from the original object. */ - table = "Table", + toJSON(): PowerPoint.Interfaces.BulletFormatData; + } + /** + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class ParagraphFormat extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * The placeholder is for an online picture. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - onlinePicture = "OnlinePicture", + readonly bulletFormat: PowerPoint.BulletFormat; /** - * The placeholder is for a SmartArt. + * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. + * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - smartArt = "SmartArt", + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; /** - * The placeholder is for media. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - media = "Media", + load(options?: PowerPoint.Interfaces.ParagraphFormatLoadOptions): PowerPoint.ParagraphFormat; /** - * The placeholder is for generic vertical content. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - verticalContent = "VerticalContent", + load(propertyNames?: string | string[]): PowerPoint.ParagraphFormat; /** - * The placeholder is for a picture. - * @remarks - * [Api set: PowerPointApi 1.8] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - picture = "Picture", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.ParagraphFormat; /** - * The placeholder is for a cameo. - * @remarks - * [Api set: PowerPointApi 1.8] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.ParagraphFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ParagraphFormatData`) that contains shallow copies of any loaded child properties from the original object. */ - cameo = "Cameo", + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** - * Specifies the type of a shape. + * The type of underline applied to a font. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ShapeType { - /** - * The given shape's type is unsupported. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - unsupported = "Unsupported", - /** - * The shape is an image. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - image = "Image", + enum ShapeFontUnderlineStyle { /** - * The shape is a geometric shape such as rectangle. + * No underlining. * @remarks * [Api set: PowerPointApi 1.4] */ - geometricShape = "GeometricShape", + none = "None", /** - * The shape is a group shape which contains sub-shapes. + * Regular single line underlining. * @remarks * [Api set: PowerPointApi 1.4] */ - group = "Group", + single = "Single", /** - * The shape is a line. + * Underlining of text with double lines. * @remarks * [Api set: PowerPointApi 1.4] */ - line = "Line", + double = "Double", /** - * The shape is a table. + * Underlining of text with a thick line. * @remarks * [Api set: PowerPointApi 1.4] */ - table = "Table", + heavy = "Heavy", /** - * The shape is a callout. + * Underlining of text with a dotted line. * @remarks * [Api set: PowerPointApi 1.4] */ - callout = "Callout", + dotted = "Dotted", /** - * The shape is a chart. + * Underlining of text with a thick, dotted line. * @remarks * [Api set: PowerPointApi 1.4] */ - chart = "Chart", + dottedHeavy = "DottedHeavy", /** - * The shape is a content Office Add-in. + * Underlining of text with a line containing dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - contentApp = "ContentApp", + dash = "Dash", /** - * The shape is a diagram. + * Underlining of text with a thick line containing dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - diagram = "Diagram", + dashHeavy = "DashHeavy", /** - * The shape is a freeform object. + * Underlining of text with a line containing long dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - freeform = "Freeform", + dashLong = "DashLong", /** - * The shape is a graphic. + * Underlining of text with a thick line containing long dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - graphic = "Graphic", + dashLongHeavy = "DashLongHeavy", /** - * The shape is an ink object. + * Underlining of text with a line containing dots and dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - ink = "Ink", + dotDash = "DotDash", /** - * The shape is a media object. + * Underlining of text with a thick line containing dots and dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - media = "Media", + dotDashHeavy = "DotDashHeavy", /** - * The shape is a 3D model. + * Underlining of text with a line containing double dots and dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - model3D = "Model3D", + dotDotDash = "DotDotDash", /** - * The shape is an OLE (Object Linking and Embedding) object. + * Underlining of text with a thick line containing double dots and dashes. * @remarks * [Api set: PowerPointApi 1.4] */ - ole = "Ole", + dotDotDashHeavy = "DotDotDashHeavy", /** - * The shape is a placeholder. + * Underlining of text with a wavy line. * @remarks * [Api set: PowerPointApi 1.4] */ - placeholder = "Placeholder", + wavy = "Wavy", /** - * The shape is a SmartArt graphic. + * Underlining of text with a thick, wavy line. * @remarks * [Api set: PowerPointApi 1.4] */ - smartArt = "SmartArt", + wavyHeavy = "WavyHeavy", /** - * The shape is a text box. + * Underlining of text with double wavy lines. * @remarks * [Api set: PowerPointApi 1.4] */ - textBox = "TextBox", + wavyDouble = "WavyDouble", } /** - * Represents the properties of a `placeholder` shape. + * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - class PlaceholderFormat extends OfficeExtension.ClientObject { + class ShapeFont extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Gets the type of the shape contained within the placeholder. See {@link PowerPoint.ShapeType} for details. - Returns `null` if the placeholder is empty. + * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: + + - `true`: All the text has the **All Caps** attribute. + + - `false`: None of the text has the **All Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. * * @remarks * [Api set: PowerPointApi 1.8] */ - readonly containedType: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox" | null; + allCaps: boolean | null; /** - * Returns the type of this placeholder. See {@link PowerPoint.PlaceholderType} for details. + * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: + + - `true`: All the text is bold. + + - `false`: None of the text is bold. + + - `null`: Returned if some, but not all, of the text is bold. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - readonly type: PowerPoint.PlaceholderType | "Unsupported" | "Date" | "SlideNumber" | "Footer" | "Header" | "Title" | "Body" | "CenterTitle" | "Subtitle" | "VerticalTitle" | "VerticalBody" | "Content" | "Chart" | "Table" | "OnlinePicture" | "SmartArt" | "Media" | "VerticalContent" | "Picture" | "Cameo"; + bold: boolean | null; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. * - * @param options Provides options for which properties of the object to load. + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(options?: PowerPoint.Interfaces.PlaceholderFormatLoadOptions): PowerPoint.PlaceholderFormat; + color: string | null; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Double strikethrough** attribute. + + - `false`: None of the text has the **Double strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNames?: string | string[]): PowerPoint.PlaceholderFormat; + doubleStrikethrough: boolean | null; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: + + - `true`: All the text is italicized. + + - `false`: None of the text is italicized. + + - `null`: Returned if some, but not all, of the text is italicized. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.PlaceholderFormat; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.PlaceholderFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.PlaceholderFormatData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.PlaceholderFormatData; - } - /** - * Represents a single hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - class Hyperlink extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + italic: boolean | null; /** - * Specifies the URL target of the hyperlink. + * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.4] */ - address: string; + name: string | null; /** - * Specifies the string displayed when hovering over the hyperlink. + * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.4] */ - screenTip: string; + size: number | null; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: + + - `true`: All the text has the **Small Caps** attribute. + + - `false`: None of the text has the **Small Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. * - * @param options Provides options for which properties of the object to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(options?: PowerPoint.Interfaces.HyperlinkLoadOptions): PowerPoint.Hyperlink; + smallCaps: boolean | null; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Strikethrough** attribute. + + - `false`: None of the text has the **Strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNames?: string | string[]): PowerPoint.Hyperlink; + strikethrough: boolean | null; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Subscript** attribute. + + - `false`: None of the text has the **Subscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Hyperlink; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Hyperlink` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkData`) that contains shallow copies of any loaded child properties from the original object. + * @remarks + * [Api set: PowerPointApi 1.8] */ - toJSON(): PowerPoint.Interfaces.HyperlinkData; - } - /** - * Represents a collection of hyperlinks. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - class HyperlinkCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.Hyperlink[]; + subscript: boolean | null; /** - * Gets the number of hyperlinks in the collection. + * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Superscript** attribute. + + - `false`: None of the text has the **Superscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. * * @remarks - * [Api set: PowerPointApi 1.6] - * @returns The number of hyperlinks in the collection. + * [Api set: PowerPointApi 1.8] */ - getCount(): OfficeExtension.ClientResult; + superscript: boolean | null; /** - * Gets a hyperlink using its zero-based index in the collection. An error is thrown if the index is out of range. + * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks - * [Api set: PowerPointApi 1.6] - * - * @param index The index of the hyperlink in the collection. - * @returns The hyperlink at the given index. An error is thrown if index is out of range. + * [Api set: PowerPointApi 1.4] */ - getItemAt(index: number): PowerPoint.Hyperlink; + underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.HyperlinkCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.HyperlinkCollection; + load(options?: PowerPoint.Interfaces.ShapeFontLoadOptions): PowerPoint.ShapeFont; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.HyperlinkCollection; + load(propertyNames?: string | string[]): PowerPoint.ShapeFont; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.HyperlinkCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.ShapeFont; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.HyperlinkCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Whereas the original `PowerPoint.ShapeFont` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeFontData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.HyperlinkCollectionData; + toJSON(): PowerPoint.Interfaces.ShapeFontData; } /** - * Specifies the connector type for line shapes. + * Determines the type of automatic sizing allowed. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ConnectorType { + enum ShapeAutoSize { /** - * Straight connector type + * No autosizing. * @remarks * [Api set: PowerPointApi 1.4] */ - straight = "Straight", + autoSizeNone = "AutoSizeNone", /** - * Elbow connector type + * The text is adjusted to fit the shape. * @remarks * [Api set: PowerPointApi 1.4] */ - elbow = "Elbow", + autoSizeTextToFitShape = "AutoSizeTextToFitShape", /** - * Curve connector type + * The shape is adjusted to fit the text. * @remarks * [Api set: PowerPointApi 1.4] */ - curve = "Curve", + autoSizeShapeToFitText = "AutoSizeShapeToFitText", + /** + * A combination of automatic sizing schemes are used. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + autoSizeMixed = "AutoSizeMixed", } /** - * Specifies the shape type for a `GeometricShape` object. + * Represents the vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + If one of the centered options is selected, the contents of the `TextFrame` will be centered horizontally within the `Shape` as a group. + To change the horizontal alignment of a text, see {@link PowerPoint.ParagraphFormat} and {@link PowerPoint.ParagraphHorizontalAlignment}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum GeometricShapeType { + enum TextVerticalAlignment { /** - * Straight Line from Top-Right Corner to Bottom-Left Corner of the Shape + * Specifies that the `TextFrame` should be top aligned to the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - lineInverse = "LineInverse", + top = "Top", /** - * Isosceles Triangle + * Specifies that the `TextFrame` should be center aligned to the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - triangle = "Triangle", + middle = "Middle", /** - * Right Triangle + * Specifies that the `TextFrame` should be bottom aligned to the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - rightTriangle = "RightTriangle", + bottom = "Bottom", /** - * Rectangle + * Specifies that the `TextFrame` should be top aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - rectangle = "Rectangle", + topCentered = "TopCentered", /** - * Diamond + * Specifies that the `TextFrame` should be center aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - diamond = "Diamond", + middleCentered = "MiddleCentered", /** - * Parallelogram + * Specifies that the `TextFrame` should be bottom aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. * @remarks * [Api set: PowerPointApi 1.4] */ - parallelogram = "Parallelogram", + bottomCentered = "BottomCentered", + } + /** + * Represents the text frame of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class TextFrame extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Trapezoid + * Represents the text that is attached to a shape in the text frame, and properties and methods for manipulating the text. See {@link PowerPoint.TextRange} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - trapezoid = "Trapezoid", + readonly textRange: PowerPoint.TextRange; /** - * Trapezoid which may have Non-Equal Sides + * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. + * * @remarks * [Api set: PowerPointApi 1.4] */ - nonIsoscelesTrapezoid = "NonIsoscelesTrapezoid", + autoSizeSetting: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; /** - * Pentagon + * Represents the bottom margin, in points, of the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - pentagon = "Pentagon", + bottomMargin: number; /** - * Hexagon + * Specifies if the text frame contains text. + * * @remarks * [Api set: PowerPointApi 1.4] */ - hexagon = "Hexagon", + readonly hasText: boolean; /** - * Heptagon + * Represents the left margin, in points, of the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - heptagon = "Heptagon", + leftMargin: number; /** - * Octagon + * Represents the right margin, in points, of the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - octagon = "Octagon", + rightMargin: number; /** - * Decagon + * Represents the top margin, in points, of the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - decagon = "Decagon", + topMargin: number; /** - * Dodecagon + * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - dodecagon = "Dodecagon", + verticalAlignment: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; /** - * Star: 4 Points + * Determines whether lines break automatically to fit text inside the shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - star4 = "Star4", + wordWrap: boolean; /** - * Star: 5 Points + * Deletes all the text in the text frame. + * * @remarks * [Api set: PowerPointApi 1.4] */ - star5 = "Star5", + deleteText(): void; /** - * Star: 6 Points + * Returns the parent {@link PowerPoint.Shape} object that holds this `TextFrame`. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - star6 = "Star6", + getParentShape(): PowerPoint.Shape; /** - * Star: 7 Points - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - star7 = "Star7", + load(options?: PowerPoint.Interfaces.TextFrameLoadOptions): PowerPoint.TextFrame; /** - * Star: 8 Points - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - star8 = "Star8", + load(propertyNames?: string | string[]): PowerPoint.TextFrame; /** - * Star: 10 Points - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - star10 = "Star10", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TextFrame; /** - * Star: 12 Points - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TextFrame` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TextFrameData`) that contains shallow copies of any loaded child properties from the original object. */ - star12 = "Star12", + toJSON(): PowerPoint.Interfaces.TextFrameData; + } + /** + * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class TextRange extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Star: 16 Points + * Returns a `ShapeFont` object that represents the font attributes for the text range. + * * @remarks * [Api set: PowerPointApi 1.4] */ - star16 = "Star16", + readonly font: PowerPoint.ShapeFont; /** - * Star: 24 Points + * Represents the paragraph format of the text range. See {@link PowerPoint.ParagraphFormat} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - star24 = "Star24", + readonly paragraphFormat: PowerPoint.ParagraphFormat; /** - * Star: 32 Points + * Gets or sets the length of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - star32 = "Star32", + length: number; /** - * Rectangle: Rounded Corners + * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - roundRectangle = "RoundRectangle", + start: number; /** - * Rectangle: Single Corner Rounded + * Represents the plain text content of the text range. + * * @remarks * [Api set: PowerPointApi 1.4] */ - round1Rectangle = "Round1Rectangle", + text: string; /** - * Rectangle: Top Corners Rounded + * Returns the parent {@link PowerPoint.TextFrame} object that holds this `TextRange`. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - round2SameRectangle = "Round2SameRectangle", + getParentTextFrame(): PowerPoint.TextFrame; /** - * Rectangle: Diagonal Corners Rounded + * Returns a `TextRange` object for the substring in the given range. + * * @remarks * [Api set: PowerPointApi 1.4] + * + * @param start The zero-based index of the first character to get from the text range. + * @param length Optional. The number of characters to be returned in the new text range. If length is omitted, all the characters from start to the end of the text range's last paragraph will be returned. */ - round2DiagonalRectangle = "Round2DiagonalRectangle", + getSubstring(start: number, length?: number): PowerPoint.TextRange; /** - * Rectangle: Top Corners One Rounded and One Snipped + * Selects this `TextRange` in the current view. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - snipRoundRectangle = "SnipRoundRectangle", + setSelected(): void; /** - * Rectangle: Single Corner Snipped - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - snip1Rectangle = "Snip1Rectangle", + load(options?: PowerPoint.Interfaces.TextRangeLoadOptions): PowerPoint.TextRange; /** - * Rectangle: Top Corners Snipped - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - snip2SameRectangle = "Snip2SameRectangle", + load(propertyNames?: string | string[]): PowerPoint.TextRange; /** - * Rectangle: Diagonal Corners Snipped - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - snip2DiagonalRectangle = "Snip2DiagonalRectangle", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TextRange; /** - * Plaque - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TextRange` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TextRangeData`) that contains shallow copies of any loaded child properties from the original object. */ - plaque = "Plaque", + toJSON(): PowerPoint.Interfaces.TextRangeData; + } + /** + * Represents a single hyperlink. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + class Hyperlink extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Oval + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] */ - ellipse = "Ellipse", + address: string; /** - * Teardrop + * Specifies the string displayed when hovering over the hyperlink. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] */ - teardrop = "Teardrop", + screenTip: string; /** - * Arrow: Pentagon - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - homePlate = "HomePlate", + load(options?: PowerPoint.Interfaces.HyperlinkLoadOptions): PowerPoint.Hyperlink; /** - * Arrow: Chevron - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - chevron = "Chevron", + load(propertyNames?: string | string[]): PowerPoint.Hyperlink; /** - * Partial Circle - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - pieWedge = "PieWedge", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Hyperlink; /** - * Partial Circle with Adjustable Spanning Area - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.Hyperlink` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkData`) that contains shallow copies of any loaded child properties from the original object. */ - pie = "Pie", + toJSON(): PowerPoint.Interfaces.HyperlinkData; + } + /** + * Specifies the type of a placeholder. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + enum PlaceholderType { /** - * Block Arc + * The placeholder is unsupported. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - blockArc = "BlockArc", + unsupported = "Unsupported", /** - * Circle: Hollow + * The placeholder is for a date. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - donut = "Donut", + date = "Date", /** - * "Not Allowed" Symbol + * The placeholder is for a slide number. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - noSmoking = "NoSmoking", + slideNumber = "SlideNumber", /** - * Arrow: Right + * The placeholder is for a footer. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - rightArrow = "RightArrow", + footer = "Footer", /** - * Arrow: Left + * The placeholder is for a header. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - leftArrow = "LeftArrow", + header = "Header", /** - * Arrow: Up + * The placeholder is for a title. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - upArrow = "UpArrow", + title = "Title", /** - * Arrow: Down + * The placeholder is for a body. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - downArrow = "DownArrow", + body = "Body", /** - * Arrow: Striped Right + * The placeholder is for a center title. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - stripedRightArrow = "StripedRightArrow", + centerTitle = "CenterTitle", /** - * Arrow: Notched Right + * The placeholder is for a subtitle. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - notchedRightArrow = "NotchedRightArrow", + subtitle = "Subtitle", /** - * Arrow: Bent-Up + * The placeholder is for a vertical title. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - bentUpArrow = "BentUpArrow", + verticalTitle = "VerticalTitle", /** - * Arrow: Left-Right + * The placeholder is for a vertical body. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - leftRightArrow = "LeftRightArrow", + verticalBody = "VerticalBody", /** - * Arrow: Up-Down + * The placeholder is for generic content. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - upDownArrow = "UpDownArrow", + content = "Content", /** - * Arrow: Left-Up + * The placeholder is for a chart. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - leftUpArrow = "LeftUpArrow", + chart = "Chart", /** - * Arrow: Left-Right-Up + * The placeholder is for a table. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - leftRightUpArrow = "LeftRightUpArrow", + table = "Table", /** - * Arrow: Quad + * The placeholder is for an online picture. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - quadArrow = "QuadArrow", + onlinePicture = "OnlinePicture", /** - * Callout: Left Arrow + * The placeholder is for a SmartArt. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - leftArrowCallout = "LeftArrowCallout", + smartArt = "SmartArt", /** - * Callout: Right Arrow + * The placeholder is for media. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - rightArrowCallout = "RightArrowCallout", + media = "Media", /** - * Callout: Up Arrow + * The placeholder is for generic vertical content. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - upArrowCallout = "UpArrowCallout", + verticalContent = "VerticalContent", /** - * Callout: Down Arrow + * The placeholder is for a picture. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - downArrowCallout = "DownArrowCallout", + picture = "Picture", /** - * Callout: Left-Right Arrow + * The placeholder is for a cameo. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - leftRightArrowCallout = "LeftRightArrowCallout", + cameo = "Cameo", + } + /** + * Specifies the type of a shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeType { /** - * Callout: Up-Down Arrow + * The given shape's type is unsupported. * @remarks * [Api set: PowerPointApi 1.4] */ - upDownArrowCallout = "UpDownArrowCallout", + unsupported = "Unsupported", /** - * Callout: Quad Arrow + * The shape is an image. * @remarks * [Api set: PowerPointApi 1.4] */ - quadArrowCallout = "QuadArrowCallout", + image = "Image", /** - * Arrow: Bent + * The shape is a geometric shape such as rectangle. * @remarks * [Api set: PowerPointApi 1.4] */ - bentArrow = "BentArrow", + geometricShape = "GeometricShape", /** - * Arrow: U-Turn + * The shape is a group shape which contains sub-shapes. * @remarks * [Api set: PowerPointApi 1.4] */ - uturnArrow = "UturnArrow", + group = "Group", /** - * Arrow: Circular + * The shape is a line. * @remarks * [Api set: PowerPointApi 1.4] */ - circularArrow = "CircularArrow", + line = "Line", /** - * Arrow: Circular with Opposite Arrow Direction + * The shape is a table. * @remarks * [Api set: PowerPointApi 1.4] */ - leftCircularArrow = "LeftCircularArrow", + table = "Table", /** - * Arrow: Circular with Two Arrows in Both Directions + * The shape is a callout. * @remarks * [Api set: PowerPointApi 1.4] */ - leftRightCircularArrow = "LeftRightCircularArrow", + callout = "Callout", /** - * Arrow: Curved Right + * The shape is a chart. * @remarks * [Api set: PowerPointApi 1.4] */ - curvedRightArrow = "CurvedRightArrow", + chart = "Chart", /** - * Arrow: Curved Left + * The shape is a content Office Add-in. * @remarks * [Api set: PowerPointApi 1.4] */ - curvedLeftArrow = "CurvedLeftArrow", + contentApp = "ContentApp", /** - * Arrow: Curved Up + * The shape is a diagram. * @remarks * [Api set: PowerPointApi 1.4] */ - curvedUpArrow = "CurvedUpArrow", + diagram = "Diagram", /** - * Arrow: Curved Down + * The shape is a freeform object. * @remarks * [Api set: PowerPointApi 1.4] */ - curvedDownArrow = "CurvedDownArrow", + freeform = "Freeform", /** - * Arrow: Curved Right Arrow with Varying Width + * The shape is a graphic. * @remarks * [Api set: PowerPointApi 1.4] */ - swooshArrow = "SwooshArrow", + graphic = "Graphic", /** - * Cube + * The shape is an ink object. * @remarks * [Api set: PowerPointApi 1.4] */ - cube = "Cube", + ink = "Ink", /** - * Cylinder + * The shape is a media object. * @remarks * [Api set: PowerPointApi 1.4] */ - can = "Can", + media = "Media", /** - * Lightning Bolt + * The shape is a 3D model. * @remarks * [Api set: PowerPointApi 1.4] */ - lightningBolt = "LightningBolt", + model3D = "Model3D", /** - * Heart + * The shape is an OLE (Object Linking and Embedding) object. * @remarks * [Api set: PowerPointApi 1.4] */ - heart = "Heart", + ole = "Ole", /** - * Sun + * The shape is a placeholder. * @remarks * [Api set: PowerPointApi 1.4] */ - sun = "Sun", + placeholder = "Placeholder", /** - * Moon + * The shape is a SmartArt graphic. * @remarks * [Api set: PowerPointApi 1.4] */ - moon = "Moon", + smartArt = "SmartArt", /** - * Smiley Face + * The shape is a text box. * @remarks * [Api set: PowerPointApi 1.4] */ - smileyFace = "SmileyFace", + textBox = "TextBox", + } + /** + * Represents the properties of a `placeholder` shape. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + class PlaceholderFormat extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Explosion: 8 Points + * Gets the type of the shape contained within the placeholder. See {@link PowerPoint.ShapeType} for details. + Returns `null` if the placeholder is empty. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - irregularSeal1 = "IrregularSeal1", + readonly containedType: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox" | null; /** - * Explosion: 14 Points + * Returns the type of this placeholder. See {@link PowerPoint.PlaceholderType} for details. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - irregularSeal2 = "IrregularSeal2", + readonly type: PowerPoint.PlaceholderType | "Unsupported" | "Date" | "SlideNumber" | "Footer" | "Header" | "Title" | "Body" | "CenterTitle" | "Subtitle" | "VerticalTitle" | "VerticalBody" | "Content" | "Chart" | "Table" | "OnlinePicture" | "SmartArt" | "Media" | "VerticalContent" | "Picture" | "Cameo"; /** - * Rectangle: Folded Corner - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - foldedCorner = "FoldedCorner", + load(options?: PowerPoint.Interfaces.PlaceholderFormatLoadOptions): PowerPoint.PlaceholderFormat; /** - * Rectangle: Beveled - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - bevel = "Bevel", + load(propertyNames?: string | string[]): PowerPoint.PlaceholderFormat; /** - * Frame - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - frame = "Frame", + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.PlaceholderFormat; /** - * Half Frame - * @remarks - * [Api set: PowerPointApi 1.4] - */ - halfFrame = "HalfFrame", + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.PlaceholderFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.PlaceholderFormatData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.PlaceholderFormatData; + } + /** + * Represents a collection of hyperlinks. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + class HyperlinkCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.Hyperlink[]; /** - * L-Shape + * Gets the number of hyperlinks in the collection. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] + * @returns The number of hyperlinks in the collection. */ - corner = "Corner", + getCount(): OfficeExtension.ClientResult; /** - * Diagonal Stripe + * Gets a hyperlink using its zero-based index in the collection. An error is thrown if the index is out of range. + Throws an `InvalidArgument` exception when the index is out of range. + * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.6] + * + * @param index The index of the hyperlink in the collection. + * @returns The hyperlink at the given index. */ - diagonalStripe = "DiagonalStripe", + getItemAt(index: number): PowerPoint.Hyperlink; /** - * Chord - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. */ - chord = "Chord", + load(options?: PowerPoint.Interfaces.HyperlinkCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.HyperlinkCollection; /** - * Arc - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - arc = "Arc", + load(propertyNames?: string | string[]): PowerPoint.HyperlinkCollection; /** - * Left Bracket - * @remarks - * [Api set: PowerPointApi 1.4] + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - leftBracket = "LeftBracket", + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.HyperlinkCollection; /** - * Right Bracket + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.HyperlinkCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.HyperlinkCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + */ + toJSON(): PowerPoint.Interfaces.HyperlinkCollectionData; + } + /** + * Specifies the connector type for line shapes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ConnectorType { + /** + * Straight connector type * @remarks * [Api set: PowerPointApi 1.4] */ - rightBracket = "RightBracket", + straight = "Straight", /** - * Left Brace + * Elbow connector type * @remarks * [Api set: PowerPointApi 1.4] */ - leftBrace = "LeftBrace", + elbow = "Elbow", /** - * Right Brace + * Curve connector type * @remarks * [Api set: PowerPointApi 1.4] */ - rightBrace = "RightBrace", + curve = "Curve", + } + /** + * Specifies the shape type for a `GeometricShape` object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum GeometricShapeType { /** - * Double Bracket + * Straight Line from Top-Right Corner to Bottom-Left Corner of the Shape * @remarks * [Api set: PowerPointApi 1.4] */ - bracketPair = "BracketPair", + lineInverse = "LineInverse", /** - * Double Brace + * Isosceles Triangle * @remarks * [Api set: PowerPointApi 1.4] */ - bracePair = "BracePair", + triangle = "Triangle", /** - * Callout: Line with No Border + * Right Triangle * @remarks * [Api set: PowerPointApi 1.4] */ - callout1 = "Callout1", + rightTriangle = "RightTriangle", /** - * Callout: Bent Line with No Border + * Rectangle * @remarks * [Api set: PowerPointApi 1.4] */ - callout2 = "Callout2", + rectangle = "Rectangle", /** - * Callout: Double Bent Line with No Border + * Diamond * @remarks * [Api set: PowerPointApi 1.4] */ - callout3 = "Callout3", + diamond = "Diamond", /** - * Callout: Line with Accent Bar + * Parallelogram * @remarks * [Api set: PowerPointApi 1.4] */ - accentCallout1 = "AccentCallout1", + parallelogram = "Parallelogram", /** - * Callout: Bent Line with Accent Bar + * Trapezoid * @remarks * [Api set: PowerPointApi 1.4] */ - accentCallout2 = "AccentCallout2", + trapezoid = "Trapezoid", /** - * Callout: Double Bent Line with Accent Bar + * Trapezoid which may have Non-Equal Sides * @remarks * [Api set: PowerPointApi 1.4] */ - accentCallout3 = "AccentCallout3", + nonIsoscelesTrapezoid = "NonIsoscelesTrapezoid", /** - * Callout: Line + * Pentagon * @remarks * [Api set: PowerPointApi 1.4] */ - borderCallout1 = "BorderCallout1", + pentagon = "Pentagon", /** - * Callout: Bent Line + * Hexagon * @remarks * [Api set: PowerPointApi 1.4] */ - borderCallout2 = "BorderCallout2", + hexagon = "Hexagon", /** - * Callout: Double Bent Line + * Heptagon * @remarks * [Api set: PowerPointApi 1.4] */ - borderCallout3 = "BorderCallout3", + heptagon = "Heptagon", /** - * Callout: Line with Border and Accent Bar + * Octagon * @remarks * [Api set: PowerPointApi 1.4] */ - accentBorderCallout1 = "AccentBorderCallout1", + octagon = "Octagon", /** - * Callout: Bent Line with Border and Accent Bar + * Decagon * @remarks * [Api set: PowerPointApi 1.4] */ - accentBorderCallout2 = "AccentBorderCallout2", + decagon = "Decagon", /** - * Callout: Double Bent Line with Border and Accent Bar + * Dodecagon * @remarks * [Api set: PowerPointApi 1.4] */ - accentBorderCallout3 = "AccentBorderCallout3", + dodecagon = "Dodecagon", /** - * Speech Bubble: Rectangle + * Star: 4 Points * @remarks * [Api set: PowerPointApi 1.4] */ - wedgeRectCallout = "WedgeRectCallout", + star4 = "Star4", /** - * Speech Bubble: Rectangle with Corners Rounded + * Star: 5 Points * @remarks * [Api set: PowerPointApi 1.4] */ - wedgeRRectCallout = "WedgeRRectCallout", + star5 = "Star5", /** - * Speech Bubble: Oval + * Star: 6 Points * @remarks * [Api set: PowerPointApi 1.4] */ - wedgeEllipseCallout = "WedgeEllipseCallout", + star6 = "Star6", /** - * Thought Bubble: Cloud + * Star: 7 Points * @remarks * [Api set: PowerPointApi 1.4] */ - cloudCallout = "CloudCallout", + star7 = "Star7", /** - * Cloud + * Star: 8 Points * @remarks * [Api set: PowerPointApi 1.4] */ - cloud = "Cloud", + star8 = "Star8", /** - * Ribbon: Tilted Down + * Star: 10 Points * @remarks * [Api set: PowerPointApi 1.4] */ - ribbon = "Ribbon", + star10 = "Star10", /** - * Ribbon: Tilted Up + * Star: 12 Points * @remarks * [Api set: PowerPointApi 1.4] */ - ribbon2 = "Ribbon2", + star12 = "Star12", /** - * Ribbon: Curved and Tilted Down + * Star: 16 Points * @remarks * [Api set: PowerPointApi 1.4] */ - ellipseRibbon = "EllipseRibbon", + star16 = "Star16", /** - * Ribbon: Curved and Tilted Up + * Star: 24 Points * @remarks * [Api set: PowerPointApi 1.4] */ - ellipseRibbon2 = "EllipseRibbon2", + star24 = "Star24", /** - * Ribbon: Straight with Both Left and Right Arrows + * Star: 32 Points * @remarks * [Api set: PowerPointApi 1.4] */ - leftRightRibbon = "LeftRightRibbon", + star32 = "Star32", /** - * Scroll: Vertical + * Rectangle: Rounded Corners * @remarks * [Api set: PowerPointApi 1.4] */ - verticalScroll = "VerticalScroll", + roundRectangle = "RoundRectangle", /** - * Scroll: Horizontal + * Rectangle: Single Corner Rounded * @remarks * [Api set: PowerPointApi 1.4] */ - horizontalScroll = "HorizontalScroll", + round1Rectangle = "Round1Rectangle", /** - * Wave + * Rectangle: Top Corners Rounded * @remarks * [Api set: PowerPointApi 1.4] */ - wave = "Wave", + round2SameRectangle = "Round2SameRectangle", /** - * Double Wave + * Rectangle: Diagonal Corners Rounded * @remarks * [Api set: PowerPointApi 1.4] */ - doubleWave = "DoubleWave", + round2DiagonalRectangle = "Round2DiagonalRectangle", /** - * Cross + * Rectangle: Top Corners One Rounded and One Snipped * @remarks * [Api set: PowerPointApi 1.4] */ - plus = "Plus", + snipRoundRectangle = "SnipRoundRectangle", /** - * Flowchart: Process + * Rectangle: Single Corner Snipped * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartProcess = "FlowChartProcess", + snip1Rectangle = "Snip1Rectangle", /** - * Flowchart: Decision + * Rectangle: Top Corners Snipped * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartDecision = "FlowChartDecision", + snip2SameRectangle = "Snip2SameRectangle", /** - * Flowchart: Data + * Rectangle: Diagonal Corners Snipped * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartInputOutput = "FlowChartInputOutput", + snip2DiagonalRectangle = "Snip2DiagonalRectangle", /** - * Flowchart: Predefined Process + * Plaque * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartPredefinedProcess = "FlowChartPredefinedProcess", + plaque = "Plaque", /** - * Flowchart: Internal Storage + * Oval * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartInternalStorage = "FlowChartInternalStorage", + ellipse = "Ellipse", /** - * Flowchart: Document + * Teardrop * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartDocument = "FlowChartDocument", + teardrop = "Teardrop", /** - * Flowchart: Multidocument + * Arrow: Pentagon * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMultidocument = "FlowChartMultidocument", + homePlate = "HomePlate", /** - * Flowchart: Terminator + * Arrow: Chevron * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartTerminator = "FlowChartTerminator", + chevron = "Chevron", /** - * Flowchart: Preparation + * Partial Circle * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartPreparation = "FlowChartPreparation", + pieWedge = "PieWedge", /** - * Flowchart: Manual Input + * Partial Circle with Adjustable Spanning Area * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartManualInput = "FlowChartManualInput", + pie = "Pie", /** - * Flowchart: Manual Operation + * Block Arc * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartManualOperation = "FlowChartManualOperation", + blockArc = "BlockArc", /** - * Flowchart: Connector + * Circle: Hollow * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartConnector = "FlowChartConnector", + donut = "Donut", /** - * Flowchart: Card + * "Not Allowed" Symbol * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartPunchedCard = "FlowChartPunchedCard", + noSmoking = "NoSmoking", /** - * Flowchart: Punched Tape + * Arrow: Right * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartPunchedTape = "FlowChartPunchedTape", + rightArrow = "RightArrow", /** - * Flowchart: Summing Junction + * Arrow: Left * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartSummingJunction = "FlowChartSummingJunction", + leftArrow = "LeftArrow", /** - * Flowchart: Or + * Arrow: Up * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartOr = "FlowChartOr", + upArrow = "UpArrow", /** - * Flowchart: Collate + * Arrow: Down * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartCollate = "FlowChartCollate", + downArrow = "DownArrow", /** - * Flowchart: Sort + * Arrow: Striped Right * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartSort = "FlowChartSort", + stripedRightArrow = "StripedRightArrow", /** - * Flowchart: Extract + * Arrow: Notched Right * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartExtract = "FlowChartExtract", + notchedRightArrow = "NotchedRightArrow", /** - * Flowchart: Merge + * Arrow: Bent-Up * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMerge = "FlowChartMerge", + bentUpArrow = "BentUpArrow", /** - * FlowChart: Offline Storage + * Arrow: Left-Right * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartOfflineStorage = "FlowChartOfflineStorage", + leftRightArrow = "LeftRightArrow", /** - * Flowchart: Stored Data + * Arrow: Up-Down * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartOnlineStorage = "FlowChartOnlineStorage", + upDownArrow = "UpDownArrow", /** - * Flowchart: Sequential Access Storage + * Arrow: Left-Up * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMagneticTape = "FlowChartMagneticTape", + leftUpArrow = "LeftUpArrow", /** - * Flowchart: Magnetic Disk + * Arrow: Left-Right-Up * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMagneticDisk = "FlowChartMagneticDisk", + leftRightUpArrow = "LeftRightUpArrow", /** - * Flowchart: Direct Access Storage + * Arrow: Quad * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartMagneticDrum = "FlowChartMagneticDrum", + quadArrow = "QuadArrow", /** - * Flowchart: Display + * Callout: Left Arrow * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartDisplay = "FlowChartDisplay", + leftArrowCallout = "LeftArrowCallout", /** - * Flowchart: Delay + * Callout: Right Arrow * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartDelay = "FlowChartDelay", + rightArrowCallout = "RightArrowCallout", /** - * Flowchart: Alternate Process + * Callout: Up Arrow * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartAlternateProcess = "FlowChartAlternateProcess", + upArrowCallout = "UpArrowCallout", /** - * Flowchart: Off-page Connector + * Callout: Down Arrow * @remarks * [Api set: PowerPointApi 1.4] */ - flowChartOffpageConnector = "FlowChartOffpageConnector", + downArrowCallout = "DownArrowCallout", /** - * Action Button: Blank + * Callout: Left-Right Arrow * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonBlank = "ActionButtonBlank", + leftRightArrowCallout = "LeftRightArrowCallout", /** - * Action Button: Go Home + * Callout: Up-Down Arrow * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonHome = "ActionButtonHome", + upDownArrowCallout = "UpDownArrowCallout", /** - * Action Button: Help + * Callout: Quad Arrow * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonHelp = "ActionButtonHelp", + quadArrowCallout = "QuadArrowCallout", /** - * Action Button: Get Information + * Arrow: Bent * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonInformation = "ActionButtonInformation", + bentArrow = "BentArrow", /** - * Action Button: Go Forward or Next + * Arrow: U-Turn * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonForwardNext = "ActionButtonForwardNext", + uturnArrow = "UturnArrow", /** - * Action Button: Go Back or Previous + * Arrow: Circular * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonBackPrevious = "ActionButtonBackPrevious", + circularArrow = "CircularArrow", /** - * Action Button: Go to End + * Arrow: Circular with Opposite Arrow Direction * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonEnd = "ActionButtonEnd", + leftCircularArrow = "LeftCircularArrow", /** - * Action Button: Go to Beginning + * Arrow: Circular with Two Arrows in Both Directions * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonBeginning = "ActionButtonBeginning", + leftRightCircularArrow = "LeftRightCircularArrow", /** - * Action Button: Return + * Arrow: Curved Right * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonReturn = "ActionButtonReturn", + curvedRightArrow = "CurvedRightArrow", /** - * Action Button: Document + * Arrow: Curved Left * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonDocument = "ActionButtonDocument", + curvedLeftArrow = "CurvedLeftArrow", /** - * Action Button: Sound + * Arrow: Curved Up * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonSound = "ActionButtonSound", + curvedUpArrow = "CurvedUpArrow", /** - * Action Button: Video + * Arrow: Curved Down * @remarks * [Api set: PowerPointApi 1.4] */ - actionButtonMovie = "ActionButtonMovie", + curvedDownArrow = "CurvedDownArrow", /** - * Gear: A Gear with Six Teeth + * Arrow: Curved Right Arrow with Varying Width * @remarks * [Api set: PowerPointApi 1.4] */ - gear6 = "Gear6", + swooshArrow = "SwooshArrow", /** - * Gear: A Gear with Nine Teeth + * Cube * @remarks * [Api set: PowerPointApi 1.4] */ - gear9 = "Gear9", + cube = "Cube", /** - * Funnel + * Cylinder * @remarks * [Api set: PowerPointApi 1.4] */ - funnel = "Funnel", + can = "Can", /** - * Plus Sign + * Lightning Bolt * @remarks * [Api set: PowerPointApi 1.4] */ - mathPlus = "MathPlus", + lightningBolt = "LightningBolt", /** - * Minus Sign + * Heart * @remarks * [Api set: PowerPointApi 1.4] */ - mathMinus = "MathMinus", + heart = "Heart", /** - * Multiplication Sign + * Sun * @remarks * [Api set: PowerPointApi 1.4] */ - mathMultiply = "MathMultiply", + sun = "Sun", /** - * Division Sign + * Moon * @remarks * [Api set: PowerPointApi 1.4] */ - mathDivide = "MathDivide", + moon = "Moon", /** - * Equals + * Smiley Face * @remarks * [Api set: PowerPointApi 1.4] */ - mathEqual = "MathEqual", + smileyFace = "SmileyFace", /** - * Not Equal + * Explosion: 8 Points * @remarks * [Api set: PowerPointApi 1.4] */ - mathNotEqual = "MathNotEqual", + irregularSeal1 = "IrregularSeal1", /** - * Four Right Triangles that Define a Rectangular Shape + * Explosion: 14 Points * @remarks * [Api set: PowerPointApi 1.4] */ - cornerTabs = "CornerTabs", + irregularSeal2 = "IrregularSeal2", /** - * Four Small Squares that Define a Rectangular Shape. + * Rectangle: Folded Corner * @remarks * [Api set: PowerPointApi 1.4] */ - squareTabs = "SquareTabs", + foldedCorner = "FoldedCorner", /** - * Four Quarter Circles that Define a Rectangular Shape. + * Rectangle: Beveled * @remarks * [Api set: PowerPointApi 1.4] */ - plaqueTabs = "PlaqueTabs", + bevel = "Bevel", /** - * A Rectangle Divided into Four Parts Along Diagonal Lines. + * Frame * @remarks * [Api set: PowerPointApi 1.4] */ - chartX = "ChartX", + frame = "Frame", /** - * A Rectangle Divided into Six Parts Along a Vertical Line and Diagonal Lines. + * Half Frame * @remarks * [Api set: PowerPointApi 1.4] */ - chartStar = "ChartStar", + halfFrame = "HalfFrame", /** - * A Rectangle Divided Vertically and Horizontally into Four Quarters. + * L-Shape * @remarks * [Api set: PowerPointApi 1.4] */ - chartPlus = "ChartPlus", - } - /** - * Represents the available options when adding shapes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface ShapeAddOptions { + corner = "Corner", /** - * Specifies the height, in points, of the shape. - When not provided, a default value will be used. - Throws an `InvalidArgument` exception when set with a negative value. - * + * Diagonal Stripe * @remarks * [Api set: PowerPointApi 1.4] */ - height?: number; + diagonalStripe = "DiagonalStripe", /** - * Specifies the distance, in points, from the left side of the shape to the left side of the slide. - When not provided, a default value will be used. - * + * Chord * @remarks * [Api set: PowerPointApi 1.4] */ - left?: number; + chord = "Chord", /** - * Specifies the distance, in points, from the top edge of the shape to the top edge of the slide. - When not provided, a default value will be used. - * + * Arc * @remarks * [Api set: PowerPointApi 1.4] */ - top?: number; + arc = "Arc", /** - * Specifies the width, in points, of the shape. - When not provided, a default value will be used. - Throws an `InvalidArgument` exception when set with a negative value. - * + * Left Bracket * @remarks * [Api set: PowerPointApi 1.4] */ - width?: number; - } - /** - * Specifies the dash style for a line. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ShapeLineDashStyle { + leftBracket = "LeftBracket", /** - * The dash line pattern. + * Right Bracket * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + rightBracket = "RightBracket", /** - * The dash-dot line pattern. + * Left Brace * @remarks * [Api set: PowerPointApi 1.4] */ - dashDot = "DashDot", + leftBrace = "LeftBrace", /** - * The dash-dot-dot line pattern. + * Right Brace * @remarks * [Api set: PowerPointApi 1.4] */ - dashDotDot = "DashDotDot", + rightBrace = "RightBrace", /** - * The long dash line pattern. + * Double Bracket * @remarks * [Api set: PowerPointApi 1.4] */ - longDash = "LongDash", + bracketPair = "BracketPair", /** - * The long dash-dot line pattern. + * Double Brace * @remarks * [Api set: PowerPointApi 1.4] */ - longDashDot = "LongDashDot", + bracePair = "BracePair", /** - * The round dot line pattern. + * Callout: Line with No Border * @remarks * [Api set: PowerPointApi 1.4] */ - roundDot = "RoundDot", + callout1 = "Callout1", /** - * The solid line pattern. + * Callout: Bent Line with No Border * @remarks * [Api set: PowerPointApi 1.4] */ - solid = "Solid", + callout2 = "Callout2", /** - * The square dot line pattern. + * Callout: Double Bent Line with No Border * @remarks * [Api set: PowerPointApi 1.4] */ - squareDot = "SquareDot", + callout3 = "Callout3", /** - * The long dash-dot-dot line pattern. + * Callout: Line with Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - longDashDotDot = "LongDashDotDot", + accentCallout1 = "AccentCallout1", /** - * The system dash line pattern. + * Callout: Bent Line with Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - systemDash = "SystemDash", + accentCallout2 = "AccentCallout2", /** - * The system dot line pattern. + * Callout: Double Bent Line with Accent Bar * @remarks * [Api set: PowerPointApi 1.4] */ - systemDot = "SystemDot", + accentCallout3 = "AccentCallout3", /** - * The system dash-dot line pattern. + * Callout: Line * @remarks * [Api set: PowerPointApi 1.4] */ - systemDashDot = "SystemDashDot", - } - /** - * Represents the properties for a table cell border. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class Border extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + borderCallout1 = "BorderCallout1", /** - * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). - * + * Callout: Bent Line * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - color: string | undefined; + borderCallout2 = "BorderCallout2", /** - * Represents the dash style of the line. - * + * Callout: Double Bent Line * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - dashStyle: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; + borderCallout3 = "BorderCallout3", /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). - * + * Callout: Line with Border and Accent Bar * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - transparency: number | undefined; + accentBorderCallout1 = "AccentBorderCallout1", /** - * Represents the weight of the line, in points. - * + * Callout: Bent Line with Border and Accent Bar * @remarks - * [Api set: PowerPointApi 1.9] - */ - weight: number | undefined; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.BorderLoadOptions): PowerPoint.Border; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.Border; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Border; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Border` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BorderData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.BorderData; - } - /** - * Represents the borders for a table cell. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class Borders extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + accentBorderCallout2 = "AccentBorderCallout2", /** - * Gets the bottom border. - * + * Callout: Double Bent Line with Border and Accent Bar * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly bottom: PowerPoint.Border; + accentBorderCallout3 = "AccentBorderCallout3", /** - * Gets the diagonal border (top-left to bottom-right). - * + * Speech Bubble: Rectangle * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly diagonalDown: PowerPoint.Border; + wedgeRectCallout = "WedgeRectCallout", /** - * Gets the diagonal border (bottom-left to top-right). - * + * Speech Bubble: Rectangle with Corners Rounded * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly diagonalUp: PowerPoint.Border; + wedgeRRectCallout = "WedgeRRectCallout", /** - * Gets the left border. - * + * Speech Bubble: Oval * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly left: PowerPoint.Border; + wedgeEllipseCallout = "WedgeEllipseCallout", /** - * Gets the right border. - * + * Thought Bubble: Cloud * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly right: PowerPoint.Border; + cloudCallout = "CloudCallout", /** - * Gets the top border. - * + * Cloud * @remarks - * [Api set: PowerPointApi 1.9] - */ - readonly top: PowerPoint.Border; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.BordersLoadOptions): PowerPoint.Borders; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.Borders; + cloud = "Cloud", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Ribbon: Tilted Down + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Borders; + ribbon = "Ribbon", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Borders` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BordersData`) that contains shallow copies of any loaded child properties from the original object. + * Ribbon: Tilted Up + * @remarks + * [Api set: PowerPointApi 1.4] */ - toJSON(): PowerPoint.Interfaces.BordersData; - } - /** - * Represents the margins of a table cell. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class Margins extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + ribbon2 = "Ribbon2", /** - * Specifies the bottom margin in points. - * + * Ribbon: Curved and Tilted Down * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - bottom: number | undefined; + ellipseRibbon = "EllipseRibbon", /** - * Specifies the left margin in points. - * + * Ribbon: Curved and Tilted Up * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - left: number | undefined; + ellipseRibbon2 = "EllipseRibbon2", /** - * Specifies the right margin in points. - * + * Ribbon: Straight with Both Left and Right Arrows * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - right: number | undefined; + leftRightRibbon = "LeftRightRibbon", /** - * Specifies the top margin in points. - * + * Scroll: Vertical * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - top: number | undefined; + verticalScroll = "VerticalScroll", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Scroll: Horizontal + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(options?: PowerPoint.Interfaces.MarginsLoadOptions): PowerPoint.Margins; + horizontalScroll = "HorizontalScroll", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Wave + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.Margins; + wave = "Wave", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Double Wave + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Margins; + doubleWave = "DoubleWave", /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Margins` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.MarginsData`) that contains shallow copies of any loaded child properties from the original object. + * Cross + * @remarks + * [Api set: PowerPointApi 1.4] */ - toJSON(): PowerPoint.Interfaces.MarginsData; - } - /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ParagraphHorizontalAlignment { + plus = "Plus", /** - * Align text to the left margin. + * Flowchart: Process * @remarks * [Api set: PowerPointApi 1.4] */ - left = "Left", + flowChartProcess = "FlowChartProcess", /** - * Align text in the center. + * Flowchart: Decision * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + flowChartDecision = "FlowChartDecision", /** - * Align text to the right margin. + * Flowchart: Data * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + flowChartInputOutput = "FlowChartInputOutput", /** - * Align text so that it's justified across the whole line. + * Flowchart: Predefined Process * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + flowChartPredefinedProcess = "FlowChartPredefinedProcess", /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * Flowchart: Internal Storage * @remarks * [Api set: PowerPointApi 1.4] */ - justifyLow = "JustifyLow", + flowChartInternalStorage = "FlowChartInternalStorage", /** - * Distributes the text words across an entire text line. + * Flowchart: Document * @remarks * [Api set: PowerPointApi 1.4] */ - distributed = "Distributed", + flowChartDocument = "FlowChartDocument", /** - * Distributes Thai text specially, because each character is treated as a word. + * Flowchart: Multidocument * @remarks * [Api set: PowerPointApi 1.4] */ - thaiDistributed = "ThaiDistributed", - } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ShapeFillType { + flowChartMultidocument = "FlowChartMultidocument", /** - * Specifies that the shape should have no fill. + * Flowchart: Terminator * @remarks * [Api set: PowerPointApi 1.4] */ - noFill = "NoFill", + flowChartTerminator = "FlowChartTerminator", /** - * Specifies that the shape should have regular solid fill. + * Flowchart: Preparation * @remarks * [Api set: PowerPointApi 1.4] */ - solid = "Solid", + flowChartPreparation = "FlowChartPreparation", /** - * Specifies that the shape should have gradient fill. + * Flowchart: Manual Input * @remarks * [Api set: PowerPointApi 1.4] */ - gradient = "Gradient", + flowChartManualInput = "FlowChartManualInput", /** - * Specifies that the shape should have pattern fill. + * Flowchart: Manual Operation * @remarks * [Api set: PowerPointApi 1.4] */ - pattern = "Pattern", + flowChartManualOperation = "FlowChartManualOperation", /** - * Specifies that the shape should have picture or texture fill. + * Flowchart: Connector * @remarks * [Api set: PowerPointApi 1.4] */ - pictureAndTexture = "PictureAndTexture", + flowChartConnector = "FlowChartConnector", /** - * Specifies that the shape should have slide background fill. + * Flowchart: Card * @remarks * [Api set: PowerPointApi 1.4] */ - slideBackground = "SlideBackground", - } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - class ShapeFill extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + flowChartPunchedCard = "FlowChartPunchedCard", /** - * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). - * + * Flowchart: Punched Tape * @remarks * [Api set: PowerPointApi 1.4] */ - foregroundColor: string; + flowChartPunchedTape = "FlowChartPunchedTape", /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. - * + * Flowchart: Summing Junction * @remarks * [Api set: PowerPointApi 1.4] */ - transparency: number; + flowChartSummingJunction = "FlowChartSummingJunction", /** - * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. - * + * Flowchart: Or * @remarks * [Api set: PowerPointApi 1.4] */ - readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; + flowChartOr = "FlowChartOr", /** - * Clears the fill formatting of this shape. - * + * Flowchart: Collate * @remarks * [Api set: PowerPointApi 1.4] */ - clear(): void; + flowChartCollate = "FlowChartCollate", /** - * Sets the fill formatting of the shape to an image. This changes the fill type to `PictureAndTexture`. - * + * Flowchart: Sort * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param base64EncodedImage A string that is a Base64 encoding of the image data. + * [Api set: PowerPointApi 1.4] */ - setImage(base64EncodedImage: string): void; + flowChartSort = "FlowChartSort", /** - * Sets the fill formatting of the shape to a uniform color. This changes the fill type to `Solid`. - * + * Flowchart: Extract * @remarks * [Api set: PowerPointApi 1.4] - * - * @param color A string that specifies the fill color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). - */ - setSolidColor(color: string): void; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.ShapeFill; + flowChartExtract = "FlowChartExtract", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Flowchart: Merge + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.ShapeFill; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ShapeFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeFillData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.ShapeFillData; - } - /** - * The type of underline applied to a font. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum ShapeFontUnderlineStyle { + flowChartMerge = "FlowChartMerge", /** - * No underlining. + * FlowChart: Offline Storage * @remarks * [Api set: PowerPointApi 1.4] */ - none = "None", + flowChartOfflineStorage = "FlowChartOfflineStorage", /** - * Regular single line underlining. + * Flowchart: Stored Data * @remarks * [Api set: PowerPointApi 1.4] */ - single = "Single", + flowChartOnlineStorage = "FlowChartOnlineStorage", /** - * Underlining of text with double lines. + * Flowchart: Sequential Access Storage * @remarks * [Api set: PowerPointApi 1.4] */ - double = "Double", + flowChartMagneticTape = "FlowChartMagneticTape", /** - * Underlining of text with a thick line. + * Flowchart: Magnetic Disk * @remarks * [Api set: PowerPointApi 1.4] */ - heavy = "Heavy", + flowChartMagneticDisk = "FlowChartMagneticDisk", /** - * Underlining of text with a dotted line. + * Flowchart: Direct Access Storage * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + flowChartMagneticDrum = "FlowChartMagneticDrum", /** - * Underlining of text with a thick, dotted line. + * Flowchart: Display * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + flowChartDisplay = "FlowChartDisplay", /** - * Underlining of text with a line containing dashes. + * Flowchart: Delay * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + flowChartDelay = "FlowChartDelay", /** - * Underlining of text with a thick line containing dashes. + * Flowchart: Alternate Process * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + flowChartAlternateProcess = "FlowChartAlternateProcess", /** - * Underlining of text with a line containing long dashes. + * Flowchart: Off-page Connector * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + flowChartOffpageConnector = "FlowChartOffpageConnector", /** - * Underlining of text with a thick line containing long dashes. + * Action Button: Blank * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + actionButtonBlank = "ActionButtonBlank", /** - * Underlining of text with a line containing dots and dashes. + * Action Button: Go Home * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + actionButtonHome = "ActionButtonHome", /** - * Underlining of text with a thick line containing dots and dashes. + * Action Button: Help * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + actionButtonHelp = "ActionButtonHelp", /** - * Underlining of text with a line containing double dots and dashes. + * Action Button: Get Information * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + actionButtonInformation = "ActionButtonInformation", /** - * Underlining of text with a thick line containing double dots and dashes. + * Action Button: Go Forward or Next * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + actionButtonForwardNext = "ActionButtonForwardNext", /** - * Underlining of text with a wavy line. + * Action Button: Go Back or Previous * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + actionButtonBackPrevious = "ActionButtonBackPrevious", /** - * Underlining of text with a thick, wavy line. + * Action Button: Go to End * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + actionButtonEnd = "ActionButtonEnd", /** - * Underlining of text with double wavy lines. + * Action Button: Go to Beginning * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", - } - /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - class ShapeFont extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + actionButtonBeginning = "ActionButtonBeginning", /** - * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: - - - `true`: All the text has the **All Caps** attribute. - - - `false`: None of the text has the **All Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. - * + * Action Button: Return * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - allCaps: boolean | null; + actionButtonReturn = "ActionButtonReturn", /** - * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: - - - `true`: All the text is bold. - - - `false`: None of the text is bold. - - - `null`: Returned if some, but not all, of the text is bold. - * + * Action Button: Document * @remarks * [Api set: PowerPointApi 1.4] */ - bold: boolean | null; + actionButtonDocument = "ActionButtonDocument", /** - * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. - * + * Action Button: Sound * @remarks * [Api set: PowerPointApi 1.4] */ - color: string | null; + actionButtonSound = "ActionButtonSound", /** - * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Double strikethrough** attribute. - - - `false`: None of the text has the **Double strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. - * + * Action Button: Video * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - doubleStrikethrough: boolean | null; + actionButtonMovie = "ActionButtonMovie", /** - * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: - - - `true`: All the text is italicized. - - - `false`: None of the text is italicized. - - - `null`: Returned if some, but not all, of the text is italicized. - * + * Gear: A Gear with Six Teeth * @remarks * [Api set: PowerPointApi 1.4] */ - italic: boolean | null; + gear6 = "Gear6", /** - * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. - * + * Gear: A Gear with Nine Teeth * @remarks * [Api set: PowerPointApi 1.4] */ - name: string | null; + gear9 = "Gear9", /** - * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. - * + * Funnel * @remarks * [Api set: PowerPointApi 1.4] */ - size: number | null; + funnel = "Funnel", /** - * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: - - - `true`: All the text has the **Small Caps** attribute. - - - `false`: None of the text has the **Small Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. - * + * Plus Sign * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - smallCaps: boolean | null; + mathPlus = "MathPlus", /** - * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Strikethrough** attribute. - - - `false`: None of the text has the **Strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. - * + * Minus Sign * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - strikethrough: boolean | null; + mathMinus = "MathMinus", /** - * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Subscript** attribute. - - - `false`: None of the text has the **Subscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. - * + * Multiplication Sign * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subscript: boolean | null; + mathMultiply = "MathMultiply", /** - * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Superscript** attribute. - - - `false`: None of the text has the **Superscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. - * + * Division Sign * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - superscript: boolean | null; + mathDivide = "MathDivide", /** - * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * + * Equals * @remarks * [Api set: PowerPointApi 1.4] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; + mathEqual = "MathEqual", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. + * Not Equal + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(options?: PowerPoint.Interfaces.ShapeFontLoadOptions): PowerPoint.ShapeFont; + mathNotEqual = "MathNotEqual", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * Four Right Triangles that Define a Rectangular Shape + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.ShapeFont; + cornerTabs = "CornerTabs", /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * Four Small Squares that Define a Rectangular Shape. + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.ShapeFont; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ShapeFont` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeFontData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.ShapeFontData; - } - /** - * Represents the font attributes, such as font name, size, and color. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface FontProperties { + squareTabs = "SquareTabs", /** - * Represents whether the font uses all caps, where lowercase letters are shown as capital letters. - * + * Four Quarter Circles that Define a Rectangular Shape. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - allCaps?: boolean | undefined; + plaqueTabs = "PlaqueTabs", /** - * Represents the bold status of font. - * + * A Rectangle Divided into Four Parts Along Diagonal Lines. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - bold?: boolean | undefined; + chartX = "ChartX", /** - * Represents the HTML color in the hexadecimal format (e.g., "#FF0000" represents red) or as a named HTML color value (e.g., "red"). - * + * A Rectangle Divided into Six Parts Along a Vertical Line and Diagonal Lines. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - color?: string | undefined; + chartStar = "ChartStar", /** - * Represents the double-strikethrough status of the font. - * + * A Rectangle Divided Vertically and Horizontally into Four Quarters. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - doubleStrikethrough?: boolean | undefined; + chartPlus = "ChartPlus", + } + /** + * Represents the available options when adding shapes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + interface ShapeAddOptions { /** - * Represents the italic status of font. + * Specifies the height, in points, of the shape. + When not provided, a default value will be used. + Throws an `InvalidArgument` exception when set with a negative value. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - italic?: boolean | undefined; + height?: number; /** - * Represents the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. + * Specifies the distance, in points, from the left side of the shape to the left side of the slide. + When not provided, a default value will be used. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - name?: string | undefined; + left?: number; /** - * Represents the font size in points (e.g., 11). + * Specifies the distance, in points, from the top edge of the shape to the top edge of the slide. + When not provided, a default value will be used. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - size?: number | undefined; + top?: number; /** - * Represents whether the text uses small caps, where lowercase letters are shown as small capital letters. + * Specifies the width, in points, of the shape. + When not provided, a default value will be used. + Throws an `InvalidArgument` exception when set with a negative value. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - smallCaps?: boolean | undefined; + width?: number; + } + /** + * Specifies the dash style for a line. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeLineDashStyle { /** - * Represents the strikethrough status of the font. - * + * The dash line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - strikethrough?: boolean | undefined; + dash = "Dash", /** - * Represents the subscript status of the font. - * + * The dash-dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subscript?: boolean | undefined; + dashDot = "DashDot", /** - * Represents the superscript status of the font. - * + * The dash-dot-dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - superscript?: boolean | undefined; + dashDotDot = "DashDotDot", /** - * Type of underline applied to the font. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * + * The long dash line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | undefined; - } - /** - * Represents a sequence of one or more characters with the same font attributes. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TextRun { + longDash = "LongDash", /** - * The font attributes (such as font name, font size, and color) applied to this text run. - * + * The long dash-dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - font?: PowerPoint.FontProperties; + longDashDot = "LongDashDot", /** - * The text of this text run. - * + * The round dot line pattern. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - text: string; - } - /** - * Represents the vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. - If one of the centered options is selected, the contents of the `TextFrame` will be centered horizontally within the `Shape` as a group. - To change the horizontal alignment of a text, see {@link PowerPoint.ParagraphFormat} and {@link PowerPoint.ParagraphHorizontalAlignment}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - enum TextVerticalAlignment { + roundDot = "RoundDot", /** - * Specifies that the `TextFrame` should be top aligned to the `Shape`. + * The solid line pattern. * @remarks * [Api set: PowerPointApi 1.4] */ - top = "Top", + solid = "Solid", /** - * Specifies that the `TextFrame` should be center aligned to the `Shape`. + * The square dot line pattern. * @remarks * [Api set: PowerPointApi 1.4] */ - middle = "Middle", + squareDot = "SquareDot", /** - * Specifies that the `TextFrame` should be bottom aligned to the `Shape`. + * The long dash-dot-dot line pattern. * @remarks * [Api set: PowerPointApi 1.4] */ - bottom = "Bottom", + longDashDotDot = "LongDashDotDot", /** - * Specifies that the `TextFrame` should be top aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. + * The system dash line pattern. * @remarks * [Api set: PowerPointApi 1.4] */ - topCentered = "TopCentered", + systemDash = "SystemDash", /** - * Specifies that the `TextFrame` should be center aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. + * The system dot line pattern. * @remarks * [Api set: PowerPointApi 1.4] */ - middleCentered = "MiddleCentered", + systemDot = "SystemDot", /** - * Specifies that the `TextFrame` should be bottom aligned vertically to the `Shape`. Contents of the `TextFrame` will be centered horizontally within the `Shape`. + * The system dash-dot line pattern. * @remarks * [Api set: PowerPointApi 1.4] */ - bottomCentered = "BottomCentered", + systemDashDot = "SystemDashDot", } /** - * Represents a table. + * Represents the properties for a table cell border. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - class TableCell extends OfficeExtension.ClientObject { + class Border extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Gets the collection of borders for the table cell. + * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). * * @remarks * [Api set: PowerPointApi 1.9] */ - readonly borders: PowerPoint.Borders; + color: string | undefined; /** - * Gets the fill color of the table cell. + * Represents the dash style of the line. * * @remarks * [Api set: PowerPointApi 1.9] */ - readonly fill: PowerPoint.ShapeFill; + dashStyle: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; /** - * Gets the font of the table cell. + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). * * @remarks * [Api set: PowerPointApi 1.9] */ - readonly font: PowerPoint.ShapeFont; + transparency: number | undefined; /** - * Gets the set of margins in the table cell. + * Represents the weight of the line, in points. * * @remarks * [Api set: PowerPointApi 1.9] */ - readonly margins: PowerPoint.Margins; - /** - * Gets the number of table columns this cell spans across. - Will be greater than or equal to 1. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - readonly columnCount: number; + weight: number | undefined; /** - * Gets the zero-based column index of the cell within the table. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.8] + * @param options Provides options for which properties of the object to load. */ - readonly columnIndex: number; + load(options?: PowerPoint.Interfaces.BorderLoadOptions): PowerPoint.Border; /** - * Specifies the horizontal alignment of the table cell. Returns `null` if the cell text contains different alignments. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.9] + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + load(propertyNames?: string | string[]): PowerPoint.Border; /** - * Specifies the indent level of the table cell. Returns `null` if the cell text contains different indent levels. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.9] + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - indentLevel: number | null; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Border; /** - * Gets the number of table rows this cell spans across. - Will be greater than or equal to 1. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - readonly rowCount: number; + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.Border` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BorderData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.BorderData; + } + /** + * Represents the borders for a table cell. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + class Borders extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Gets the zero-based row index of the cell within the table. + * Gets the bottom border. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - readonly rowIndex: number; + readonly bottom: PowerPoint.Border; /** - * Specifies the text content of the table cell. + * Gets the diagonal border (top-left to bottom-right). * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - text: string; + readonly diagonalDown: PowerPoint.Border; /** - * Specifies the contents of the table cell as an array of {@link PowerPoint.TextRun} objects. - Each `TextRun` object represents a sequence of one or more characters that share the same font attributes. + * Gets the diagonal border (bottom-left to top-right). * * @remarks * [Api set: PowerPointApi 1.9] */ - textRuns: PowerPoint.TextRun[]; + readonly diagonalUp: PowerPoint.Border; /** - * Specifies the vertical alignment of the text in the table cell. + * Gets the left border. * * @remarks * [Api set: PowerPointApi 1.9] */ - verticalAlignment: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + readonly left: PowerPoint.Border; /** - * Resizes the table cell to span across a specified number of rows and columns. - If rowCount or columnCount are greater than 1, the cell will become a merged area. If the cell - is already a merged area and rowCount and columnCount are set to 1, the cell will no longer be - a merged area. + * Gets the right border. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param rowCount The number of rows the cell will span across. Must be greater than 0. - * @param columnCount The number of columns the cell will span across. Must be greater than 0. */ - resize(rowCount: number, columnCount: number): void; + readonly right: PowerPoint.Border; /** - * Splits the cell into the specified number of rows and columns. + * Gets the top border. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param rowCount The number of rows to split into. Must be greater than 0. - * @param columnCount The number of columns to split into. Must be greater than 0. */ - split(rowCount: number, columnCount: number): void; + readonly top: PowerPoint.Border; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableCellLoadOptions): PowerPoint.TableCell; + load(options?: PowerPoint.Interfaces.BordersLoadOptions): PowerPoint.Borders; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableCell; + load(propertyNames?: string | string[]): PowerPoint.Borders; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -130593,109 +130472,188 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.TableCell; + }): PowerPoint.Borders; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableCell` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableCellData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.Borders` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BordersData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TableCellData; + toJSON(): PowerPoint.Interfaces.BordersData; } /** - * Represents a collection of table cells. + * Represents the margins of a table cell. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - class TableCellCollection extends OfficeExtension.ClientObject { + class Margins extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.TableCell[]; /** - * Gets the number of table cells in the collection. + * Specifies the bottom margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] - * @returns The number of table cells in the collection. + * [Api set: PowerPointApi 1.9] */ - getCount(): OfficeExtension.ClientResult; + bottom: number | undefined; /** - * Gets the table cell using its zero-based index in the collection. If the `TableCell` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * Specifies the left margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] + */ + left: number | undefined; + /** + * Specifies the right margin in points. * - * @param row Row index value of the table cell to be retrieved, as a zero-based index. - * @param column Column index value of the table cell to be retrieved, as a zero-based index. - * @returns The `TableCell` object. + * @remarks + * [Api set: PowerPointApi 1.9] */ - getItemAtOrNullObject(row: number, column: number): PowerPoint.TableCell; + right: number | undefined; + /** + * Specifies the top margin in points. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + top: number | undefined; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableCellCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableCellCollection; + load(options?: PowerPoint.Interfaces.MarginsLoadOptions): PowerPoint.Margins; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableCellCollection; + load(propertyNames?: string | string[]): PowerPoint.Margins; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableCellCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Margins; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableCellCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableCellCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Whereas the original `PowerPoint.Margins` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.MarginsData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TableCellCollectionData; + toJSON(): PowerPoint.Interfaces.MarginsData; } /** - * Represents a column in a table. + * Specifies a shape's fill type. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - class TableColumn extends OfficeExtension.ClientObject { + enum ShapeFillType { + /** + * Specifies that the shape should have no fill. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + noFill = "NoFill", + /** + * Specifies that the shape should have regular solid fill. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + solid = "Solid", + /** + * Specifies that the shape should have gradient fill. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + gradient = "Gradient", + /** + * Specifies that the shape should have pattern fill. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + pattern = "Pattern", + /** + * Specifies that the shape should have picture or texture fill. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + pictureAndTexture = "PictureAndTexture", + /** + * Specifies that the shape should have slide background fill. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + slideBackground = "SlideBackground", + } + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + class ShapeFill extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Returns the index number of the column within the column collection of the table. Zero-indexed. + * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - readonly columnIndex: number; + foregroundColor: string; /** - * Retrieves the width of the column in points. If the set column width is less than the minimum width, the column width will be increased to the minimum width. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - width: number; + transparency: number; /** - * Deletes the column. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - delete(): void; + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; + /** + * Clears the fill formatting of this shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + clear(): void; + /** + * Sets the fill formatting of the shape to an image. This changes the fill type to `PictureAndTexture`. + * + * @remarks + * [Api set: PowerPointApi 1.8] + * + * @param base64EncodedImage A string that is a Base64 encoding of the image data. + */ + setImage(base64EncodedImage: string): void; + /** + * Sets the fill formatting of the shape to a uniform color. This changes the fill type to `Solid`. + * + * @remarks + * [Api set: PowerPointApi 1.4] + * + * @param color A string that specifies the fill color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + */ + setSolidColor(color: string): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableColumnLoadOptions): PowerPoint.TableColumn; + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableColumn; + load(propertyNames?: string | string[]): PowerPoint.ShapeFill; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -130704,365 +130662,359 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.TableColumn; + }): PowerPoint.ShapeFill; /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableColumn` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableColumnData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.TableColumnData; + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.ShapeFill` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeFillData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.ShapeFillData; } /** - * Represents the fill formatting of a table cell. + * Represents the font attributes, such as font name, size, and color. * * @remarks * [Api set: PowerPointApi 1.8] */ - interface FillProperties { + interface FontProperties { /** - * Represents the shape fill color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). + * Represents whether the font uses all caps, where lowercase letters are shown as capital letters. * * @remarks * [Api set: PowerPointApi 1.8] */ - color?: string | undefined; + allCaps?: boolean | undefined; /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). + * Represents the bold status of font. * * @remarks * [Api set: PowerPointApi 1.8] */ - transparency?: number | undefined; - } - /** - * Represents the properties for a table cell border. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface BorderProperties { + bold?: boolean | undefined; /** - * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). + * Represents the HTML color in the hexadecimal format (e.g., "#FF0000" represents red) or as a named HTML color value (e.g., "red"). * * @remarks * [Api set: PowerPointApi 1.8] */ color?: string | undefined; /** - * Represents the dash style of the line. + * Represents the double-strikethrough status of the font. * * @remarks * [Api set: PowerPointApi 1.8] */ - dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; + doubleStrikethrough?: boolean | undefined; /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). + * Represents the italic status of font. * * @remarks * [Api set: PowerPointApi 1.8] */ - transparency?: number | undefined; + italic?: boolean | undefined; /** - * Represents the weight of the line, in points. + * Represents the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. * * @remarks * [Api set: PowerPointApi 1.8] */ - weight?: number | undefined; - } - /** - * Represents the borders of a table cell. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TableCellBorders { + name?: string | undefined; /** - * Represents the bottom border. + * Represents the font size in points (e.g., 11). * * @remarks * [Api set: PowerPointApi 1.8] */ - bottom?: PowerPoint.BorderProperties; + size?: number | undefined; /** - * Represents the diagonal border (top-left to bottom-right). + * Represents whether the text uses small caps, where lowercase letters are shown as small capital letters. * * @remarks * [Api set: PowerPointApi 1.8] */ - diagonalDown?: PowerPoint.BorderProperties; + smallCaps?: boolean | undefined; /** - * Represents the diagonal border (bottom-left to top-right). + * Represents the strikethrough status of the font. * * @remarks * [Api set: PowerPointApi 1.8] */ - diagonalUp?: PowerPoint.BorderProperties; + strikethrough?: boolean | undefined; /** - * Represents the left border. + * Represents the subscript status of the font. * * @remarks * [Api set: PowerPointApi 1.8] */ - left?: PowerPoint.BorderProperties; + subscript?: boolean | undefined; /** - * Represents the right border. + * Represents the superscript status of the font. * * @remarks * [Api set: PowerPointApi 1.8] */ - right?: PowerPoint.BorderProperties; + superscript?: boolean | undefined; /** - * Represents the top border. + * Type of underline applied to the font. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks * [Api set: PowerPointApi 1.8] */ - top?: PowerPoint.BorderProperties; + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | undefined; } /** - * Represents the margins of a table cell. + * Represents a sequence of one or more characters with the same font attributes. * * @remarks * [Api set: PowerPointApi 1.8] */ - interface TableCellMargins { + interface TextRun { /** - * Specifies the bottom margin in points. + * The font attributes (such as font name, font size, and color) applied to this text run. * * @remarks * [Api set: PowerPointApi 1.8] */ - bottom?: number | undefined; + font?: PowerPoint.FontProperties; /** - * Specifies the left margin in points. + * The text of this text run. * * @remarks * [Api set: PowerPointApi 1.8] */ - left?: number | undefined; + text: string; + } + /** + * Represents a table. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + class TableCell extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; /** - * Specifies the right margin in points. + * Gets the collection of borders for the table cell. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - right?: number | undefined; + readonly borders: PowerPoint.Borders; /** - * Specifies the top margin in points. + * Gets the fill color of the table cell. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - top?: number | undefined; - } - /** - * Represents the table cell properties to update. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - interface TableCellProperties { + readonly fill: PowerPoint.ShapeFill; /** - * Specifies the border formatting of the table cell. + * Gets the font of the table cell. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - borders?: PowerPoint.TableCellBorders; + readonly font: PowerPoint.ShapeFont; /** - * Specifies the fill formatting of the table cell. + * Gets the set of margins in the table cell. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - fill?: PowerPoint.FillProperties; + readonly margins: PowerPoint.Margins; /** - * Specifies the font formatting of the table cell. + * Gets the number of table columns this cell spans across. + Will be greater than or equal to 1. * * @remarks * [Api set: PowerPointApi 1.8] */ - font?: PowerPoint.FontProperties; + readonly columnCount: number; /** - * Represents the horizontal alignment of the table cell. + * Gets the zero-based column index of the cell within the table. * * @remarks * [Api set: PowerPointApi 1.8] */ - horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | undefined; + readonly columnIndex: number; /** - * Represents the indent level of the text in the table cell. + * Specifies the horizontal alignment of the text in the table cell. Returns `null` if the cell text contains different alignments. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - indentLevel?: number | undefined; + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; /** - * Specifies the margin settings in the table cell. + * Specifies the indent level of the text in the table cell. Returns `null` if the cell text contains different indent levels. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - margins?: PowerPoint.TableCellMargins; + indentLevel: number | null; /** - * Specifies the text content of the table cell. - - If a portion of the text requires different formatting, use the `textRuns` property instead. + * Gets the number of table rows this cell spans across. + Will be greater than or equal to 1. * * @remarks * [Api set: PowerPointApi 1.8] */ - text?: string; + readonly rowCount: number; /** - * Specifies the contents of the table cell as an array of {@link PowerPoint.TextRun} objects. - Each `TextRun` object represents a sequence of one or more characters that share the same font attributes. + * Gets the zero-based row index of the cell within the table. * * @remarks * [Api set: PowerPointApi 1.8] */ - textRuns?: PowerPoint.TextRun[]; + readonly rowIndex: number; /** - * Represents the vertical alignment of the table cell. + * Specifies the text content of the table cell. * * @remarks * [Api set: PowerPointApi 1.8] */ - verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered" | undefined; - } - /** - * Represents a collection of table columns. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - class TableColumnCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.TableColumn[]; + text: string; /** - * Adds one or more columns to the table. + * Specifies the contents of the table cell as an array of {@link PowerPoint.TextRun} objects. + Each `TextRun` object represents a sequence of one or more characters that share the same font attributes. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param index Optional. Specifies the zero-based index where the new columns are added. Existing columns starting at the index location are shifted right. If the index value is undefined, null, -1, or greater than the number of columns in the table, the new columns are added at the end of the table. - * @param count Optional. The number of columns to add. If the value is undefined or 0, only one column is added. */ - // eslint-disable-next-line @definitelytyped/redundant-undefined - add(index?: number | null | undefined, count?: number | undefined): void; + textRuns: PowerPoint.TextRun[]; /** - * Deletes the specified columns from the collection. + * Specifies the vertical alignment of the text in the table cell. * * @remarks * [Api set: PowerPointApi 1.9] - * - * @param columns An array of `TableColumn` objects representing the columns to be deleted. */ - deleteColumns(columns: PowerPoint.TableColumn[]): void; + verticalAlignment: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; /** - * Gets the number of columns in the collection. + * Resizes the table cell to span across a specified number of rows and columns. + If rowCount or columnCount are greater than 1, the cell will become a merged area. If the cell + is already a merged area and rowCount and columnCount are set to 1, the cell will no longer be + a merged area. * * @remarks * [Api set: PowerPointApi 1.9] - * @returns The number of columns in the collection. + * + * @param rowCount The number of rows the cell will span across. Must be greater than 0. + * @param columnCount The number of columns the cell will span across. Must be greater than 0. */ - getCount(): OfficeExtension.ClientResult; + resize(rowCount: number, columnCount: number): void; /** - * Gets the column using its zero-based index in the collection. + * Splits the cell into the specified number of rows and columns. * * @remarks * [Api set: PowerPointApi 1.9] * - * @param index Index value of the column to be retrieved, as a zero-based index. - * @returns The column object. + * @param rowCount The number of rows to split into. Must be greater than 0. + * @param columnCount The number of columns to split into. Must be greater than 0. */ - getItemAt(index: number): PowerPoint.TableColumn; + split(rowCount: number, columnCount: number): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableColumnCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableColumnCollection; + load(options?: PowerPoint.Interfaces.TableCellLoadOptions): PowerPoint.TableCell; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableColumnCollection; + load(propertyNames?: string | string[]): PowerPoint.TableCell; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableColumnCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TableCell; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableColumnCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableColumnCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Whereas the original `PowerPoint.TableCell` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableCellData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TableColumnCollectionData; + toJSON(): PowerPoint.Interfaces.TableCellData; } /** - * Represents the available options when clearing a table. + * Represents a collection of table cells. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - interface TableClearOptions { + class TableCellCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.TableCell[]; /** - * Specifies if both values and formatting of the table should be cleared. + * Gets the number of table cells in the collection. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] + * @returns The number of table cells in the collection. */ - all?: boolean; + getCount(): OfficeExtension.ClientResult; /** - * Specifies if the formatting of the table should be cleared. + * Gets the table cell using its zero-based index in the collection. If the `TableCell` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] + * + * @param row Row index value of the table cell to be retrieved, as a zero-based index. + * @param column Column index value of the table cell to be retrieved, as a zero-based index. + * @returns The `TableCell` object. */ - format?: boolean; + getItemAtOrNullObject(row: number, column: number): PowerPoint.TableCell; /** - * Specifies if the values of the table should be cleared. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.9] + * @param options Provides options for which properties of the object to load. */ - text?: boolean; + load(options?: PowerPoint.Interfaces.TableCellCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableCellCollection; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.TableCellCollection; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableCellCollection; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableCellCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableCellCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + */ + toJSON(): PowerPoint.Interfaces.TableCellCollectionData; } /** - * Represents a row in a table. + * Represents a column in a table. * * @remarks * [Api set: PowerPointApi 1.9] */ - class TableRow extends OfficeExtension.ClientObject { + class TableColumn extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Retrieves the current height of the row in points. - * - * @remarks - * [Api set: PowerPointApi 1.9] - */ - readonly currentHeight: number; - /** - * Specifies the height of the row in points. If the set row height is less than the minimum height, the row height will be increased to the minimum height. + * Returns the index number of the column within the column collection of the table. Zero-indexed. * * @remarks * [Api set: PowerPointApi 1.9] */ - height: number; + readonly columnIndex: number; /** - * Returns the index number of the row within the rows collection of the table. Zero-indexed. + * Retrieves the width of the column in points. If the set column width is less than the minimum width, the column width will be increased to the minimum width. * * @remarks * [Api set: PowerPointApi 1.9] */ - readonly rowIndex: number; + width: number; /** - * Deletes the row. + * Deletes the column. * * @remarks * [Api set: PowerPointApi 1.9] @@ -131073,13 +131025,13 @@ declare namespace PowerPoint { * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TableRowLoadOptions): PowerPoint.TableRow; + load(options?: PowerPoint.Interfaces.TableColumnLoadOptions): PowerPoint.TableColumn; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TableRow; + load(propertyNames?: string | string[]): PowerPoint.TableColumn; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -131088,10 +131040,176 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.TableRow; + }): PowerPoint.TableColumn; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TableRow` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableRowData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.TableColumn` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableColumnData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.TableColumnData; + } + /** + * Represents a collection of table columns. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + class TableColumnCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.TableColumn[]; + /** + * Adds one or more columns to the table. + * + * @remarks + * [Api set: PowerPointApi 1.9] + * + * @param index Optional. Specifies the zero-based index where the new columns are added. Existing columns starting at the index location are shifted right. If the index value is undefined, null, -1, or greater than the number of columns in the table, the new columns are added at the end of the table. + * @param count Optional. The number of columns to add. If the value is undefined or 0, only one column is added. + */ + // eslint-disable-next-line @definitelytyped/redundant-undefined + add(index?: number | null | undefined, count?: number | undefined): void; + /** + * Deletes the specified columns from the collection. + * + * @remarks + * [Api set: PowerPointApi 1.9] + * + * @param columns An array of `TableColumn` objects representing the columns to be deleted. + */ + deleteColumns(columns: PowerPoint.TableColumn[]): void; + /** + * Gets the number of columns in the collection. + * + * @remarks + * [Api set: PowerPointApi 1.9] + * @returns The number of columns in the collection. + */ + getCount(): OfficeExtension.ClientResult; + /** + * Gets the column using its zero-based index in the collection. + * + * @remarks + * [Api set: PowerPointApi 1.9] + * + * @param index Index value of the column to be retrieved, as a zero-based index. + * @returns The column object. + */ + getItemAt(index: number): PowerPoint.TableColumn; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.TableColumnCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.TableColumnCollection; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.TableColumnCollection; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.TableColumnCollection; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableColumnCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableColumnCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + */ + toJSON(): PowerPoint.Interfaces.TableColumnCollectionData; + } + /** + * Represents the available options when clearing a table. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + interface TableClearOptions { + /** + * Specifies if both values and formatting of the table should be cleared. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + all?: boolean; + /** + * Specifies if the formatting of the table should be cleared. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + format?: boolean; + /** + * Specifies if the values of the table should be cleared. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + text?: boolean; + } + /** + * Represents a row in a table. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + class TableRow extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Retrieves the current height of the row in points. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + readonly currentHeight: number; + /** + * Specifies the height of the row in points. If the set row height is less than the minimum height, the row height will be increased to the minimum height. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + height: number; + /** + * Returns the index number of the row within the rows collection of the table. Zero-indexed. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + readonly rowIndex: number; + /** + * Deletes the row. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + delete(): void; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.TableRowLoadOptions): PowerPoint.TableRow; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.TableRow; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TableRow; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableRow` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableRowData`) that contains shallow copies of any loaded child properties from the original object. */ toJSON(): PowerPoint.Interfaces.TableRowData; } @@ -131620,6 +131738,91 @@ declare namespace PowerPoint { */ darkStyle2Accent3 = "DarkStyle2Accent3", } + /** + * Represents the available table style settings. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + class TableStyleSettings extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + areColumnsBanded: boolean; + /** + * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + areRowsBanded: boolean; + /** + * Specifies if the first column contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isFirstColumnHighlighted: boolean; + /** + * Specifies if the first row contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isFirstRowHighlighted: boolean; + /** + * Specifies if the last column contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isLastColumnHighlighted: boolean; + /** + * Specifies if the last row contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isLastRowHighlighted: boolean; + /** + * Specifies the table style. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + style: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.TableStyleSettingsLoadOptions): PowerPoint.TableStyleSettings; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.TableStyleSettings; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.TableStyleSettings; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.TableStyleSettings` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TableStyleSettingsData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.TableStyleSettingsData; + } /** * Represents a table. * @@ -131643,6 +131846,13 @@ declare namespace PowerPoint { * [Api set: PowerPointApi 1.9] */ readonly rows: PowerPoint.TableRowCollection; + /** + * Gets the table style settings. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + readonly styleSettings: PowerPoint.TableStyleSettings; /** * Gets the number of columns in the table. * @@ -131739,29 +131949,247 @@ declare namespace PowerPoint { toJSON(): PowerPoint.Interfaces.TableData; } /** - * Provides the table column properties. + * Represents the fill formatting of a table cell. * * @remarks * [Api set: PowerPointApi 1.8] */ - interface TableColumnProperties { + interface FillProperties { /** - * Represents the desired width of each column in points, or is undefined. - - When a table is being added, for columns whose width is undefined, - the column width will be calculated by evenly dividing the remaining width - of the table amongst those columns. If the table doesn't have a defined width, - a default column width will be used. + * Represents the shape fill color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). * * @remarks * [Api set: PowerPointApi 1.8] */ - columnWidth?: number | undefined; - } - /** - * Represents the properties of a merged area of cells in a table. - * - * @remarks + color?: string | undefined; + /** + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + transparency?: number | undefined; + } + /** + * Represents the properties for a table cell border. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface BorderProperties { + /** + * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + color?: string | undefined; + /** + * Represents the dash style of the line. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; + /** + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + transparency?: number | undefined; + /** + * Represents the weight of the line, in points. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + weight?: number | undefined; + } + /** + * Represents the borders of a table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface TableCellBorders { + /** + * Represents the bottom border. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + bottom?: PowerPoint.BorderProperties; + /** + * Represents the diagonal border (top-left to bottom-right). + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + diagonalDown?: PowerPoint.BorderProperties; + /** + * Represents the diagonal border (bottom-left to top-right). + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + diagonalUp?: PowerPoint.BorderProperties; + /** + * Represents the left border. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + left?: PowerPoint.BorderProperties; + /** + * Represents the right border. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + right?: PowerPoint.BorderProperties; + /** + * Represents the top border. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + top?: PowerPoint.BorderProperties; + } + /** + * Represents the margins of a table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface TableCellMargins { + /** + * Specifies the bottom margin in points. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + bottom?: number | undefined; + /** + * Specifies the left margin in points. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + left?: number | undefined; + /** + * Specifies the right margin in points. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + right?: number | undefined; + /** + * Specifies the top margin in points. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + top?: number | undefined; + } + /** + * Represents the table cell properties to update. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface TableCellProperties { + /** + * Specifies the border formatting of the table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + borders?: PowerPoint.TableCellBorders; + /** + * Specifies the fill formatting of the table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + fill?: PowerPoint.FillProperties; + /** + * Specifies the font formatting of the table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + font?: PowerPoint.FontProperties; + /** + * Specifies the horizontal alignment of the text in the table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | undefined; + /** + * Specifies the indent level of the text in the table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + indentLevel?: number | undefined; + /** + * Specifies the margin settings in the table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + margins?: PowerPoint.TableCellMargins; + /** + * Specifies the text content of the table cell. + + If a portion of the text requires different formatting, use the `textRuns` property instead. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + text?: string; + /** + * Specifies the contents of the table cell as an array of {@link TextRun} objects. + Each `TextRun` object represents a sequence of one or more characters that share the same font attributes. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + textRuns?: PowerPoint.TextRun[]; + /** + * Specifies the vertical alignment of the text in the table cell. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered" | undefined; + } + /** + * Provides the table column properties. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + interface TableColumnProperties { + /** + * Represents the desired width of each column in points, or is undefined. + + When a table is being added, for columns whose width is undefined, + the column width will be calculated by evenly dividing the remaining width + of the table amongst those columns. If the table doesn't have a defined width, + a default column width will be used. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + columnWidth?: number | undefined; + } + /** + * Represents the properties of a merged area of cells in a table. + * + * @remarks * [Api set: PowerPointApi 1.8] */ interface TableMergedAreaProperties { @@ -131836,6 +132264,9 @@ declare namespace PowerPoint { * Specifies the height, in points, of the table. A default value is used when this parameter isn't provided. Throws an `InvalidArgument` exception when set with a negative value. + + Note: If the table height isn't evenly divisible by the number of rows, PowerPoint sets it to the nearest possible value. + For example, a height of 400 for 3 rows may result in an actual height of 399.9999. * * @remarks * [Api set: PowerPointApi 1.8] @@ -131924,6 +132355,9 @@ declare namespace PowerPoint { * Specifies the width, in points, of the table. A default value is used when this parameter isn't provided. Throws an `InvalidArgument` exception when set with a negative value. + + Note: If the table width isn't evenly divisible by the number of columns, PowerPoint sets it to the nearest possible value. + For example, a width of 400 for 3 columns may result in an actual width of 399.9999. * * @remarks * [Api set: PowerPointApi 1.8] @@ -133101,212 +133535,261 @@ declare namespace PowerPoint { toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } /** - * Determines the type of automatic sizing allowed. + * Use with `setZOrder` to move the specified shape up or down the collection's z-order, which shifts it in front of or behind other shapes. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - enum ShapeAutoSize { + enum ShapeZOrder { /** - * No autosizing. + * Brings the shape forward one spot in the z-order. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeNone = "AutoSizeNone", + bringForward = "BringForward", /** - * The text is adjusted to fit the shape. + * Brings the shape to the front of the z-order. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeTextToFitShape = "AutoSizeTextToFitShape", + bringToFront = "BringToFront", /** - * The shape is adjusted to fit the text. + * Sends the shape backward one spot in the z-order. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeShapeToFitText = "AutoSizeShapeToFitText", + sendBackward = "SendBackward", /** - * A combination of automatic sizing schemes are used. + * Sends the shape to the back of the z-order. * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeMixed = "AutoSizeMixed", + sendToBack = "SendToBack", } /** - * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. + * Represents a single shape in the slide. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.3] */ - class BulletFormat extends OfficeExtension.ClientObject { + class Shape extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. + * Returns a collection of custom XML parts in the shape. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + readonly customXmlParts: PowerPoint.CustomXmlPartCollection; + /** + * Returns the fill formatting of this shape. * * @remarks * [Api set: PowerPointApi 1.4] */ - visible: boolean | null; + readonly fill: PowerPoint.ShapeFill; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Returns the `ShapeGroup` associated with the shape. + If the shape type isn't `group`, then this method returns the `GeneralException` error. * - * @param options Provides options for which properties of the object to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(options?: PowerPoint.Interfaces.BulletFormatLoadOptions): PowerPoint.BulletFormat; + readonly group: PowerPoint.ShapeGroup; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Returns the line formatting of this shape. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.BulletFormat; + readonly lineFormat: PowerPoint.ShapeLineFormat; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Returns the parent group of this shape. + If the shape isn't part of a group, then this method returns the `GeneralException` error. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.BulletFormat; + readonly parentGroup: PowerPoint.Shape; /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.BulletFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BulletFormatData`) that contains shallow copies of any loaded child properties from the original object. + * Returns the properties that apply specifically to this placeholder. + If the shape type isn't `placeholder`, then this method returns the `GeneralException` error. + * + * @remarks + * [Api set: PowerPointApi 1.8] */ - toJSON(): PowerPoint.Interfaces.BulletFormatData; - } - /** - * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - class ParagraphFormat extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + readonly placeholderFormat: PowerPoint.PlaceholderFormat; /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. + * Returns a collection of tags in the shape. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + readonly tags: PowerPoint.TagCollection; + /** + * Returns the {@link PowerPoint.TextFrame} object of this `Shape`. Throws an `InvalidArgument` exception if the shape doesn't support a `TextFrame`. * * @remarks * [Api set: PowerPointApi 1.4] */ - readonly bulletFormat: PowerPoint.BulletFormat; + readonly textFrame: PowerPoint.TextFrame; /** - * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. + * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. * * @remarks * [Api set: PowerPointApi 1.4] */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + height: number; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Gets the unique ID of the shape. * - * @param options Provides options for which properties of the object to load. + * @remarks + * [Api set: PowerPointApi 1.3] */ - load(options?: PowerPoint.Interfaces.ParagraphFormatLoadOptions): PowerPoint.ParagraphFormat; + readonly id: string; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * The distance, in points, from the left side of the shape to the left side of the slide. * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * @remarks + * [Api set: PowerPointApi 1.4] */ - load(propertyNames?: string | string[]): PowerPoint.ParagraphFormat; + left: number; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Returns the level of the specified shape. + + - A level of 0 means the shape isn't part of a group. + + - A level of 1 means the shape is part of a top-level group. + + - A level greater than 1 indicates the shape is a nested group. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * @remarks + * [Api set: PowerPointApi 1.8] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.ParagraphFormat; + readonly level: number; /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.ParagraphFormat` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ParagraphFormatData`) that contains shallow copies of any loaded child properties from the original object. + * Specifies the name of this shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] */ - toJSON(): PowerPoint.Interfaces.ParagraphFormatData; - } - /** - * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - class TextRange extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + name: string; /** - * Returns a `ShapeFont` object that represents the font attributes for the text range. + * The distance, in points, from the top edge of the shape to the top edge of the slide. * * @remarks * [Api set: PowerPointApi 1.4] */ - readonly font: PowerPoint.ShapeFont; + top: number; /** - * Represents the paragraph format of the text range. See {@link PowerPoint.ParagraphFormat} for details. + * Returns the type of this shape. See {@link PowerPoint.ShapeType} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - readonly paragraphFormat: PowerPoint.ParagraphFormat; + readonly type: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox"; /** - * Gets or sets the length of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. + * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.4] */ - length: number; + width: number; /** - * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * Returns the z-order position of the shape, with 0 representing the bottom of the order stack. Every shape on a slide has a unique z-order, but + each slide also has a unique z-order stack, so two shapes on separate slides could have the same z-order number. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + readonly zOrderPosition: number; + /** + * Deletes the shape from the shape collection. Does nothing if the shape doesn't exist. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + delete(): void; + /** + * Returns the parent {@link PowerPoint.Slide} object that holds this `Shape`. Throws an exception if this shape doesn't belong to a `Slide`. * * @remarks * [Api set: PowerPointApi 1.5] */ - start: number; + getParentSlide(): PowerPoint.Slide; /** - * Represents the plain text content of the text range. + * Returns the parent {@link PowerPoint.SlideLayout} object that holds this `Shape`. Throws an exception if this shape doesn't belong to a `SlideLayout`. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - text: string; + getParentSlideLayout(): PowerPoint.SlideLayout; /** - * Returns the parent {@link PowerPoint.TextFrame} object that holds this `TextRange`. + * Returns the parent {@link PowerPoint.SlideLayout} object that holds this `Shape`. If this shape doesn't belong to a `SlideLayout`, an object with an `isNullObject` property set to `true` is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks * [Api set: PowerPointApi 1.5] */ - getParentTextFrame(): PowerPoint.TextFrame; + getParentSlideLayoutOrNullObject(): PowerPoint.SlideLayout; /** - * Returns a `TextRange` object for the substring in the given range. + * Returns the parent {@link PowerPoint.SlideMaster} object that holds this `Shape`. Throws an exception if this shape doesn't belong to a `SlideMaster`. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] + */ + getParentSlideMaster(): PowerPoint.SlideMaster; + /** + * Returns the parent {@link PowerPoint.SlideMaster} object that holds this `Shape`. If this shape doesn't belong to a `SlideMaster`, an object with an `isNullObject` property set to `true` is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * - * @param start The zero-based index of the first character to get from the text range. - * @param length Optional. The number of characters to be returned in the new text range. If length is omitted, all the characters from start to the end of the text range's last paragraph will be returned. + * @remarks + * [Api set: PowerPointApi 1.5] */ - getSubstring(start: number, length?: number): PowerPoint.TextRange; + getParentSlideMasterOrNullObject(): PowerPoint.SlideMaster; /** - * Selects this `TextRange` in the current view. + * Returns the parent {@link PowerPoint.Slide} object that holds this `Shape`. If this shape doesn't belong to a `Slide`, an object with an `isNullObject` property set to `true` is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks * [Api set: PowerPointApi 1.5] */ - setSelected(): void; + getParentSlideOrNullObject(): PowerPoint.Slide; + /** + * Returns the `Table` object if this shape is a table. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + getTable(): PowerPoint.Table; + /** + * Moves the specified shape up or down the collection's z-order, which shifts it in front of or behind other shapes. + * + * @remarks + * [Api set: PowerPointApi 1.8] + * + * @param position Specifies how to move the shape within the z-order stack. Uses the `ShapeZOrder` enum. + */ + setZOrder(position: PowerPoint.ShapeZOrder): void; + /** + * Moves the specified shape up or down the collection's z-order, which shifts it in front of or behind other shapes. + * + * @remarks + * [Api set: PowerPointApi 1.8] + * + * @param position Specifies how to move the shape within the z-order stack. Uses the `ShapeZOrder` enum. + */ + setZOrder(position: "BringForward" | "BringToFront" | "SendBackward" | "SendToBack"): void; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TextRangeLoadOptions): PowerPoint.TextRange; + load(options?: PowerPoint.Interfaces.ShapeLoadOptions): PowerPoint.Shape; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TextRange; + load(propertyNames?: string | string[]): PowerPoint.Shape; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -133315,382 +133798,477 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.TextRange; + }): PowerPoint.Shape; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TextRange` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TextRangeData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.Shape` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.TextRangeData; + toJSON(): PowerPoint.Interfaces.ShapeData; } /** - * Represents the text frame of a shape object. + * Represents an Office.js binding that is defined in the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - class TextFrame extends OfficeExtension.ClientObject { + class Binding extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Represents the text that is attached to a shape in the text frame, and properties and methods for manipulating the text. See {@link PowerPoint.TextRange} for details. + * Represents the binding identifier. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - readonly textRange: PowerPoint.TextRange; + readonly id: string; /** - * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. + * Returns the type of the binding. See `BindingType` for details. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - autoSizeSetting: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; + readonly type: PowerPoint.BindingType | "Shape"; /** - * Represents the bottom margin, in points, of the text frame. + * Deletes the binding. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - bottomMargin: number; + delete(): void; /** - * Specifies if the text frame contains text. + * Returns the shape represented by the binding. Will throw an error if the binding isn't of the correct type. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - readonly hasText: boolean; + getShape(): PowerPoint.Shape; /** - * Represents the left margin, in points, of the text frame. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param options Provides options for which properties of the object to load. + */ + load(options?: PowerPoint.Interfaces.BindingLoadOptions): PowerPoint.Binding; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + */ + load(propertyNames?: string | string[]): PowerPoint.Binding; + /** + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + */ + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.Binding; + /** + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.Binding` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BindingData`) that contains shallow copies of any loaded child properties from the original object. + */ + toJSON(): PowerPoint.Interfaces.BindingData; + } + /** + * Represents the collection of all the binding objects that are part of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + class BindingCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.Binding[]; + /** + * Adds a new binding to a particular Shape. If the provided ID is already being used by a binding, the existing binding will be overwritten. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] + * + * @param shape Shape to which the binding is added. + * @param bindingType Type of binding. See `BindingType`. + * @param id ID of the binding. */ - leftMargin: number; + add(shape: PowerPoint.Shape, bindingType: PowerPoint.BindingType, id: string): PowerPoint.Binding; /** - * Represents the right margin, in points, of the text frame. + * Adds a new binding to a particular Shape. If the provided ID is already being used by a binding, the existing binding will be overwritten. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] + * + * @param shape Shape to which the binding is added. + * @param bindingType Type of binding. See `BindingType`. + * @param id ID of the binding. */ - rightMargin: number; + add(shape: PowerPoint.Shape, bindingType: "Shape", id: string): PowerPoint.Binding; /** - * Represents the top margin, in points, of the text frame. + * Adds a new binding based on the current selection. + If the selection has multiple areas, the `InvalidReference` error will be returned. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] + * + * @param bindingType Type of binding. See `BindingType`. + * @param id ID of the binding. */ - topMargin: number; + addFromSelection(bindingType: PowerPoint.BindingType, id: string): PowerPoint.Binding; /** - * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. + * Adds a new binding based on the current selection. + If the selection has multiple areas, the `InvalidReference` error will be returned. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] + * + * @param bindingType Type of binding. See `BindingType`. + * @param id ID of the binding. */ - verticalAlignment: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + addFromSelection(bindingType: "Shape", id: string): PowerPoint.Binding; /** - * Determines whether lines break automatically to fit text inside the shape. + * Gets the number of bindings in the collection. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - wordWrap: boolean; + getCount(): OfficeExtension.ClientResult; /** - * Deletes all the text in the text frame. + * Gets a binding object by ID. Throws an ItemNotFoundException if there's no binding with that ID. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] + * + * @param key ID of the binding object to be retrieved. */ - deleteText(): void; + getItem(key: string): PowerPoint.Binding; /** - * Returns the parent {@link PowerPoint.Shape} object that holds this `TextFrame`. + * Gets a binding object based on its position in the items array. Throws an InvalidArgumentException if the index less than 0, or greater than or equal to the count of items in the collection. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.8] + * + * @param index Index value of the object to be retrieved. Zero-indexed. */ - getParentShape(): PowerPoint.Shape; + getItemAt(index: number): PowerPoint.Binding; + /** + * Gets a binding object by ID. If the binding object doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. + For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * + * @remarks + * [Api set: PowerPointApi 1.8] + * + * @param id ID of the binding object to be retrieved. + */ + getItemOrNullObject(id: string): PowerPoint.Binding; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.TextFrameLoadOptions): PowerPoint.TextFrame; + load(options?: PowerPoint.Interfaces.BindingCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.BindingCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.TextFrame; + load(propertyNames?: string | string[]): PowerPoint.BindingCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.TextFrame; + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.BindingCollection; /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.TextFrame` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.TextFrameData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.TextFrameData; + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.BindingCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BindingCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + */ + toJSON(): PowerPoint.Interfaces.BindingCollectionData; } /** - * Use with `setZOrder` to move the specified shape up or down the collection's z-order, which shifts it in front of or behind other shapes. + * Specifies the document property type for custom properties. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - enum ShapeZOrder { + enum DocumentPropertyType { /** - * Brings the shape forward one spot in the z-order. + * The Boolean document property type. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - bringForward = "BringForward", + boolean = "Boolean", /** - * Brings the shape to the front of the z-order. + * The Date document property type. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - bringToFront = "BringToFront", + date = "Date", /** - * Sends the shape backward one spot in the z-order. + * The Number document property type. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - sendBackward = "SendBackward", + number = "Number", /** - * Sends the shape to the back of the z-order. + * The String document property type. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - sendToBack = "SendToBack", + string = "String", } /** - * Represents a single shape in the slide. + * Represents a custom property. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.7] */ - class Shape extends OfficeExtension.ClientObject { + class CustomProperty extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** - * Returns a collection of custom XML parts in the shape. + * The string that uniquely identifies the custom property. * * @remarks * [Api set: PowerPointApi 1.7] */ - readonly customXmlParts: PowerPoint.CustomXmlPartCollection; + readonly key: string; /** - * Returns the fill formatting of this shape. + * The type of the value used for the custom property. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - readonly fill: PowerPoint.ShapeFill; + readonly type: PowerPoint.DocumentPropertyType | "Boolean" | "Date" | "Number" | "String"; /** - * Returns the `ShapeGroup` associated with the shape. - If the shape type isn't `group`, then this method returns the `GeneralException` error. + * The value of the custom property. + If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - readonly group: PowerPoint.ShapeGroup; + value: boolean | Date | number | string; /** - * Returns the line formatting of this shape. + * Deletes the custom property. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - readonly lineFormat: PowerPoint.ShapeLineFormat; + delete(): void; /** - * Returns the parent group of this shape. - If the shape isn't part of a group, then this method returns the `GeneralException` error. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.8] + * @param options Provides options for which properties of the object to load. */ - readonly parentGroup: PowerPoint.Shape; + load(options?: PowerPoint.Interfaces.CustomPropertyLoadOptions): PowerPoint.CustomProperty; /** - * Returns the properties that apply specifically to this placeholder. - If the shape type isn't `placeholder`, then this method returns the `GeneralException` error. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.8] + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - readonly placeholderFormat: PowerPoint.PlaceholderFormat; + load(propertyNames?: string | string[]): PowerPoint.CustomProperty; /** - * Returns a collection of tags in the shape. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.3] + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - readonly tags: PowerPoint.TagCollection; + load(propertyNamesAndPaths?: { + select?: string; + expand?: string; + }): PowerPoint.CustomProperty; /** - * Returns the {@link PowerPoint.TextFrame} object of this `Shape`. Throws an `InvalidArgument` exception if the shape doesn't support a `TextFrame`. - * - * @remarks - * [Api set: PowerPointApi 1.4] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.CustomProperty` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.CustomPropertyData`) that contains shallow copies of any loaded child properties from the original object. */ - readonly textFrame: PowerPoint.TextFrame; + toJSON(): PowerPoint.Interfaces.CustomPropertyData; + } + /** + * A collection of custom properties. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + class CustomPropertyCollection extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.CustomProperty[]; /** - * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * Creates a new `CustomProperty` or updates the property with the given key. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] + * + * @param key The string that identifies the `CustomProperty` object. It's case-insensitive. + * The maximum key length is 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * @param value The value of the `CustomProperty`. + * If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. */ - height: number; + add(key: string, value: boolean | Date | number | string): PowerPoint.CustomProperty; /** - * Gets the unique ID of the shape. + * Deletes all custom properties in this collection. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.7] */ - readonly id: string; + deleteAll(): void; /** - * The distance, in points, from the left side of the shape to the left side of the slide. + * Gets the number of custom properties in the collection. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] + * @returns The number of custom properties in the collection. */ - left: number; + getCount(): OfficeExtension.ClientResult; /** - * Returns the level of the specified shape. - - - A level of 0 means the shape isn't part of a group. - - - A level of 1 means the shape is part of a top-level group. - - - A level greater than 1 indicates the shape is a nested group. + * Gets a `CustomProperty` by its key. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] + * + * @param key The string that identifies the `CustomProperty` object. It's case-insensitive. + * Keys have a maximum length of 255 characters. If the argument exceeds 255 characters, then this method returns the `InvalidArgument` error. */ - readonly level: number; + getItem(key: string): PowerPoint.CustomProperty; /** - * Specifies the name of this shape. + * Gets a `CustomProperty` by its key. + If the `CustomProperty` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. + For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] + * + * @param key The string that identifies the `CustomProperty` object. It's case-insensitive. + * Keys have a maximum length of 255 characters. If the argument exceeds 255 characters, then this method returns the `InvalidArgument` error. */ - name: string; + getItemOrNullObject(key: string): PowerPoint.CustomProperty; /** - * The distance, in points, from the top edge of the shape to the top edge of the slide. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.4] + * @param options Provides options for which properties of the object to load. */ - top: number; + load(options?: PowerPoint.Interfaces.CustomPropertyCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.CustomPropertyCollection; /** - * Returns the type of this shape. See {@link PowerPoint.ShapeType} for details. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.4] + * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - readonly type: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox"; + load(propertyNames?: string | string[]): PowerPoint.CustomPropertyCollection; /** - * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * - * @remarks - * [Api set: PowerPointApi 1.4] + * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - width: number; + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.CustomPropertyCollection; /** - * Returns the z-order position of the shape, with 0 representing the bottom of the order stack. Every shape on a slide has a unique z-order, but - each slide also has a unique z-order stack, so two shapes on separate slides could have the same z-order number. + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.CustomPropertyCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.CustomPropertyCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + */ + toJSON(): PowerPoint.Interfaces.CustomPropertyCollectionData; + } + /** + * Represents presentation properties. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + class DocumentProperties extends OfficeExtension.ClientObject { + /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ + context: RequestContext; + /** + * The collection of custom properties of the presentation. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - readonly zOrderPosition: number; + readonly customProperties: PowerPoint.CustomPropertyCollection; /** - * Deletes the shape from the shape collection. Does nothing if the shape doesn't exist. + * The author of the presentation. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.7] */ - delete(): void; + author: string; /** - * Returns the parent {@link PowerPoint.Slide} object that holds this `Shape`. Throws an exception if this shape doesn't belong to a `Slide`. + * The category of the presentation. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - getParentSlide(): PowerPoint.Slide; + category: string; /** - * Returns the parent {@link PowerPoint.SlideLayout} object that holds this `Shape`. Throws an exception if this shape doesn't belong to a `SlideLayout`. + * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - getParentSlideLayout(): PowerPoint.SlideLayout; + comments: string; /** - * Returns the parent {@link PowerPoint.SlideLayout} object that holds this `Shape`. If this shape doesn't belong to a `SlideLayout`, an object with an `isNullObject` property set to `true` is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * The company of the presentation. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - getParentSlideLayoutOrNullObject(): PowerPoint.SlideLayout; + company: string; /** - * Returns the parent {@link PowerPoint.SlideMaster} object that holds this `Shape`. Throws an exception if this shape doesn't belong to a `SlideMaster`. + * The creation date of the presentation. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - getParentSlideMaster(): PowerPoint.SlideMaster; + readonly creationDate: Date; /** - * Returns the parent {@link PowerPoint.SlideMaster} object that holds this `Shape`. If this shape doesn't belong to a `SlideMaster`, an object with an `isNullObject` property set to `true` is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * The keywords of the presentation. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - getParentSlideMasterOrNullObject(): PowerPoint.SlideMaster; + keywords: string; /** - * Returns the parent {@link PowerPoint.Slide} object that holds this `Shape`. If this shape doesn't belong to a `Slide`, an object with an `isNullObject` property set to `true` is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * The last author of the presentation. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - getParentSlideOrNullObject(): PowerPoint.Slide; + readonly lastAuthor: string; /** - * Returns the `Table` object if this shape is a table. + * The manager of the presentation. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - getTable(): PowerPoint.Table; + manager: string; /** - * Moves the specified shape up or down the collection's z-order, which shifts it in front of or behind other shapes. + * The revision number of the presentation. * * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param position Specifies how to move the shape within the z-order stack. Uses the `ShapeZOrder` enum. + * [Api set: PowerPointApi 1.7] */ - setZOrder(position: PowerPoint.ShapeZOrder): void; + revisionNumber: number; /** - * Moves the specified shape up or down the collection's z-order, which shifts it in front of or behind other shapes. + * The subject of the presentation. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] + */ + subject: string; + /** + * The title of the presentation. * - * @param position Specifies how to move the shape within the z-order stack. Uses the `ShapeZOrder` enum. + * @remarks + * [Api set: PowerPointApi 1.7] */ - setZOrder(position: "BringForward" | "BringToFront" | "SendBackward" | "SendToBack"): void; + title: string; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.ShapeLoadOptions): PowerPoint.Shape; + load(options?: PowerPoint.Interfaces.DocumentPropertiesLoadOptions): PowerPoint.DocumentProperties; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.Shape; + load(propertyNames?: string | string[]): PowerPoint.DocumentProperties; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * @@ -133699,1050 +134277,669 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.Shape; + }): PowerPoint.DocumentProperties; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Shape` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.ShapeData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.DocumentProperties` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.DocumentPropertiesData`) that contains shallow copies of any loaded child properties from the original object. */ - toJSON(): PowerPoint.Interfaces.ShapeData; + toJSON(): PowerPoint.Interfaces.DocumentPropertiesData; } /** - * Represents an Office.js binding that is defined in the presentation. + * Specifies the formatting options for when slides are inserted. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.2] */ - class Binding extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; + enum InsertSlideFormatting { /** - * Represents the binding identifier. - * + * Copy the source theme into the target presentation and use that theme. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.2] */ - readonly id: string; + keepSourceFormatting = "KeepSourceFormatting", /** - * Returns the type of the binding. See `BindingType` for details. - * + * Use the existing theme in the target presentation. * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.2] */ - readonly type: PowerPoint.BindingType | "Shape"; + useDestinationTheme = "UseDestinationTheme", + } + /** + * Represents the available options when inserting slides. + * + * @remarks + * [Api set: PowerPointApi 1.2] + */ + interface InsertSlideOptions { /** - * Deletes the binding. + * Specifies which formatting to use during slide insertion. + The default option is to use "KeepSourceFormatting". * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.2] */ - delete(): void; + formatting?: PowerPoint.InsertSlideFormatting | "KeepSourceFormatting" | "UseDestinationTheme"; /** - * Returns the shape represented by the binding. Will throw an error if the binding isn't of the correct type. + * Specifies the slides from the source presentation that will be inserted into the current presentation. These slides are represented by their IDs which can be retrieved from a `Slide` object. + The order of these slides is preserved during the insertion. + If any of the source slides aren't found, or if the IDs are invalid, the operation throws a `SlideNotFound` exception and no slides will be inserted. + All of the source slides will be inserted when `sourceSlideIds` isn't provided (this is the default behavior). * * @remarks - * [Api set: PowerPointApi 1.8] - */ - getShape(): PowerPoint.Shape; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.BindingLoadOptions): PowerPoint.Binding; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. + * [Api set: PowerPointApi 1.2] */ - load(propertyNames?: string | string[]): PowerPoint.Binding; + sourceSlideIds?: string[]; /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. + * Specifies where in the presentation the new slides will be inserted. The new slides will be inserted after the slide with the given slide ID. + If `targetSlideId` isn't provided, the slides will be inserted at the beginning of the presentation. + If `targetSlideId` is invalid or if it's pointing to a non-existing slide, the operation throws a `SlideNotFound` exception and no slides will be inserted. * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. + * @remarks + * [Api set: PowerPointApi 1.2] */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.Binding; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.Binding` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BindingData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.BindingData; + targetSlideId?: string; } /** - * Represents the collection of all the binding objects that are part of the presentation. + * Represents the collection of slides in the presentation. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.2] */ - class BindingCollection extends OfficeExtension.ClientObject { + class SlideCollection extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.Binding[]; + readonly items: PowerPoint.Slide[]; /** - * Adds a new binding to a particular Shape. If the provided ID is already being used by a binding, the existing binding will be overwritten. + * Adds a new slide at the end of the collection. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.3] * - * @param shape Shape to which the binding is added. - * @param bindingType Type of binding. See `BindingType`. - * @param id ID of the binding. + * @param options The options that define the theme of the new slide. */ - add(shape: PowerPoint.Shape, bindingType: PowerPoint.BindingType, id: string): PowerPoint.Binding; + add(options?: PowerPoint.AddSlideOptions): void; /** - * Adds a new binding to a particular Shape. If the provided ID is already being used by a binding, the existing binding will be overwritten. + * Gets the number of slides in the collection. * * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param shape Shape to which the binding is added. - * @param bindingType Type of binding. See `BindingType`. - * @param id ID of the binding. + * [Api set: PowerPointApi 1.2] + * @returns The number of slides in the collection. */ - add(shape: PowerPoint.Shape, bindingType: "Shape", id: string): PowerPoint.Binding; + getCount(): OfficeExtension.ClientResult; /** - * Adds a new binding based on the current selection. - If the selection has multiple areas, the `InvalidReference` error will be returned. + * Gets a slide using its unique ID. * * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param bindingType Type of binding. See `BindingType`. - * @param id ID of the binding. - */ - addFromSelection(bindingType: PowerPoint.BindingType, id: string): PowerPoint.Binding; - /** - * Adds a new binding based on the current selection. - If the selection has multiple areas, the `InvalidReference` error will be returned. - * - * @remarks - * [Api set: PowerPointApi 1.8] - * - * @param bindingType Type of binding. See `BindingType`. - * @param id ID of the binding. - */ - addFromSelection(bindingType: "Shape", id: string): PowerPoint.Binding; - /** - * Gets the number of bindings in the collection. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - getCount(): OfficeExtension.ClientResult; - /** - * Gets a binding object by ID. Throws an ItemNotFoundException if there's no binding with that ID. - * - * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.2] * - * @param key ID of the binding object to be retrieved. + * @param key The ID of the slide. + * @returns The slide with the unique ID. If such a slide doesn't exist, an error is thrown. */ - getItem(key: string): PowerPoint.Binding; + getItem(key: string): PowerPoint.Slide; /** - * Gets a binding object based on its position in the items array. Throws an InvalidArgumentException if the index less than 0, or greater than or equal to the count of items in the collection. + * Gets a slide using its zero-based index in the collection. Slides are stored in the same order as they + are shown in the presentation. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.2] * - * @param index Index value of the object to be retrieved. Zero-indexed. + * @param index The index of the slide in the collection. + * @returns The slide at the given index. An error is thrown if index is out of range. */ - getItemAt(index: number): PowerPoint.Binding; + getItemAt(index: number): PowerPoint.Slide; /** - * Gets a binding object by ID. If the binding object doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. - For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. + * Gets a slide using its unique ID. If such a slide doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see + {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.2] * - * @param id ID of the binding object to be retrieved. + * @param id The ID of the slide. + * @returns The slide with the unique ID. */ - getItemOrNullObject(id: string): PowerPoint.Binding; + getItemOrNullObject(id: string): PowerPoint.Slide; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.BindingCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.BindingCollection; + load(options?: PowerPoint.Interfaces.SlideCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.SlideCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.BindingCollection; + load(propertyNames?: string | string[]): PowerPoint.SlideCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.BindingCollection; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.BindingCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.BindingCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. - */ - toJSON(): PowerPoint.Interfaces.BindingCollectionData; - } - /** - * Specifies the document property type for custom properties. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - enum DocumentPropertyType { - /** - * The Boolean document property type. - * @remarks - * [Api set: PowerPointApi 1.7] - */ - boolean = "Boolean", - /** - * The Date document property type. - * @remarks - * [Api set: PowerPointApi 1.7] - */ - date = "Date", - /** - * The Number document property type. - * @remarks - * [Api set: PowerPointApi 1.7] - */ - number = "Number", + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.SlideCollection; /** - * The String document property type. - * @remarks - * [Api set: PowerPointApi 1.7] + * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) + * Whereas the original `PowerPoint.SlideCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - string = "String", + toJSON(): PowerPoint.Interfaces.SlideCollectionData; } /** - * Represents a custom property. + * Represents a collection of slides in the presentation. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] */ - class CustomProperty extends OfficeExtension.ClientObject { + class SlideScopedCollection extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; + /** Gets the loaded child items in this collection. */ + readonly items: PowerPoint.Slide[]; /** - * The string that uniquely identifies the custom property. + * Gets the number of slides in the collection. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] + * @returns The number of slides in the collection. */ - readonly key: string; + getCount(): OfficeExtension.ClientResult; /** - * The type of the value used for the custom property. + * Gets a slide using its unique ID. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] + * + * @param key The ID of the slide. + * @returns The slide with the unique ID. If such a slide doesn't exist, an error is thrown. */ - readonly type: PowerPoint.DocumentPropertyType | "Boolean" | "Date" | "Number" | "String"; + getItem(key: string): PowerPoint.Slide; /** - * The value of the custom property. - If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * Gets a slide using its zero-based index in the collection. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] + * + * @param index The index of the slide in the collection. + * @returns The slide at the given index. An error is thrown if index is out of range. */ - value: boolean | Date | number | string; + getItemAt(index: number): PowerPoint.Slide; /** - * Deletes the custom property. + * Gets a slide using its unique ID. If such a slide doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see + {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] + * + * @param id The ID of the slide. + * @returns The slide with the unique ID. */ - delete(): void; + getItemOrNullObject(id: string): PowerPoint.Slide; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.CustomPropertyLoadOptions): PowerPoint.CustomProperty; + load(options?: PowerPoint.Interfaces.SlideScopedCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.SlideScopedCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.CustomProperty; + load(propertyNames?: string | string[]): PowerPoint.SlideScopedCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.CustomProperty; + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.SlideScopedCollection; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.CustomProperty` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.CustomPropertyData`) that contains shallow copies of any loaded child properties from the original object. + * Whereas the original `PowerPoint.SlideScopedCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideScopedCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - toJSON(): PowerPoint.Interfaces.CustomPropertyData; + toJSON(): PowerPoint.Interfaces.SlideScopedCollectionData; } /** - * A collection of custom properties. + * Represents the collection of Slide Masters in the presentation. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.3] */ - class CustomPropertyCollection extends OfficeExtension.ClientObject { + class SlideMasterCollection extends OfficeExtension.ClientObject { /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ context: RequestContext; /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.CustomProperty[]; + readonly items: PowerPoint.SlideMaster[]; /** - * Creates a new `CustomProperty` or updates the property with the given key. + * Gets the number of Slide Masters in the collection. * * @remarks - * [Api set: PowerPointApi 1.7] - * - * @param key The string that identifies the `CustomProperty` object. It's case-insensitive. - * The maximum key length is 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. - * @param value The value of the `CustomProperty`. - * If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * [Api set: PowerPointApi 1.3] + * @returns The number of Slide Masters in the collection. */ - add(key: string, value: boolean | Date | number | string): PowerPoint.CustomProperty; + getCount(): OfficeExtension.ClientResult; /** - * Deletes all custom properties in this collection. + * Gets a Slide Master using its unique ID. * * @remarks - * [Api set: PowerPointApi 1.7] - */ - deleteAll(): void; - /** - * Gets the number of custom properties in the collection. + * [Api set: PowerPointApi 1.3] * - * @remarks - * [Api set: PowerPointApi 1.7] - * @returns The number of custom properties in the collection. + * @param key The ID of the Slide Master. + * @returns The Slide Master with the unique ID. If such a Slide Master doesn't exist, an error is thrown. */ - getCount(): OfficeExtension.ClientResult; + getItem(key: string): PowerPoint.SlideMaster; /** - * Gets a `CustomProperty` by its key. + * Gets a Slide Master using its zero-based index in the collection. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.3] * - * @param key The string that identifies the `CustomProperty` object. It's case-insensitive. - * Keys have a maximum length of 255 characters. If the argument exceeds 255 characters, then this method returns the `InvalidArgument` error. + * @param index The index of the Slide Master in the collection. + * @returns The Slide Master at the given index. An error is thrown if index is out of range. */ - getItem(key: string): PowerPoint.CustomProperty; + getItemAt(index: number): PowerPoint.SlideMaster; /** - * Gets a `CustomProperty` by its key. - If the `CustomProperty` doesn't exist, then this method returns an object with its `isNullObject` property set to `true`. + * Gets a Slide Master using its unique ID. If such a Slide Master doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.3] * - * @param key The string that identifies the `CustomProperty` object. It's case-insensitive. - * Keys have a maximum length of 255 characters. If the argument exceeds 255 characters, then this method returns the `InvalidArgument` error. + * @param id The ID of the Slide Master. + * @returns The Slide Master with the unique ID. */ - getItemOrNullObject(key: string): PowerPoint.CustomProperty; + getItemOrNullObject(id: string): PowerPoint.SlideMaster; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param options Provides options for which properties of the object to load. */ - load(options?: PowerPoint.Interfaces.CustomPropertyCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.CustomPropertyCollection; + load(options?: PowerPoint.Interfaces.SlideMasterCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.SlideMasterCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. */ - load(propertyNames?: string | string[]): PowerPoint.CustomPropertyCollection; + load(propertyNames?: string | string[]): PowerPoint.SlideMasterCollection; /** * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. * * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.CustomPropertyCollection; + load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.SlideMasterCollection; /** * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.CustomPropertyCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.CustomPropertyCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. + * Whereas the original `PowerPoint.SlideMasterCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideMasterCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. */ - toJSON(): PowerPoint.Interfaces.CustomPropertyCollectionData; + toJSON(): PowerPoint.Interfaces.SlideMasterCollectionData; } - /** - * Represents presentation properties. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - class DocumentProperties extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** - * The collection of custom properties of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - readonly customProperties: PowerPoint.CustomPropertyCollection; - /** - * The author of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - author: string; - /** - * The category of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - category: string; - /** - * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - comments: string; - /** - * The company of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - company: string; - /** - * The creation date of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - readonly creationDate: Date; - /** - * The keywords of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - keywords: string; - /** - * The last author of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - readonly lastAuthor: string; - /** - * The manager of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - manager: string; - /** - * The revision number of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - revisionNumber: number; - /** - * The subject of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - subject: string; - /** - * The title of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - title: string; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.DocumentPropertiesLoadOptions): PowerPoint.DocumentProperties; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.DocumentProperties; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: { - select?: string; - expand?: string; - }): PowerPoint.DocumentProperties; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.DocumentProperties` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.DocumentPropertiesData`) that contains shallow copies of any loaded child properties from the original object. - */ - toJSON(): PowerPoint.Interfaces.DocumentPropertiesData; - } - /** - * Specifies the formatting options for when slides are inserted. - * - * @remarks - * [Api set: PowerPointApi 1.2] - */ - enum InsertSlideFormatting { - /** - * Copy the source theme into the target presentation and use that theme. - * @remarks - * [Api set: PowerPointApi 1.2] - */ - keepSourceFormatting = "KeepSourceFormatting", - /** - * Use the existing theme in the target presentation. - * @remarks - * [Api set: PowerPointApi 1.2] - */ - useDestinationTheme = "UseDestinationTheme", - } - /** - * Represents the available options when inserting slides. - * - * @remarks - * [Api set: PowerPointApi 1.2] - */ - interface InsertSlideOptions { - /** - * Specifies which formatting to use during slide insertion. - The default option is to use "KeepSourceFormatting". - * - * @remarks - * [Api set: PowerPointApi 1.2] - */ - formatting?: PowerPoint.InsertSlideFormatting | "KeepSourceFormatting" | "UseDestinationTheme"; - /** - * Specifies the slides from the source presentation that will be inserted into the current presentation. These slides are represented by their IDs which can be retrieved from a `Slide` object. - The order of these slides is preserved during the insertion. - If any of the source slides aren't found, or if the IDs are invalid, the operation throws a `SlideNotFound` exception and no slides will be inserted. - All of the source slides will be inserted when `sourceSlideIds` isn't provided (this is the default behavior). - * - * @remarks - * [Api set: PowerPointApi 1.2] - */ - sourceSlideIds?: string[]; - /** - * Specifies where in the presentation the new slides will be inserted. The new slides will be inserted after the slide with the given slide ID. - If `targetSlideId` isn't provided, the slides will be inserted at the beginning of the presentation. - If `targetSlideId` is invalid or if it's pointing to a non-existing slide, the operation throws a `SlideNotFound` exception and no slides will be inserted. - * - * @remarks - * [Api set: PowerPointApi 1.2] - */ - targetSlideId?: string; - } - /** - * Represents the collection of slides in the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.2] - */ - class SlideCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.Slide[]; - /** - * Adds a new slide at the end of the collection. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param options The options that define the theme of the new slide. - */ - add(options?: PowerPoint.AddSlideOptions): void; - /** - * Gets the number of slides in the collection. - * - * @remarks - * [Api set: PowerPointApi 1.2] - * @returns The number of slides in the collection. - */ - getCount(): OfficeExtension.ClientResult; - /** - * Gets a slide using its unique ID. - * - * @remarks - * [Api set: PowerPointApi 1.2] - * - * @param key The ID of the slide. - * @returns The slide with the unique ID. If such a slide doesn't exist, an error is thrown. - */ - getItem(key: string): PowerPoint.Slide; - /** - * Gets a slide using its zero-based index in the collection. Slides are stored in the same order as they - are shown in the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.2] - * - * @param index The index of the slide in the collection. - * @returns The slide at the given index. An error is thrown if index is out of range. - */ - getItemAt(index: number): PowerPoint.Slide; - /** - * Gets a slide using its unique ID. If such a slide doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see - {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. - * - * @remarks - * [Api set: PowerPointApi 1.2] - * - * @param id The ID of the slide. - * @returns The slide with the unique ID. - */ - getItemOrNullObject(id: string): PowerPoint.Slide; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.SlideCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.SlideCollection; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.SlideCollection; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.SlideCollection; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. - */ - toJSON(): PowerPoint.Interfaces.SlideCollectionData; - } - /** - * Represents a collection of slides in the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.5] - */ - class SlideScopedCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.Slide[]; - /** - * Gets the number of slides in the collection. - * - * @remarks - * [Api set: PowerPointApi 1.5] - * @returns The number of slides in the collection. - */ - getCount(): OfficeExtension.ClientResult; - /** - * Gets a slide using its unique ID. - * - * @remarks - * [Api set: PowerPointApi 1.5] - * - * @param key The ID of the slide. - * @returns The slide with the unique ID. If such a slide doesn't exist, an error is thrown. - */ - getItem(key: string): PowerPoint.Slide; - /** - * Gets a slide using its zero-based index in the collection. - * - * @remarks - * [Api set: PowerPointApi 1.5] - * - * @param index The index of the slide in the collection. - * @returns The slide at the given index. An error is thrown if index is out of range. - */ - getItemAt(index: number): PowerPoint.Slide; - /** - * Gets a slide using its unique ID. If such a slide doesn't exist, an object with an `isNullObject` property set to true is returned. For further information, see - {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. - * - * @remarks - * [Api set: PowerPointApi 1.5] - * - * @param id The ID of the slide. - * @returns The slide with the unique ID. - */ - getItemOrNullObject(id: string): PowerPoint.Slide; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.SlideScopedCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.SlideScopedCollection; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.SlideScopedCollection; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.SlideScopedCollection; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideScopedCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideScopedCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. - */ - toJSON(): PowerPoint.Interfaces.SlideScopedCollectionData; - } - /** - * Represents the collection of Slide Masters in the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.3] - */ - class SlideMasterCollection extends OfficeExtension.ClientObject { - /** The request context associated with the object. This connects the add-in's process to the Office host application's process. */ - context: RequestContext; - /** Gets the loaded child items in this collection. */ - readonly items: PowerPoint.SlideMaster[]; - /** - * Gets the number of Slide Masters in the collection. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * @returns The number of Slide Masters in the collection. - */ - getCount(): OfficeExtension.ClientResult; - /** - * Gets a Slide Master using its unique ID. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param key The ID of the Slide Master. - * @returns The Slide Master with the unique ID. If such a Slide Master doesn't exist, an error is thrown. - */ - getItem(key: string): PowerPoint.SlideMaster; - /** - * Gets a Slide Master using its zero-based index in the collection. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param index The index of the Slide Master in the collection. - * @returns The Slide Master at the given index. An error is thrown if index is out of range. - */ - getItemAt(index: number): PowerPoint.SlideMaster; - /** - * Gets a Slide Master using its unique ID. If such a Slide Master doesn't exist, an object with an `isNullObject` property set to true is returned. - For further information, see {@link https://learn.microsoft.com/office/dev/add-ins/develop/application-specific-api-model#ornullobject-methods-and-properties | *OrNullObject methods and properties}. - * - * @remarks - * [Api set: PowerPointApi 1.3] - * - * @param id The ID of the Slide Master. - * @returns The Slide Master with the unique ID. - */ - getItemOrNullObject(id: string): PowerPoint.SlideMaster; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param options Provides options for which properties of the object to load. - */ - load(options?: PowerPoint.Interfaces.SlideMasterCollectionLoadOptions & PowerPoint.Interfaces.CollectionLoadOptions): PowerPoint.SlideMasterCollection; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNames A comma-delimited string or an array of strings that specify the properties to load. - */ - load(propertyNames?: string | string[]): PowerPoint.SlideMasterCollection; - /** - * Queues up a command to load the specified properties of the object. You must call `context.sync()` before reading the properties. - * - * @param propertyNamesAndPaths `propertyNamesAndPaths.select` is a comma-delimited string that specifies the properties to load, and `propertyNamesAndPaths.expand` is a comma-delimited string that specifies the navigation properties to load. - */ - load(propertyNamesAndPaths?: OfficeExtension.LoadOption): PowerPoint.SlideMasterCollection; - /** - * Overrides the JavaScript `toJSON()` method in order to provide more useful output when an API object is passed to `JSON.stringify()`. (`JSON.stringify`, in turn, calls the `toJSON` method of the object that's passed to it.) - * Whereas the original `PowerPoint.SlideMasterCollection` object is an API object, the `toJSON` method returns a plain JavaScript object (typed as `PowerPoint.Interfaces.SlideMasterCollectionData`) that contains an "items" array with shallow copies of any loaded properties from the collection's items. - */ - toJSON(): PowerPoint.Interfaces.SlideMasterCollectionData; - } - enum ErrorCodes { - generalException = "GeneralException", - } - namespace Interfaces { + enum ErrorCodes { + generalException = "GeneralException", + } + namespace Interfaces { /** * Provides ways to load properties of only a subset of members of a collection. */ interface CollectionLoadOptions { /** - * Specify the number of items in the queried collection to be included in the result. - */ - $top?: number; + * Specify the number of items in the queried collection to be included in the result. + */ + $top?: number; + /** + * Specify the number of items in the collection that are to be skipped and not included in the result. If top is specified, the selection of result will start after skipping the specified number of items. + */ + $skip?: number; + } + /** An interface for updating data on the `CustomXmlPartScopedCollection` object, for use in `customXmlPartScopedCollection.set({ ... })`. */ + interface CustomXmlPartScopedCollectionUpdateData { + items?: PowerPoint.Interfaces.CustomXmlPartData[]; + } + /** An interface for updating data on the `CustomXmlPartCollection` object, for use in `customXmlPartCollection.set({ ... })`. */ + interface CustomXmlPartCollectionUpdateData { + items?: PowerPoint.Interfaces.CustomXmlPartData[]; + } + /** An interface for updating data on the `BulletFormat` object, for use in `bulletFormat.set({ ... })`. */ + interface BulletFormatUpdateData { + /** + * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + visible?: boolean | null; + } + /** An interface for updating data on the `ParagraphFormat` object, for use in `paragraphFormat.set({ ... })`. */ + interface ParagraphFormatUpdateData { + /** + * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + } + /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + interface ShapeFontUpdateData { + /** + * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: + + - `true`: All the text has the **All Caps** attribute. + + - `false`: None of the text has the **All Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + allCaps?: boolean | null; + /** + * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: + + - `true`: All the text is bold. + + - `false`: None of the text is bold. + + - `null`: Returned if some, but not all, of the text is bold. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean | null; /** - * Specify the number of items in the collection that are to be skipped and not included in the result. If top is specified, the selection of result will start after skipping the specified number of items. - */ - $skip?: number; - } - /** An interface for updating data on the `CustomXmlPartScopedCollection` object, for use in `customXmlPartScopedCollection.set({ ... })`. */ - interface CustomXmlPartScopedCollectionUpdateData { - items?: PowerPoint.Interfaces.CustomXmlPartData[]; - } - /** An interface for updating data on the `CustomXmlPartCollection` object, for use in `customXmlPartCollection.set({ ... })`. */ - interface CustomXmlPartCollectionUpdateData { - items?: PowerPoint.Interfaces.CustomXmlPartData[]; - } - /** An interface for updating data on the `Hyperlink` object, for use in `hyperlink.set({ ... })`. */ - interface HyperlinkUpdateData { + * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string | null; /** - * Specifies the URL target of the hyperlink. + * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Double strikethrough** attribute. + + - `false`: None of the text has the **Double strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.8] */ - address?: string; + doubleStrikethrough?: boolean | null; /** - * Specifies the string displayed when hovering over the hyperlink. + * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: + + - `true`: All the text is italicized. + + - `false`: None of the text is italicized. + + - `null`: Returned if some, but not all, of the text is italicized. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.4] */ - screenTip?: string; - } - /** An interface for updating data on the `HyperlinkCollection` object, for use in `hyperlinkCollection.set({ ... })`. */ - interface HyperlinkCollectionUpdateData { - items?: PowerPoint.Interfaces.HyperlinkData[]; - } - /** An interface for updating data on the `Border` object, for use in `border.set({ ... })`. */ - interface BorderUpdateData { + italic?: boolean | null; /** - * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). + * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - color?: string | undefined; + name?: string | null; /** - * Represents the dash style of the line. + * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; + size?: number | null; /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). + * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: + + - `true`: All the text has the **Small Caps** attribute. + + - `false`: None of the text has the **Small Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - transparency?: number | undefined; + smallCaps?: boolean | null; /** - * Represents the weight of the line, in points. + * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Strikethrough** attribute. + + - `false`: None of the text has the **Strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.8] */ - weight?: number | undefined; + strikethrough?: boolean | null; + /** + * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Subscript** attribute. + + - `false`: None of the text has the **Subscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + subscript?: boolean | null; + /** + * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Superscript** attribute. + + - `false`: None of the text has the **Superscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + superscript?: boolean | null; + /** + * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; } - /** An interface for updating data on the `Margins` object, for use in `margins.set({ ... })`. */ - interface MarginsUpdateData { + /** An interface for updating data on the `TextFrame` object, for use in `textFrame.set({ ... })`. */ + interface TextFrameUpdateData { /** - * Specifies the bottom margin in points. + * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - bottom?: number | undefined; + autoSizeSetting?: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; /** - * Specifies the left margin in points. + * Represents the bottom margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - left?: number | undefined; + bottomMargin?: number; /** - * Specifies the right margin in points. + * Represents the left margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - right?: number | undefined; + leftMargin?: number; /** - * Specifies the top margin in points. + * Represents the right margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.9] + * [Api set: PowerPointApi 1.4] */ - top?: number | undefined; - } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - interface ShapeFillUpdateData { + rightMargin?: number; /** - * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + * Represents the top margin, in points, of the text frame. * * @remarks * [Api set: PowerPointApi 1.4] */ - foregroundColor?: string; + topMargin?: number; /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - transparency?: number; + verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + /** + * Determines whether lines break automatically to fit text inside the shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wordWrap?: boolean; } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - interface ShapeFontUpdateData { + /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ + interface TextRangeUpdateData { /** - * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: - - - `true`: All the text has the **All Caps** attribute. - - - `false`: None of the text has the **All Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. + * Gets or sets the length of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.5] */ - allCaps?: boolean | null; + length?: number; /** - * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: - - - `true`: All the text is bold. - - - `false`: None of the text is bold. - - - `null`: Returned if some, but not all, of the text is bold. + * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - bold?: boolean | null; + start?: number; /** - * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. + * Represents the plain text content of the text range. * * @remarks * [Api set: PowerPointApi 1.4] */ - color?: string | null; + text?: string; + } + /** An interface for updating data on the `Hyperlink` object, for use in `hyperlink.set({ ... })`. */ + interface HyperlinkUpdateData { /** - * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Double strikethrough** attribute. - - - `false`: None of the text has the **Double strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + address?: string; + /** + * Specifies the string displayed when hovering over the hyperlink. + * + * @remarks + * [Api set: PowerPointApi 1.6] + */ + screenTip?: string; + } + /** An interface for updating data on the `HyperlinkCollection` object, for use in `hyperlinkCollection.set({ ... })`. */ + interface HyperlinkCollectionUpdateData { + items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface for updating data on the `Border` object, for use in `border.set({ ... })`. */ + interface BorderUpdateData { + /** + * Represents the line color in the hexadecimal format #RRGGBB (e.g., "FFA500") or as a named HTML color value (e.g., "orange"). * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - doubleStrikethrough?: boolean | null; + color?: string | undefined; /** - * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: - - - `true`: All the text is italicized. - - - `false`: None of the text is italicized. - - - `null`: Returned if some, but not all, of the text is italicized. + * Represents the dash style of the line. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.9] */ - italic?: boolean | null; + dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot" | undefined; /** - * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.9] */ - name?: string | null; + transparency?: number | undefined; /** - * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. + * Represents the weight of the line, in points. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.9] */ - size?: number | null; + weight?: number | undefined; + } + /** An interface for updating data on the `Margins` object, for use in `margins.set({ ... })`. */ + interface MarginsUpdateData { /** - * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: - - - `true`: All the text has the **Small Caps** attribute. - - - `false`: None of the text has the **Small Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. + * Specifies the bottom margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - smallCaps?: boolean | null; + bottom?: number | undefined; /** - * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Strikethrough** attribute. - - - `false`: None of the text has the **Strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. + * Specifies the left margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - strikethrough?: boolean | null; + left?: number | undefined; /** - * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Subscript** attribute. - - - `false`: None of the text has the **Subscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. + * Specifies the right margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - subscript?: boolean | null; + right?: number | undefined; /** - * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Superscript** attribute. - - - `false`: None of the text has the **Superscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * Specifies the top margin in points. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.9] */ - superscript?: boolean | null; + top?: number | undefined; + } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + interface ShapeFillUpdateData { /** - * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). * * @remarks * [Api set: PowerPointApi 1.4] */ - underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; + foregroundColor?: string; + /** + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + transparency?: number; } /** An interface for updating data on the `TableCell` object, for use in `tableCell.set({ ... })`. */ interface TableCellUpdateData { /** - * Specifies the horizontal alignment of the table cell. Returns `null` if the cell text contains different alignments. + * Specifies the horizontal alignment of the text in the table cell. Returns `null` if the cell text contains different alignments. * * @remarks * [Api set: PowerPointApi 1.9] */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; /** - * Specifies the indent level of the table cell. Returns `null` if the cell text contains different indent levels. + * Specifies the indent level of the text in the table cell. Returns `null` if the cell text contains different indent levels. * * @remarks * [Api set: PowerPointApi 1.9] @@ -134803,6 +135000,58 @@ declare namespace PowerPoint { interface TableRowCollectionUpdateData { items?: PowerPoint.Interfaces.TableRowData[]; } + /** An interface for updating data on the `TableStyleSettings` object, for use in `tableStyleSettings.set({ ... })`. */ + interface TableStyleSettingsUpdateData { + /** + * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + areColumnsBanded?: boolean; + /** + * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + areRowsBanded?: boolean; + /** + * Specifies if the first column contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isFirstColumnHighlighted?: boolean; + /** + * Specifies if the first row contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isFirstRowHighlighted?: boolean; + /** + * Specifies if the last column contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isLastColumnHighlighted?: boolean; + /** + * Specifies if the last row contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isLastRowHighlighted?: boolean; + /** + * Specifies the table style. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + style?: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ interface ShapeCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -134814,334 +135063,493 @@ declare namespace PowerPoint { /** An interface for updating data on the `Tag` object, for use in `tag.set({ ... })`. */ interface TagUpdateData { /** - * Gets the value of the tag. + * Gets the value of the tag. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + value?: string; + } + /** An interface for updating data on the `TagCollection` object, for use in `tagCollection.set({ ... })`. */ + interface TagCollectionUpdateData { + items?: PowerPoint.Interfaces.TagData[]; + } + /** An interface for updating data on the `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ + interface ShapeScopedCollectionUpdateData { + items?: PowerPoint.Interfaces.ShapeData[]; + } + /** An interface for updating data on the `ShapeLineFormat` object, for use in `shapeLineFormat.set({ ... })`. */ + interface ShapeLineFormatUpdateData { + /** + * Represents the line color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the dash style of the line. Returns null when the line isn't visible or there are inconsistent dash styles. See {@link PowerPoint.ShapeLineDashStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot"; + /** + * Represents the line style of the shape. Returns null when the line isn't visible or there are inconsistent styles. See {@link PowerPoint.ShapeLineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + style?: PowerPoint.ShapeLineStyle | "Single" | "ThickBetweenThin" | "ThickThin" | "ThinThick" | "ThinThin"; + /** + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). Returns null when the shape has inconsistent transparencies. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + transparency?: number; + /** + * Specifies if the line formatting of a shape element is visible. Returns `null` when the shape has inconsistent visibilities. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + visible?: boolean; + /** + * Represents the weight of the line, in points. Returns `null` when the line isn't visible or there are inconsistent line weights. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + weight?: number; + } + /** An interface for updating data on the `Shape` object, for use in `shape.set({ ... })`. */ + interface ShapeUpdateData { + /** + * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + height?: number; + /** + * The distance, in points, from the left side of the shape to the left side of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + left?: number; + /** + * Specifies the name of this shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * The distance, in points, from the top edge of the shape to the top edge of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + top?: number; + /** + * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + width?: number; + } + /** An interface for updating data on the `BindingCollection` object, for use in `bindingCollection.set({ ... })`. */ + interface BindingCollectionUpdateData { + items?: PowerPoint.Interfaces.BindingData[]; + } + /** An interface for updating data on the `CustomProperty` object, for use in `customProperty.set({ ... })`. */ + interface CustomPropertyUpdateData { + /** + * The value of the custom property. + If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + value?: boolean | Date | number | string; + } + /** An interface for updating data on the `CustomPropertyCollection` object, for use in `customPropertyCollection.set({ ... })`. */ + interface CustomPropertyCollectionUpdateData { + items?: PowerPoint.Interfaces.CustomPropertyData[]; + } + /** An interface for updating data on the `DocumentProperties` object, for use in `documentProperties.set({ ... })`. */ + interface DocumentPropertiesUpdateData { + /** + * The author of the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + author?: string; + /** + * The category of the presentation. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.7] */ - value?: string; - } - /** An interface for updating data on the `TagCollection` object, for use in `tagCollection.set({ ... })`. */ - interface TagCollectionUpdateData { - items?: PowerPoint.Interfaces.TagData[]; - } - /** An interface for updating data on the `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ - interface ShapeScopedCollectionUpdateData { - items?: PowerPoint.Interfaces.ShapeData[]; - } - /** An interface for updating data on the `ShapeLineFormat` object, for use in `shapeLineFormat.set({ ... })`. */ - interface ShapeLineFormatUpdateData { + category?: string; /** - * Represents the line color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - color?: string; + comments?: string; /** - * Represents the dash style of the line. Returns null when the line isn't visible or there are inconsistent dash styles. See {@link PowerPoint.ShapeLineDashStyle} for details. + * The company of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot"; + company?: string; /** - * Represents the line style of the shape. Returns null when the line isn't visible or there are inconsistent styles. See {@link PowerPoint.ShapeLineStyle} for details. + * The keywords of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - style?: PowerPoint.ShapeLineStyle | "Single" | "ThickBetweenThin" | "ThickThin" | "ThinThick" | "ThinThin"; + keywords?: string; /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). Returns null when the shape has inconsistent transparencies. + * The manager of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - transparency?: number; + manager?: string; /** - * Specifies if the line formatting of a shape element is visible. Returns `null` when the shape has inconsistent visibilities. + * The revision number of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - visible?: boolean; + revisionNumber?: number; /** - * Represents the weight of the line, in points. Returns `null` when the line isn't visible or there are inconsistent line weights. + * The subject of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - weight?: number; - } - /** An interface for updating data on the `BulletFormat` object, for use in `bulletFormat.set({ ... })`. */ - interface BulletFormatUpdateData { + subject?: string; /** - * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. + * The title of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - visible?: boolean | null; + title?: string; } - /** An interface for updating data on the `ParagraphFormat` object, for use in `paragraphFormat.set({ ... })`. */ - interface ParagraphFormatUpdateData { + /** An interface for updating data on the `SlideCollection` object, for use in `slideCollection.set({ ... })`. */ + interface SlideCollectionUpdateData { + items?: PowerPoint.Interfaces.SlideData[]; + } + /** An interface for updating data on the `SlideScopedCollection` object, for use in `slideScopedCollection.set({ ... })`. */ + interface SlideScopedCollectionUpdateData { + items?: PowerPoint.Interfaces.SlideData[]; + } + /** An interface for updating data on the `SlideMasterCollection` object, for use in `slideMasterCollection.set({ ... })`. */ + interface SlideMasterCollectionUpdateData { + items?: PowerPoint.Interfaces.SlideMasterData[]; + } + /** An interface describing the data returned by calling `presentation.toJSON()`. */ + interface PresentationData { /** - * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. + * Gets the ID of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + id?: string; + title?: string; } - /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ - interface TextRangeUpdateData { + /** An interface describing the data returned by calling `customXmlPart.toJSON()`. */ + interface CustomXmlPartData { /** - * Gets or sets the length of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. + * The ID of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - length?: number; + id?: string; /** - * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * The namespace URI of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - start?: number; + namespaceUri?: string; + } + /** An interface describing the data returned by calling `customXmlPartScopedCollection.toJSON()`. */ + interface CustomXmlPartScopedCollectionData { + items?: PowerPoint.Interfaces.CustomXmlPartData[]; + } + /** An interface describing the data returned by calling `customXmlPartCollection.toJSON()`. */ + interface CustomXmlPartCollectionData { + items?: PowerPoint.Interfaces.CustomXmlPartData[]; + } + /** An interface describing the data returned by calling `bulletFormat.toJSON()`. */ + interface BulletFormatData { /** - * Represents the plain text content of the text range. + * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. * * @remarks * [Api set: PowerPointApi 1.4] */ - text?: string; + visible?: boolean | null; } - /** An interface for updating data on the `TextFrame` object, for use in `textFrame.set({ ... })`. */ - interface TextFrameUpdateData { + /** An interface describing the data returned by calling `paragraphFormat.toJSON()`. */ + interface ParagraphFormatData { /** - * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. + * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - autoSizeSetting?: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; + horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + } + /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ + interface ShapeFontData { /** - * Represents the bottom margin, in points, of the text frame. + * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: + + - `true`: All the text has the **All Caps** attribute. + + - `false`: None of the text has the **All Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - bottomMargin?: number; + allCaps?: boolean | null; /** - * Represents the left margin, in points, of the text frame. + * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: + + - `true`: All the text is bold. + + - `false`: None of the text is bold. + + - `null`: Returned if some, but not all, of the text is bold. * * @remarks * [Api set: PowerPointApi 1.4] */ - leftMargin?: number; + bold?: boolean | null; /** - * Represents the right margin, in points, of the text frame. + * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. * * @remarks * [Api set: PowerPointApi 1.4] */ - rightMargin?: number; + color?: string | null; /** - * Represents the top margin, in points, of the text frame. + * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Double strikethrough** attribute. + + - `false`: None of the text has the **Double strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - topMargin?: number; + doubleStrikethrough?: boolean | null; /** - * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. + * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: + + - `true`: All the text is italicized. + + - `false`: None of the text is italicized. + + - `null`: Returned if some, but not all, of the text is italicized. * * @remarks * [Api set: PowerPointApi 1.4] */ - verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + italic?: boolean | null; /** - * Determines whether lines break automatically to fit text inside the shape. + * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. * * @remarks * [Api set: PowerPointApi 1.4] */ - wordWrap?: boolean; - } - /** An interface for updating data on the `Shape` object, for use in `shape.set({ ... })`. */ - interface ShapeUpdateData { + name?: string | null; /** - * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. * * @remarks * [Api set: PowerPointApi 1.4] */ - height?: number; + size?: number | null; /** - * The distance, in points, from the left side of the shape to the left side of the slide. + * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: + + - `true`: All the text has the **Small Caps** attribute. + + - `false`: None of the text has the **Small Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - left?: number; + smallCaps?: boolean | null; /** - * Specifies the name of this shape. + * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Strikethrough** attribute. + + - `false`: None of the text has the **Strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - name?: string; + strikethrough?: boolean | null; /** - * The distance, in points, from the top edge of the shape to the top edge of the slide. + * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Subscript** attribute. + + - `false`: None of the text has the **Subscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - top?: number; + subscript?: boolean | null; /** - * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Superscript** attribute. + + - `false`: None of the text has the **Superscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + superscript?: boolean | null; + /** + * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - width?: number; - } - /** An interface for updating data on the `BindingCollection` object, for use in `bindingCollection.set({ ... })`. */ - interface BindingCollectionUpdateData { - items?: PowerPoint.Interfaces.BindingData[]; + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; } - /** An interface for updating data on the `CustomProperty` object, for use in `customProperty.set({ ... })`. */ - interface CustomPropertyUpdateData { + /** An interface describing the data returned by calling `textFrame.toJSON()`. */ + interface TextFrameData { /** - * The value of the custom property. - If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - value?: boolean | Date | number | string; - } - /** An interface for updating data on the `CustomPropertyCollection` object, for use in `customPropertyCollection.set({ ... })`. */ - interface CustomPropertyCollectionUpdateData { - items?: PowerPoint.Interfaces.CustomPropertyData[]; - } - /** An interface for updating data on the `DocumentProperties` object, for use in `documentProperties.set({ ... })`. */ - interface DocumentPropertiesUpdateData { + autoSizeSetting?: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; /** - * The author of the presentation. + * Represents the bottom margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - author?: string; + bottomMargin?: number; /** - * The category of the presentation. + * Specifies if the text frame contains text. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - category?: string; + hasText?: boolean; /** - * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. + * Represents the left margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - comments?: string; + leftMargin?: number; /** - * The company of the presentation. + * Represents the right margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - company?: string; + rightMargin?: number; /** - * The keywords of the presentation. + * Represents the top margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - keywords?: string; + topMargin?: number; /** - * The manager of the presentation. + * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - manager?: string; + verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; /** - * The revision number of the presentation. + * Determines whether lines break automatically to fit text inside the shape. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - revisionNumber?: number; + wordWrap?: boolean; + } + /** An interface describing the data returned by calling `textRange.toJSON()`. */ + interface TextRangeData { /** - * The subject of the presentation. + * Gets or sets the length of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] */ - subject?: string; + length?: number; /** - * The title of the presentation. + * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] */ - title?: string; - } - /** An interface for updating data on the `SlideCollection` object, for use in `slideCollection.set({ ... })`. */ - interface SlideCollectionUpdateData { - items?: PowerPoint.Interfaces.SlideData[]; - } - /** An interface for updating data on the `SlideScopedCollection` object, for use in `slideScopedCollection.set({ ... })`. */ - interface SlideScopedCollectionUpdateData { - items?: PowerPoint.Interfaces.SlideData[]; - } - /** An interface for updating data on the `SlideMasterCollection` object, for use in `slideMasterCollection.set({ ... })`. */ - interface SlideMasterCollectionUpdateData { - items?: PowerPoint.Interfaces.SlideMasterData[]; - } - /** An interface describing the data returned by calling `presentation.toJSON()`. */ - interface PresentationData { + start?: number; /** - * Gets the ID of the presentation. + * Represents the plain text content of the text range. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.4] */ - id?: string; - title?: string; + text?: string; } - /** An interface describing the data returned by calling `customXmlPart.toJSON()`. */ - interface CustomXmlPartData { + /** An interface describing the data returned by calling `hyperlink.toJSON()`. */ + interface HyperlinkData { /** - * The ID of the custom XML part. + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - id?: string; + address?: string; /** - * The namespace URI of the custom XML part. + * Specifies the string displayed when hovering over the hyperlink. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - namespaceUri?: string; - } - /** An interface describing the data returned by calling `customXmlPartScopedCollection.toJSON()`. */ - interface CustomXmlPartScopedCollectionData { - items?: PowerPoint.Interfaces.CustomXmlPartData[]; - } - /** An interface describing the data returned by calling `customXmlPartCollection.toJSON()`. */ - interface CustomXmlPartCollectionData { - items?: PowerPoint.Interfaces.CustomXmlPartData[]; + screenTip?: string; } /** An interface describing the data returned by calling `placeholderFormat.toJSON()`. */ interface PlaceholderFormatData { @@ -135161,23 +135569,6 @@ declare namespace PowerPoint { */ type?: PowerPoint.PlaceholderType | "Unsupported" | "Date" | "SlideNumber" | "Footer" | "Header" | "Title" | "Body" | "CenterTitle" | "Subtitle" | "VerticalTitle" | "VerticalBody" | "Content" | "Chart" | "Table" | "OnlinePicture" | "SmartArt" | "Media" | "VerticalContent" | "Picture" | "Cameo"; } - /** An interface describing the data returned by calling `hyperlink.toJSON()`. */ - interface HyperlinkData { - /** - * Specifies the URL target of the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - address?: string; - /** - * Specifies the string displayed when hovering over the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - screenTip?: string; - } /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ interface HyperlinkCollectionData { items?: PowerPoint.Interfaces.HyperlinkData[]; @@ -135247,164 +135638,29 @@ declare namespace PowerPoint { */ top?: number | undefined; } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - interface ShapeFillData { - /** - * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - foregroundColor?: string; - /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - transparency?: number; - /** - * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - type?: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; - } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - interface ShapeFontData { - /** - * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: - - - `true`: All the text has the **All Caps** attribute. - - - `false`: None of the text has the **All Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - allCaps?: boolean | null; - /** - * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: - - - `true`: All the text is bold. - - - `false`: None of the text is bold. - - - `null`: Returned if some, but not all, of the text is bold. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean | null; - /** - * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string | null; - /** - * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Double strikethrough** attribute. - - - `false`: None of the text has the **Double strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - doubleStrikethrough?: boolean | null; - /** - * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: - - - `true`: All the text is italicized. - - - `false`: None of the text is italicized. - - - `null`: Returned if some, but not all, of the text is italicized. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean | null; - /** - * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string | null; - /** - * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number | null; - /** - * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: - - - `true`: All the text has the **Small Caps** attribute. - - - `false`: None of the text has the **Small Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - smallCaps?: boolean | null; - /** - * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Strikethrough** attribute. - - - `false`: None of the text has the **Strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - strikethrough?: boolean | null; + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + interface ShapeFillData { /** - * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Subscript** attribute. - - - `false`: None of the text has the **Subscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. + * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subscript?: boolean | null; + foregroundColor?: string; /** - * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Superscript** attribute. - - - `false`: None of the text has the **Superscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - superscript?: boolean | null; + transparency?: number; /** - * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble" | null; + type?: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; } /** An interface describing the data returned by calling `tableCell.toJSON()`. */ interface TableCellData { @@ -135424,14 +135680,14 @@ declare namespace PowerPoint { */ columnIndex?: number; /** - * Specifies the horizontal alignment of the table cell. Returns `null` if the cell text contains different alignments. + * Specifies the horizontal alignment of the text in the table cell. Returns `null` if the cell text contains different alignments. * * @remarks * [Api set: PowerPointApi 1.9] */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; /** - * Specifies the indent level of the table cell. Returns `null` if the cell text contains different indent levels. + * Specifies the indent level of the text in the table cell. Returns `null` if the cell text contains different indent levels. * * @remarks * [Api set: PowerPointApi 1.9] @@ -135528,6 +135784,58 @@ declare namespace PowerPoint { interface TableRowCollectionData { items?: PowerPoint.Interfaces.TableRowData[]; } + /** An interface describing the data returned by calling `tableStyleSettings.toJSON()`. */ + interface TableStyleSettingsData { + /** + * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + areColumnsBanded?: boolean; + /** + * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + areRowsBanded?: boolean; + /** + * Specifies if the first column contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isFirstColumnHighlighted?: boolean; + /** + * Specifies if the first row contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isFirstRowHighlighted?: boolean; + /** + * Specifies if the last column contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isLastColumnHighlighted?: boolean; + /** + * Specifies if the last row contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isLastRowHighlighted?: boolean; + /** + * Specifies the table style. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + style?: PowerPoint.TableStyle | "NoStyleNoGrid" | "ThemedStyle1Accent1" | "ThemedStyle1Accent2" | "ThemedStyle1Accent3" | "ThemedStyle1Accent4" | "ThemedStyle1Accent5" | "ThemedStyle1Accent6" | "NoStyleTableGrid" | "ThemedStyle2Accent1" | "ThemedStyle2Accent2" | "ThemedStyle2Accent3" | "ThemedStyle2Accent4" | "ThemedStyle2Accent5" | "ThemedStyle2Accent6" | "LightStyle1" | "LightStyle1Accent1" | "LightStyle1Accent2" | "LightStyle1Accent3" | "LightStyle1Accent4" | "LightStyle1Accent5" | "LightStyle1Accent6" | "LightStyle2" | "LightStyle2Accent1" | "LightStyle2Accent2" | "LightStyle2Accent3" | "LightStyle2Accent4" | "LightStyle2Accent5" | "LightStyle2Accent6" | "LightStyle3" | "LightStyle3Accent1" | "LightStyle3Accent2" | "LightStyle3Accent3" | "LightStyle3Accent4" | "LightStyle3Accent5" | "LightStyle3Accent6" | "MediumStyle1" | "MediumStyle1Accent1" | "MediumStyle1Accent2" | "MediumStyle1Accent3" | "MediumStyle1Accent4" | "MediumStyle1Accent5" | "MediumStyle1Accent6" | "MediumStyle2" | "MediumStyle2Accent1" | "MediumStyle2Accent2" | "MediumStyle2Accent3" | "MediumStyle2Accent4" | "MediumStyle2Accent5" | "MediumStyle2Accent6" | "MediumStyle3" | "MediumStyle3Accent1" | "MediumStyle3Accent2" | "MediumStyle3Accent3" | "MediumStyle3Accent4" | "MediumStyle3Accent5" | "MediumStyle3Accent6" | "MediumStyle4" | "MediumStyle4Accent1" | "MediumStyle4Accent2" | "MediumStyle4Accent3" | "MediumStyle4Accent4" | "MediumStyle4Accent5" | "MediumStyle4Accent6" | "DarkStyle1" | "DarkStyle1Accent1" | "DarkStyle1Accent2" | "DarkStyle1Accent3" | "DarkStyle1Accent4" | "DarkStyle1Accent5" | "DarkStyle1Accent6" | "DarkStyle2" | "DarkStyle2Accent1" | "DarkStyle2Accent2" | "DarkStyle2Accent3"; + } /** An interface describing the data returned by calling `table.toJSON()`. */ interface TableData { /** @@ -135590,538 +135898,772 @@ declare namespace PowerPoint { * Gets the unique ID of the Slide Master. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.3] + */ + id?: string; + /** + * Gets the unique name of the Slide Master. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + name?: string; + } + /** An interface describing the data returned by calling `tag.toJSON()`. */ + interface TagData { + /** + * Gets the unique ID of the tag. The `key` is unique within the owning `TagCollection` and always stored as uppercase letters within the document. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + key?: string; + /** + * Gets the value of the tag. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + value?: string; + } + /** An interface describing the data returned by calling `tagCollection.toJSON()`. */ + interface TagCollectionData { + items?: PowerPoint.Interfaces.TagData[]; + } + /** An interface describing the data returned by calling `slide.toJSON()`. */ + interface SlideData { + /** + * Gets the unique ID of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.2] + */ + id?: string; + /** + * Returns the zero-based index of the slide representing its position in the presentation. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + index?: number; + } + /** An interface describing the data returned by calling `shapeScopedCollection.toJSON()`. */ + interface ShapeScopedCollectionData { + items?: PowerPoint.Interfaces.ShapeData[]; + } + /** An interface describing the data returned by calling `shapeGroup.toJSON()`. */ + interface ShapeGroupData { + /** + * Gets the unique ID of the shape group. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + id?: string; + } + /** An interface describing the data returned by calling `shapeLineFormat.toJSON()`. */ + interface ShapeLineFormatData { + /** + * Represents the line color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the dash style of the line. Returns null when the line isn't visible or there are inconsistent dash styles. See {@link PowerPoint.ShapeLineDashStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot"; + /** + * Represents the line style of the shape. Returns null when the line isn't visible or there are inconsistent styles. See {@link PowerPoint.ShapeLineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + style?: PowerPoint.ShapeLineStyle | "Single" | "ThickBetweenThin" | "ThickThin" | "ThinThick" | "ThinThin"; + /** + * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). Returns null when the shape has inconsistent transparencies. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + transparency?: number; + /** + * Specifies if the line formatting of a shape element is visible. Returns `null` when the shape has inconsistent visibilities. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + visible?: boolean; + /** + * Represents the weight of the line, in points. Returns `null` when the line isn't visible or there are inconsistent line weights. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + weight?: number; + } + /** An interface describing the data returned by calling `shape.toJSON()`. */ + interface ShapeData { + /** + * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + height?: number; + /** + * Gets the unique ID of the shape. + * + * @remarks + * [Api set: PowerPointApi 1.3] + */ + id?: string; + /** + * The distance, in points, from the left side of the shape to the left side of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + left?: number; + /** + * Returns the level of the specified shape. + + - A level of 0 means the shape isn't part of a group. + + - A level of 1 means the shape is part of a top-level group. + + - A level greater than 1 indicates the shape is a nested group. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + level?: number; + /** + * Specifies the name of this shape. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * The distance, in points, from the top edge of the shape to the top edge of the slide. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + top?: number; + /** + * Returns the type of this shape. See {@link PowerPoint.ShapeType} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + type?: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox"; + /** + * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + width?: number; + /** + * Returns the z-order position of the shape, with 0 representing the bottom of the order stack. Every shape on a slide has a unique z-order, but + each slide also has a unique z-order stack, so two shapes on separate slides could have the same z-order number. + * + * @remarks + * [Api set: PowerPointApi 1.8] + */ + zOrderPosition?: number; + } + /** An interface describing the data returned by calling `binding.toJSON()`. */ + interface BindingData { + /** + * Represents the binding identifier. + * + * @remarks + * [Api set: PowerPointApi 1.8] */ id?: string; /** - * Gets the unique name of the Slide Master. + * Returns the type of the binding. See `BindingType` for details. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.8] */ - name?: string; + type?: PowerPoint.BindingType | "Shape"; } - /** An interface describing the data returned by calling `tag.toJSON()`. */ - interface TagData { + /** An interface describing the data returned by calling `bindingCollection.toJSON()`. */ + interface BindingCollectionData { + items?: PowerPoint.Interfaces.BindingData[]; + } + /** An interface describing the data returned by calling `customProperty.toJSON()`. */ + interface CustomPropertyData { /** - * Gets the unique ID of the tag. The `key` is unique within the owning `TagCollection` and always stored as uppercase letters within the document. + * The string that uniquely identifies the custom property. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.7] */ key?: string; /** - * Gets the value of the tag. + * The type of the value used for the custom property. * * @remarks - * [Api set: PowerPointApi 1.3] + * [Api set: PowerPointApi 1.7] */ - value?: string; + type?: PowerPoint.DocumentPropertyType | "Boolean" | "Date" | "Number" | "String"; + /** + * The value of the custom property. + If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + value?: boolean | Date | number | string; } - /** An interface describing the data returned by calling `tagCollection.toJSON()`. */ - interface TagCollectionData { - items?: PowerPoint.Interfaces.TagData[]; + /** An interface describing the data returned by calling `customPropertyCollection.toJSON()`. */ + interface CustomPropertyCollectionData { + items?: PowerPoint.Interfaces.CustomPropertyData[]; } - /** An interface describing the data returned by calling `slide.toJSON()`. */ - interface SlideData { + /** An interface describing the data returned by calling `documentProperties.toJSON()`. */ + interface DocumentPropertiesData { /** - * Gets the unique ID of the slide. + * The author of the presentation. * * @remarks - * [Api set: PowerPointApi 1.2] + * [Api set: PowerPointApi 1.7] */ - id?: string; + author?: string; /** - * Returns the zero-based index of the slide representing its position in the presentation. + * The category of the presentation. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - index?: number; - } - /** An interface describing the data returned by calling `shapeScopedCollection.toJSON()`. */ - interface ShapeScopedCollectionData { - items?: PowerPoint.Interfaces.ShapeData[]; - } - /** An interface describing the data returned by calling `shapeGroup.toJSON()`. */ - interface ShapeGroupData { + category?: string; /** - * Gets the unique ID of the shape group. + * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.7] */ - id?: string; - } - /** An interface describing the data returned by calling `shapeLineFormat.toJSON()`. */ - interface ShapeLineFormatData { + comments?: string; /** - * Represents the line color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). + * The company of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - color?: string; + company?: string; /** - * Represents the dash style of the line. Returns null when the line isn't visible or there are inconsistent dash styles. See {@link PowerPoint.ShapeLineDashStyle} for details. + * The creation date of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - dashStyle?: PowerPoint.ShapeLineDashStyle | "Dash" | "DashDot" | "DashDotDot" | "LongDash" | "LongDashDot" | "RoundDot" | "Solid" | "SquareDot" | "LongDashDotDot" | "SystemDash" | "SystemDot" | "SystemDashDot"; + creationDate?: Date; /** - * Represents the line style of the shape. Returns null when the line isn't visible or there are inconsistent styles. See {@link PowerPoint.ShapeLineStyle} for details. + * The keywords of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - style?: PowerPoint.ShapeLineStyle | "Single" | "ThickBetweenThin" | "ThickThin" | "ThinThick" | "ThinThin"; + keywords?: string; /** - * Specifies the transparency percentage of the line as a value from 0.0 (opaque) through 1.0 (clear). Returns null when the shape has inconsistent transparencies. + * The last author of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - transparency?: number; + lastAuthor?: string; /** - * Specifies if the line formatting of a shape element is visible. Returns `null` when the shape has inconsistent visibilities. + * The manager of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - visible?: boolean; + manager?: string; /** - * Represents the weight of the line, in points. Returns `null` when the line isn't visible or there are inconsistent line weights. + * The revision number of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - weight?: number; - } - /** An interface describing the data returned by calling `bulletFormat.toJSON()`. */ - interface BulletFormatData { + revisionNumber?: number; /** - * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. + * The subject of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - visible?: boolean | null; - } - /** An interface describing the data returned by calling `paragraphFormat.toJSON()`. */ - interface ParagraphFormatData { + subject?: string; /** - * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. + * The title of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed" | null; + title?: string; } - /** An interface describing the data returned by calling `textRange.toJSON()`. */ - interface TextRangeData { + /** An interface describing the data returned by calling `slideCollection.toJSON()`. */ + interface SlideCollectionData { + items?: PowerPoint.Interfaces.SlideData[]; + } + /** An interface describing the data returned by calling `slideScopedCollection.toJSON()`. */ + interface SlideScopedCollectionData { + items?: PowerPoint.Interfaces.SlideData[]; + } + /** An interface describing the data returned by calling `slideMasterCollection.toJSON()`. */ + interface SlideMasterCollectionData { + items?: PowerPoint.Interfaces.SlideMasterData[]; + } + /** + * @remarks + * [Api set: PowerPointApi 1.0] + */ + interface PresentationLoadOptions { /** - * Gets or sets the length of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. - * - * @remarks - * [Api set: PowerPointApi 1.5] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - length?: number; + $all?: boolean; /** - * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. + * Gets the properties of the presentation. * * @remarks - * [Api set: PowerPointApi 1.5] + * [Api set: PowerPointApi 1.7] */ - start?: number; + properties?: PowerPoint.Interfaces.DocumentPropertiesLoadOptions; /** - * Represents the plain text content of the text range. + * Gets the ID of the presentation. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.5] */ - text?: string; + id?: boolean; + title?: boolean; } - /** An interface describing the data returned by calling `textFrame.toJSON()`. */ - interface TextFrameData { + /** + * Represents a custom XML part object. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + interface CustomXmlPartLoadOptions { /** - * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. - * - * @remarks - * [Api set: PowerPointApi 1.4] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - autoSizeSetting?: PowerPoint.ShapeAutoSize | "AutoSizeNone" | "AutoSizeTextToFitShape" | "AutoSizeShapeToFitText" | "AutoSizeMixed"; + $all?: boolean; /** - * Represents the bottom margin, in points, of the text frame. + * The ID of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - bottomMargin?: number; + id?: boolean; /** - * Specifies if the text frame contains text. + * The namespace URI of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - hasText?: boolean; + namespaceUri?: boolean; + } + /** + * A scoped collection of custom XML parts. + A scoped collection is the result of some operation (such as filtering by namespace). + A scoped collection cannot be scoped any further. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + interface CustomXmlPartScopedCollectionLoadOptions { /** - * Represents the left margin, in points, of the text frame. + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + */ + $all?: boolean; + /** + * For EACH ITEM in the collection: The ID of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - leftMargin?: number; + id?: boolean; /** - * Represents the right margin, in points, of the text frame. + * For EACH ITEM in the collection: The namespace URI of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - rightMargin?: number; + namespaceUri?: boolean; + } + /** + * A collection of custom XML parts. + * + * @remarks + * [Api set: PowerPointApi 1.7] + */ + interface CustomXmlPartCollectionLoadOptions { /** - * Represents the top margin, in points, of the text frame. + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + */ + $all?: boolean; + /** + * For EACH ITEM in the collection: The ID of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] */ - topMargin?: number; + id?: boolean; /** - * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. + * For EACH ITEM in the collection: The namespace URI of the custom XML part. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.7] + */ + namespaceUri?: boolean; + } + /** + * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + interface BulletFormatLoadOptions { + /** + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - verticalAlignment?: PowerPoint.TextVerticalAlignment | "Top" | "Middle" | "Bottom" | "TopCentered" | "MiddleCentered" | "BottomCentered"; + $all?: boolean; /** - * Determines whether lines break automatically to fit text inside the shape. + * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. * * @remarks * [Api set: PowerPointApi 1.4] */ - wordWrap?: boolean; + visible?: boolean; } - /** An interface describing the data returned by calling `shape.toJSON()`. */ - interface ShapeData { + /** + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + interface ParagraphFormatLoadOptions { /** - * Specifies the height, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. - * - * @remarks - * [Api set: PowerPointApi 1.4] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - height?: number; + $all?: boolean; /** - * Gets the unique ID of the shape. - * - * @remarks - * [Api set: PowerPointApi 1.3] - */ - id?: string; + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bulletFormat?: PowerPoint.Interfaces.BulletFormatLoadOptions; /** - * The distance, in points, from the left side of the shape to the left side of the slide. + * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - left?: number; + horizontalAlignment?: boolean; + } + /** + * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + interface ShapeFontLoadOptions { /** - * Returns the level of the specified shape. + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + */ + $all?: boolean; + /** + * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: - - A level of 0 means the shape isn't part of a group. + - `true`: All the text has the **All Caps** attribute. - - A level of 1 means the shape is part of a top-level group. + - `false`: None of the text has the **All Caps** attribute. - - A level greater than 1 indicates the shape is a nested group. + - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. * * @remarks * [Api set: PowerPointApi 1.8] */ - level?: number; + allCaps?: boolean; /** - * Specifies the name of this shape. + * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: + + - `true`: All the text is bold. + + - `false`: None of the text is bold. + + - `null`: Returned if some, but not all, of the text is bold. * * @remarks * [Api set: PowerPointApi 1.4] */ - name?: string; + bold?: boolean; /** - * The distance, in points, from the top edge of the shape to the top edge of the slide. + * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. * * @remarks * [Api set: PowerPointApi 1.4] */ - top?: number; + color?: boolean; /** - * Returns the type of this shape. See {@link PowerPoint.ShapeType} for details. + * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Double strikethrough** attribute. + + - `false`: None of the text has the **Double strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.4] + * [Api set: PowerPointApi 1.8] */ - type?: PowerPoint.ShapeType | "Unsupported" | "Image" | "GeometricShape" | "Group" | "Line" | "Table" | "Callout" | "Chart" | "ContentApp" | "Diagram" | "Freeform" | "Graphic" | "Ink" | "Media" | "Model3D" | "Ole" | "Placeholder" | "SmartArt" | "TextBox"; + doubleStrikethrough?: boolean; /** - * Specifies the width, in points, of the shape. Throws an `InvalidArgument` exception when set with a negative value. + * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: + + - `true`: All the text is italicized. + + - `false`: None of the text is italicized. + + - `null`: Returned if some, but not all, of the text is italicized. * * @remarks * [Api set: PowerPointApi 1.4] */ - width?: number; + italic?: boolean; /** - * Returns the z-order position of the shape, with 0 representing the bottom of the order stack. Every shape on a slide has a unique z-order, but - each slide also has a unique z-order stack, so two shapes on separate slides could have the same z-order number. + * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - zOrderPosition?: number; - } - /** An interface describing the data returned by calling `binding.toJSON()`. */ - interface BindingData { + name?: boolean; /** - * Represents the binding identifier. + * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - id?: string; + size?: boolean; /** - * Returns the type of the binding. See `BindingType` for details. + * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: + + - `true`: All the text has the **Small Caps** attribute. + + - `false`: None of the text has the **Small Caps** attribute. + + - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. * * @remarks * [Api set: PowerPointApi 1.8] */ - type?: PowerPoint.BindingType | "Shape"; - } - /** An interface describing the data returned by calling `bindingCollection.toJSON()`. */ - interface BindingCollectionData { - items?: PowerPoint.Interfaces.BindingData[]; - } - /** An interface describing the data returned by calling `customProperty.toJSON()`. */ - interface CustomPropertyData { - /** - * The string that uniquely identifies the custom property. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - key?: string; - /** - * The type of the value used for the custom property. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - type?: PowerPoint.DocumentPropertyType | "Boolean" | "Date" | "Number" | "String"; - /** - * The value of the custom property. - If the value is a string, the maximum length 255 characters. Larger strings cause the operation to fail with an `InvalidArgument` error. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - value?: boolean | Date | number | string; - } - /** An interface describing the data returned by calling `customPropertyCollection.toJSON()`. */ - interface CustomPropertyCollectionData { - items?: PowerPoint.Interfaces.CustomPropertyData[]; - } - /** An interface describing the data returned by calling `documentProperties.toJSON()`. */ - interface DocumentPropertiesData { - /** - * The author of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - author?: string; + smallCaps?: boolean; /** - * The category of the presentation. + * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: + + - `true`: All the text has the **Strikethrough** attribute. + + - `false`: None of the text has the **Strikethrough** attribute. + + - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.8] */ - category?: string; + strikethrough?: boolean; /** - * The Comments field in the metadata of the presentation. These have no connection to comments made in slides. + * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Subscript** attribute. + + - `false`: None of the text has the **Subscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.8] */ - comments?: string; + subscript?: boolean; /** - * The company of the presentation. + * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: + + - `true`: All the text has the **Superscript** attribute. + + - `false`: None of the text has the **Superscript** attribute. + + - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.8] */ - company?: string; + superscript?: boolean; /** - * The creation date of the presentation. + * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - creationDate?: Date; + underline?: boolean; + } + /** + * Represents the text frame of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + interface TextFrameLoadOptions { /** - * The keywords of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - keywords?: string; + $all?: boolean; /** - * The last author of the presentation. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - lastAuthor?: string; + * Represents the text that is attached to a shape in the text frame, and properties and methods for manipulating the text. See {@link PowerPoint.TextRange} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textRange?: PowerPoint.Interfaces.TextRangeLoadOptions; /** - * The manager of the presentation. + * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - manager?: string; + autoSizeSetting?: boolean; /** - * The revision number of the presentation. + * Represents the bottom margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - revisionNumber?: number; + bottomMargin?: boolean; /** - * The subject of the presentation. + * Specifies if the text frame contains text. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - subject?: string; + hasText?: boolean; /** - * The title of the presentation. + * Represents the left margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] - */ - title?: string; - } - /** An interface describing the data returned by calling `slideCollection.toJSON()`. */ - interface SlideCollectionData { - items?: PowerPoint.Interfaces.SlideData[]; - } - /** An interface describing the data returned by calling `slideScopedCollection.toJSON()`. */ - interface SlideScopedCollectionData { - items?: PowerPoint.Interfaces.SlideData[]; - } - /** An interface describing the data returned by calling `slideMasterCollection.toJSON()`. */ - interface SlideMasterCollectionData { - items?: PowerPoint.Interfaces.SlideMasterData[]; - } - /** - * @remarks - * [Api set: PowerPointApi 1.0] - */ - interface PresentationLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + * [Api set: PowerPointApi 1.4] */ - $all?: boolean; + leftMargin?: boolean; /** - * Gets the properties of the presentation. + * Represents the right margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - properties?: PowerPoint.Interfaces.DocumentPropertiesLoadOptions; + rightMargin?: boolean; /** - * Gets the ID of the presentation. + * Represents the top margin, in points, of the text frame. * * @remarks - * [Api set: PowerPointApi 1.5] - */ - id?: boolean; - title?: boolean; - } - /** - * Represents a custom XML part object. - * - * @remarks - * [Api set: PowerPointApi 1.7] - */ - interface CustomXmlPartLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + * [Api set: PowerPointApi 1.4] */ - $all?: boolean; + topMargin?: boolean; /** - * The ID of the custom XML part. + * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - id?: boolean; + verticalAlignment?: boolean; /** - * The namespace URI of the custom XML part. + * Determines whether lines break automatically to fit text inside the shape. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - namespaceUri?: boolean; + wordWrap?: boolean; } /** - * A scoped collection of custom XML parts. - A scoped collection is the result of some operation (such as filtering by namespace). - A scoped collection cannot be scoped any further. + * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.4] */ - interface CustomXmlPartScopedCollectionLoadOptions { + interface TextRangeLoadOptions { /** Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; /** - * For EACH ITEM in the collection: The ID of the custom XML part. + * Returns a `ShapeFont` object that represents the font attributes for the text range. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + font?: PowerPoint.Interfaces.ShapeFontLoadOptions; + /** + * Represents the paragraph format of the text range. See {@link PowerPoint.ParagraphFormat} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + paragraphFormat?: PowerPoint.Interfaces.ParagraphFormatLoadOptions; + /** + * Gets or sets the length of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] */ - id?: boolean; + length?: boolean; /** - * For EACH ITEM in the collection: The namespace URI of the custom XML part. + * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. + Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.5] */ - namespaceUri?: boolean; + start?: boolean; + /** + * Represents the plain text content of the text range. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + text?: boolean; } /** - * A collection of custom XML parts. + * Represents a single hyperlink. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - interface CustomXmlPartCollectionLoadOptions { + interface HyperlinkLoadOptions { /** Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; /** - * For EACH ITEM in the collection: The ID of the custom XML part. + * Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - id?: boolean; + address?: boolean; /** - * For EACH ITEM in the collection: The namespace URI of the custom XML part. + * Specifies the string displayed when hovering over the hyperlink. * * @remarks - * [Api set: PowerPointApi 1.7] + * [Api set: PowerPointApi 1.6] */ - namespaceUri?: boolean; + screenTip?: boolean; } /** * Represents the properties of a `placeholder` shape. @@ -136150,32 +136692,6 @@ declare namespace PowerPoint { */ type?: boolean; } - /** - * Represents a single hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - interface HyperlinkLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Specifies the URL target of the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - address?: boolean; - /** - * Specifies the string displayed when hovering over the hyperlink. - * - * @remarks - * [Api set: PowerPointApi 1.6] - */ - screenTip?: boolean; - } /** * Represents a collection of hyperlinks. * @@ -136188,7 +136704,7 @@ declare namespace PowerPoint { */ $all?: boolean; /** - * For EACH ITEM in the collection: Specifies the URL target of the hyperlink. + * For EACH ITEM in the collection: Specifies the address of the hyperlink, which can be a URL, a file name or file path, or an email address with the `mailto` URI scheme. * * @remarks * [Api set: PowerPointApi 1.6] @@ -136343,175 +136859,31 @@ declare namespace PowerPoint { * [Api set: PowerPointApi 1.4] */ interface ShapeFillLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - foregroundColor?: boolean; - /** - * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - transparency?: boolean; - /** - * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - type?: boolean; - } - /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface ShapeFontLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **All Caps** attribute which makes lowercase letters appear as uppercase letters. The possible values are as follows: - - - `true`: All the text has the **All Caps** attribute. - - - `false`: None of the text has the **All Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **All Caps** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - allCaps?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to bold. The possible values are as follows: - - - `true`: All the text is bold. - - - `false`: None of the text is bold. - - - `null`: Returned if some, but not all, of the text is bold. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * Specifies the HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` contains text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **Double strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Double strikethrough** attribute. - - - `false`: None of the text has the **Double strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Double strikethrough** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - doubleStrikethrough?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to italic. The possible values are as follows: - - - `true`: All the text is italicized. - - - `false`: None of the text is italicized. - - - `null`: Returned if some, but not all, of the text is italicized. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Specifies the font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it's the Latin font name. Returns `null` if the `TextRange` contains text fragments with different font names. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Specifies the font size in points (e.g., 11). Returns `null` if the `TextRange` contains text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **Small Caps** attribute which makes lowercase letters appear as small uppercase letters. The possible values are as follows: - - - `true`: All the text has the **Small Caps** attribute. - - - `false`: None of the text has the **Small Caps** attribute. - - - `null`: Returned if some, but not all, of the text has the **Small Caps** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] - */ - smallCaps?: boolean; - /** - * Specifies whether the text in the `TextRange` is set to use the **Strikethrough** attribute. The possible values are as follows: - - - `true`: All the text has the **Strikethrough** attribute. - - - `false`: None of the text has the **Strikethrough** attribute. - - - `null`: Returned if some, but not all, of the text has the **Strikethrough** attribute. - * - * @remarks - * [Api set: PowerPointApi 1.8] + /** + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ - strikethrough?: boolean; + $all?: boolean; /** - * Specifies whether the text in the `TextRange` is set to use the **Subscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Subscript** attribute. - - - `false`: None of the text has the **Subscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Subscript** attribute. + * Represents the shape fill foreground color in HTML color format, in the form #RRGGBB (e.g., "FFA500") or as a named HTML color (e.g., "orange"). * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - subscript?: boolean; + foregroundColor?: boolean; /** - * Specifies whether the text in the `TextRange` is set to use the **Superscript** attribute. The possible values are as follows: - - - `true`: All the text has the **Superscript** attribute. - - - `false`: None of the text has the **Superscript** attribute. - - - `null`: Returned if some, but not all, of the text has the **Superscript** attribute. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type doesn't support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. * * @remarks - * [Api set: PowerPointApi 1.8] + * [Api set: PowerPointApi 1.4] */ - superscript?: boolean; + transparency?: boolean; /** - * Specifies the type of underline applied to the font. Returns `null` if the `TextRange` contains text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - underline?: boolean; + type?: boolean; } /** * Represents a table. @@ -136568,14 +136940,14 @@ declare namespace PowerPoint { */ columnIndex?: boolean; /** - * Specifies the horizontal alignment of the table cell. Returns `null` if the cell text contains different alignments. + * Specifies the horizontal alignment of the text in the table cell. Returns `null` if the cell text contains different alignments. * * @remarks * [Api set: PowerPointApi 1.9] */ horizontalAlignment?: boolean; /** - * Specifies the indent level of the table cell. Returns `null` if the cell text contains different indent levels. + * Specifies the indent level of the text in the table cell. Returns `null` if the cell text contains different indent levels. * * @remarks * [Api set: PowerPointApi 1.9] @@ -136674,14 +137046,14 @@ declare namespace PowerPoint { */ columnIndex?: boolean; /** - * For EACH ITEM in the collection: Specifies the horizontal alignment of the table cell. Returns `null` if the cell text contains different alignments. + * For EACH ITEM in the collection: Specifies the horizontal alignment of the text in the table cell. Returns `null` if the cell text contains different alignments. * * @remarks * [Api set: PowerPointApi 1.9] */ horizontalAlignment?: boolean; /** - * For EACH ITEM in the collection: Specifies the indent level of the table cell. Returns `null` if the cell text contains different indent levels. + * For EACH ITEM in the collection: Specifies the indent level of the text in the table cell. Returns `null` if the cell text contains different indent levels. * * @remarks * [Api set: PowerPointApi 1.9] @@ -136843,6 +137215,67 @@ declare namespace PowerPoint { */ rowIndex?: boolean; } + /** + * Represents the available table style settings. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + interface TableStyleSettingsLoadOptions { + /** + Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). + */ + $all?: boolean; + /** + * Specifies if the columns show banded formatting in which odd columns are highlighted differently from even ones, to make reading the table easier. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + areColumnsBanded?: boolean; + /** + * Specifies if the rows show banded formatting in which odd rows are highlighted differently from even ones, to make reading the table easier. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + areRowsBanded?: boolean; + /** + * Specifies if the first column contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isFirstColumnHighlighted?: boolean; + /** + * Specifies if the first row contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isFirstRowHighlighted?: boolean; + /** + * Specifies if the last column contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isLastColumnHighlighted?: boolean; + /** + * Specifies if the last row contains special formatting. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + isLastRowHighlighted?: boolean; + /** + * Specifies the table style. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + style?: boolean; + } /** * Represents a table. * @@ -136854,6 +137287,13 @@ declare namespace PowerPoint { Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). */ $all?: boolean; + /** + * Gets the table style settings. + * + * @remarks + * [Api set: PowerPointApi 1.9] + */ + styleSettings?: PowerPoint.Interfaces.TableStyleSettingsLoadOptions; /** * Gets the number of columns in the table. * @@ -137394,175 +137834,6 @@ declare namespace PowerPoint { */ weight?: boolean; } - /** - * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface BulletFormatLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Specifies if the bullets in the paragraph are visible. Returns `null` if the {@link PowerPoint.TextRange} includes text fragments with different bullet visibility values. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - visible?: boolean; - } - /** - * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface ParagraphFormatLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bulletFormat?: PowerPoint.Interfaces.BulletFormatLoadOptions; - /** - * Represents the horizontal alignment of the paragraph. Returns 'null' if the 'TextRange' includes text fragments with different horizontal alignment values. See {@link PowerPoint.ParagraphHorizontalAlignment} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - horizontalAlignment?: boolean; - } - /** - * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface TextRangeLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Returns a `ShapeFont` object that represents the font attributes for the text range. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - font?: PowerPoint.Interfaces.ShapeFontLoadOptions; - /** - * Represents the paragraph format of the text range. See {@link PowerPoint.ParagraphFormat} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - paragraphFormat?: PowerPoint.Interfaces.ParagraphFormatLoadOptions; - /** - * Gets or sets the length of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the available text from the starting point. - * - * @remarks - * [Api set: PowerPointApi 1.5] - */ - length?: boolean; - /** - * Gets or sets zero-based index, relative to the parent text frame, for the starting position of the range that this `TextRange` represents. - Throws an `InvalidArgument` exception when set with a negative value or if the value is greater than the length of the text. - * - * @remarks - * [Api set: PowerPointApi 1.5] - */ - start?: boolean; - /** - * Represents the plain text content of the text range. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - text?: boolean; - } - /** - * Represents the text frame of a shape object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - interface TextFrameLoadOptions { - /** - Specifying `$all` for the load options loads all the scalar properties (such as `Range.address`) but not the navigational properties (such as `Range.format.fill.color`). - */ - $all?: boolean; - /** - * Represents the text that is attached to a shape in the text frame, and properties and methods for manipulating the text. See {@link PowerPoint.TextRange} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - textRange?: PowerPoint.Interfaces.TextRangeLoadOptions; - /** - * The automatic sizing settings for the text frame. A text frame can be set to automatically fit the text to the text frame, to automatically fit the text frame to the text, or not perform any automatic sizing. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - autoSizeSetting?: boolean; - /** - * Represents the bottom margin, in points, of the text frame. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bottomMargin?: boolean; - /** - * Specifies if the text frame contains text. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - hasText?: boolean; - /** - * Represents the left margin, in points, of the text frame. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - leftMargin?: boolean; - /** - * Represents the right margin, in points, of the text frame. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - rightMargin?: boolean; - /** - * Represents the top margin, in points, of the text frame. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - topMargin?: boolean; - /** - * Represents the vertical alignment of the text frame. See {@link PowerPoint.TextVerticalAlignment} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - verticalAlignment?: boolean; - /** - * Determines whether lines break automatically to fit text inside the shape. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - wordWrap?: boolean; - } /** * Represents a single shape in the slide. *