From 6ce3ee357dd1891b6881a302b5a1991264a2c0c8 Mon Sep 17 00:00:00 2001 From: Elizabeth Samuel Date: Tue, 21 Jan 2025 11:28:19 -0800 Subject: [PATCH] [all hosts] Get latest (#2184) --- .../PowerPoint_1_1/powerpoint.d.ts | 58 +- .../PowerPoint_1_2/powerpoint.d.ts | 70 +- .../PowerPoint_1_3/powerpoint.d.ts | 70 +- .../PowerPoint_1_4/powerpoint.d.ts | 1258 ++++++++-------- .../PowerPoint_1_5/powerpoint.d.ts | 1258 ++++++++-------- .../PowerPoint_1_6/powerpoint.d.ts | 1266 ++++++++--------- .../PowerPoint_1_7/powerpoint.d.ts | 1266 ++++++++--------- .../powerpoint.d.ts | 1266 ++++++++--------- generate-docs/script-inputs/office.d.ts | 1266 ++++++++--------- .../script-inputs/office_preview.d.ts | 1266 ++++++++--------- 10 files changed, 4522 insertions(+), 4522 deletions(-) diff --git a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_1/powerpoint.d.ts b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_1/powerpoint.d.ts index 487f01502..5a18e54b2 100644 --- a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_1/powerpoint.d.ts +++ b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_1/powerpoint.d.ts @@ -146,6 +146,20 @@ export declare namespace PowerPoint { /** An interface for updating data on the `HyperlinkCollection` object, for use in `hyperlinkCollection.set({ ... })`. */ export interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + export interface ShapeFillUpdateData { + + + } + /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + export interface ShapeFontUpdateData { + + + + + + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ export interface ShapeCollectionUpdateData { @@ -162,11 +176,6 @@ export declare namespace PowerPoint { /** An interface for updating data on the `TagCollection` object, for use in `tagCollection.set({ ... })`. */ export interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; - } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - export interface ShapeFillUpdateData { - - } /** An interface for updating data on the `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ export interface ShapeScopedCollectionUpdateData { @@ -188,15 +197,6 @@ export declare namespace PowerPoint { /** An interface for updating data on the `ParagraphFormat` object, for use in `paragraphFormat.set({ ... })`. */ export interface ParagraphFormatUpdateData { - } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - export interface ShapeFontUpdateData { - - - - - - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ export interface TextRangeUpdateData { @@ -280,6 +280,21 @@ export declare namespace PowerPoint { /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ export interface HyperlinkCollectionData { items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + export interface ShapeFillData { + + + + } + /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ + export interface ShapeFontData { + + + + + + } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ export interface ShapeCollectionData { @@ -311,12 +326,6 @@ export declare namespace PowerPoint { /** An interface describing the data returned by calling `slide.toJSON()`. */ export interface SlideData { - } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - export interface ShapeFillData { - - - } /** An interface describing the data returned by calling `shapeScopedCollection.toJSON()`. */ export interface ShapeScopedCollectionData { @@ -338,15 +347,6 @@ export declare namespace PowerPoint { /** An interface describing the data returned by calling `paragraphFormat.toJSON()`. */ export interface ParagraphFormatData { - } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - export interface ShapeFontData { - - - - - - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ export interface TextRangeData { diff --git a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_2/powerpoint.d.ts b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_2/powerpoint.d.ts index 001ae5d51..21aa3d48f 100644 --- a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_2/powerpoint.d.ts +++ b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_2/powerpoint.d.ts @@ -102,6 +102,10 @@ export declare namespace PowerPoint { + + + + @@ -175,10 +179,6 @@ export declare namespace PowerPoint { - - - - /** * Specifies the formatting options for when slides are inserted. * @@ -345,6 +345,20 @@ export declare namespace PowerPoint { /** An interface for updating data on the `HyperlinkCollection` object, for use in `hyperlinkCollection.set({ ... })`. */ export interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + export interface ShapeFillUpdateData { + + + } + /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + export interface ShapeFontUpdateData { + + + + + + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ export interface ShapeCollectionUpdateData { @@ -361,11 +375,6 @@ export declare namespace PowerPoint { /** An interface for updating data on the `TagCollection` object, for use in `tagCollection.set({ ... })`. */ export interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; - } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - export interface ShapeFillUpdateData { - - } /** An interface for updating data on the `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ export interface ShapeScopedCollectionUpdateData { @@ -387,15 +396,6 @@ export declare namespace PowerPoint { /** An interface for updating data on the `ParagraphFormat` object, for use in `paragraphFormat.set({ ... })`. */ export interface ParagraphFormatUpdateData { - } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - export interface ShapeFontUpdateData { - - - - - - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ export interface TextRangeUpdateData { @@ -479,6 +479,21 @@ export declare namespace PowerPoint { /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ export interface HyperlinkCollectionData { items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + export interface ShapeFillData { + + + + } + /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ + export interface ShapeFontData { + + + + + + } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ export interface ShapeCollectionData { @@ -516,12 +531,6 @@ export declare namespace PowerPoint { * [Api set: PowerPointApi 1.2] */ id?: string; - } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - export interface ShapeFillData { - - - } /** An interface describing the data returned by calling `shapeScopedCollection.toJSON()`. */ export interface ShapeScopedCollectionData { @@ -543,15 +552,6 @@ export declare namespace PowerPoint { /** An interface describing the data returned by calling `paragraphFormat.toJSON()`. */ export interface ParagraphFormatData { - } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - export interface ShapeFontData { - - - - - - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ export interface TextRangeData { @@ -640,6 +640,8 @@ export declare namespace PowerPoint { + + /** * Represents a single slide of a presentation. * @@ -671,8 +673,6 @@ export declare namespace PowerPoint { - - /** * Represents the collection of slides in the presentation. * diff --git a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_3/powerpoint.d.ts b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_3/powerpoint.d.ts index 6c580cb39..f5eb0fd35 100644 --- a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_3/powerpoint.d.ts +++ b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_3/powerpoint.d.ts @@ -137,6 +137,10 @@ export declare namespace PowerPoint { + + + + /** * Represents the collection of shapes. * @@ -643,10 +647,6 @@ export declare namespace PowerPoint { - - - - /** * Represents a single shape in the slide. * @@ -971,6 +971,20 @@ export declare namespace PowerPoint { /** An interface for updating data on the `HyperlinkCollection` object, for use in `hyperlinkCollection.set({ ... })`. */ export interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + export interface ShapeFillUpdateData { + + + } + /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + export interface ShapeFontUpdateData { + + + + + + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ export interface ShapeCollectionUpdateData { @@ -993,11 +1007,6 @@ export declare namespace PowerPoint { /** An interface for updating data on the `TagCollection` object, for use in `tagCollection.set({ ... })`. */ export interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; - } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - export interface ShapeFillUpdateData { - - } /** An interface for updating data on the `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ export interface ShapeScopedCollectionUpdateData { @@ -1019,15 +1028,6 @@ export declare namespace PowerPoint { /** An interface for updating data on the `ParagraphFormat` object, for use in `paragraphFormat.set({ ... })`. */ export interface ParagraphFormatUpdateData { - } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - export interface ShapeFontUpdateData { - - - - - - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ export interface TextRangeUpdateData { @@ -1111,6 +1111,21 @@ export declare namespace PowerPoint { /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ export interface HyperlinkCollectionData { items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + export interface ShapeFillData { + + + + } + /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ + export interface ShapeFontData { + + + + + + } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ export interface ShapeCollectionData { @@ -1184,12 +1199,6 @@ export declare namespace PowerPoint { * [Api set: PowerPointApi 1.2] */ id?: string; - } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - export interface ShapeFillData { - - - } /** An interface describing the data returned by calling `shapeScopedCollection.toJSON()`. */ export interface ShapeScopedCollectionData { @@ -1211,15 +1220,6 @@ export declare namespace PowerPoint { /** An interface describing the data returned by calling `paragraphFormat.toJSON()`. */ export interface ParagraphFormatData { - } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - export interface ShapeFontData { - - - - - - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ export interface TextRangeData { @@ -1308,6 +1308,8 @@ export declare namespace PowerPoint { + + /** * Represents the collection of shapes. * @@ -1505,8 +1507,6 @@ export declare namespace PowerPoint { - - /** * Represents a single shape in the slide. * diff --git a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_4/powerpoint.d.ts b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_4/powerpoint.d.ts index fe32c19c7..c25aa5c63 100644 --- a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_4/powerpoint.d.ts +++ b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_4/powerpoint.d.ts @@ -128,6 +128,128 @@ export declare namespace PowerPoint { + /** + * Specifies the type of a shape. + * + * @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", + /** + * The shape is a geometric shape such as rectangle. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + geometricShape = "GeometricShape", + /** + * The shape is a group shape which contains sub-shapes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + group = "Group", + /** + * The shape is a line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + line = "Line", + /** + * The shape is a table. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + table = "Table", + /** + * The shape is a callout. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + callout = "Callout", + /** + * The shape is a chart. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + chart = "Chart", + /** + * The shape is a content Office Add-in. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + contentApp = "ContentApp", + /** + * The shape is a diagram. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + diagram = "Diagram", + /** + * The shape is a freeform object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + freeform = "Freeform", + /** + * The shape is a graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + graphic = "Graphic", + /** + * The shape is an ink object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ink = "Ink", + /** + * The shape is a media object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + media = "Media", + /** + * The shape is a 3D model. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + model3D = "Model3D", + /** + * The shape is an OLE (Object Linking and Embedding) object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ole = "Ole", + /** + * The shape is a placeholder. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + placeholder = "Placeholder", + /** + * The shape is a SmartArt graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + smartArt = "SmartArt", + /** + * The shape is a text box. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textBox = "TextBox", + } /** @@ -1349,164 +1471,359 @@ export declare namespace PowerPoint { systemDashDot = "SystemDashDot", } /** - * The type of underline applied to a font. + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ShapeFontUnderlineStyle { - /** - * No underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - none = "None", - /** - * Regular single line underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - single = "Single", - /** - * Underlining of text with double lines. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - double = "Double", - /** - * Underlining of text with a thick line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - heavy = "Heavy", + enum ParagraphHorizontalAlignment { /** - * Underlining of text with a dotted line. + * Align text to the left margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + left = "Left", /** - * Underlining of text with a thick, dotted line. + * Align text in the center. * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + center = "Center", /** - * Underlining of text with a line containing dashes. + * Align text to the right margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + right = "Right", /** - * Underlining of text with a thick line containing dashes. + * Align text so that it is justified across the whole line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + justify = "Justify", /** - * Underlining of text with a line containing long dashes. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + justifyLow = "JustifyLow", /** - * Underlining of text with a thick line containing long dashes. + * Distributes the text words across an entire text line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + distributed = "Distributed", /** - * Underlining of text with a line containing dots and dashes. + * Distributes Thai text specially, because each character is treated as a word. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + thaiDistributed = "ThaiDistributed", + } + /** + * Specifies a shape's fill type. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeFillType { /** - * Underlining of text with a thick line containing dots and dashes. + * Specifies that the shape should have no fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + noFill = "NoFill", /** - * Underlining of text with a line containing double dots and dashes. + * Specifies that the shape should have regular solid fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + solid = "Solid", /** - * Underlining of text with a thick line containing double dots and dashes. + * Specifies that the shape should have gradient fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + gradient = "Gradient", /** - * Underlining of text with a wavy line. + * Specifies that the shape should have pattern fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + pattern = "Pattern", /** - * Underlining of text with a thick, wavy line. + * Specifies that the shape should have picture or texture fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + pictureAndTexture = "PictureAndTexture", /** - * Underlining of text with double wavy lines. + * Specifies that the shape should have slide background fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", + slideBackground = "SlideBackground", } /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + * Represents the fill formatting of a shape object. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ParagraphHorizontalAlignment { + export 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; /** - * Align text to the left margin. + * 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] */ - left = "Left", + foregroundColor: string; /** - * Align text in the center. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type does not support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + transparency: number; /** - * Align text to the right margin. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; /** - * Align text so that it is justified across the whole line. + * Clears the fill formatting of this shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + clear(): void; /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * 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"). */ - justifyLow = "JustifyLow", + setSolidColor(color: string): void; /** - * Distributes the text words across an entire text line. - * @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. */ - distributed = "Distributed", + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** - * Distributes Thai text specially, because each character is treated as a word. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - thaiDistributed = "ThaiDistributed", + * 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 { + /** + * No underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + none = "None", + /** + * Regular single line underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + single = "Single", + /** + * Underlining of text with double lines. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + double = "Double", + /** + * Underlining of text with a thick line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + heavy = "Heavy", + /** + * Underlining of text with a dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotted = "Dotted", + /** + * Underlining of text with a thick, dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dottedHeavy = "DottedHeavy", + /** + * Underlining of text with a line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dash = "Dash", + /** + * Underlining of text with a thick line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashHeavy = "DashHeavy", + /** + * Underlining of text with a line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLong = "DashLong", + /** + * Underlining of text with a thick line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLongHeavy = "DashLongHeavy", + /** + * Underlining of text with a line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDash = "DotDash", + /** + * Underlining of text with a thick line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDashHeavy = "DotDashHeavy", + /** + * Underlining of text with a line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDash = "DotDotDash", + /** + * Underlining of text with a thick line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDashHeavy = "DotDotDashHeavy", + /** + * Underlining of text with a wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavy = "Wavy", + /** + * Underlining of text with a thick, wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavyHeavy = "WavyHeavy", + /** + * Underlining of text with double wavy lines. + * @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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + /** + * 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.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.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?: { + 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 vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. @@ -2102,123 +2419,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.SlideData; } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - 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] - */ - export 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; - /** - * 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 does not 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] - */ - 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 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.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; - } /** * Specifies the style for a line. @@ -2336,128 +2536,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } - /** - * Specifies the type of a shape. - * - * @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", - /** - * The shape is a geometric shape such as rectangle. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - geometricShape = "GeometricShape", - /** - * The shape is a group shape which contains sub-shapes. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - group = "Group", - /** - * The shape is a line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - line = "Line", - /** - * The shape is a table. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - table = "Table", - /** - * The shape is a callout. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - callout = "Callout", - /** - * The shape is a chart. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - chart = "Chart", - /** - * The shape is a content Office Add-in. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - contentApp = "ContentApp", - /** - * The shape is a diagram. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - diagram = "Diagram", - /** - * The shape is a freeform object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - freeform = "Freeform", - /** - * The shape is a graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - graphic = "Graphic", - /** - * The shape is an ink object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ink = "Ink", - /** - * The shape is a media object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - media = "Media", - /** - * The shape is a 3D model. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - model3D = "Model3D", - /** - * The shape is an OLE (Object Linking and Embedding) object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ole = "Ole", - /** - * The shape is a placeholder. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - placeholder = "Placeholder", - /** - * The shape is a SmartArt graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - smartArt = "SmartArt", - /** - * The shape is a text box. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - textBox = "TextBox", - } /** * Determines the type of automatic sizing allowed. * @@ -2488,86 +2566,36 @@ export declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.4] */ - autoSizeMixed = "AutoSizeMixed", - } - /** - * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - export 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; - /** - * Specifies if the bullets in the paragraph are visible. Returns 'null' if the 'TextRange' includes text fragments with different bullet visibility values. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - visible: boolean; - /** - * 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.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.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?: { - 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. - */ - toJSON(): PowerPoint.Interfaces.BulletFormatData; + autoSizeMixed = "AutoSizeMixed", } /** - * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. + * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. * * @remarks * [Api set: PowerPointApi 1.4] */ - export class ParagraphFormat extends OfficeExtension.ClientObject { + export 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; /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @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. + * Specifies if the bullets in the paragraph are visible. Returns 'null' if the 'TextRange' includes text fragments with different bullet visibility values. * * @remarks * [Api set: PowerPointApi 1.4] */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; + visible: boolean; /** * 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.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.ParagraphFormat; + 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. * @@ -2576,76 +2604,48 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ParagraphFormat; + }): 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.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.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.ParagraphFormatData; + toJSON(): PowerPoint.Interfaces.BulletFormatData; } /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. * * @remarks * [Api set: PowerPointApi 1.4] */ - export class ShapeFont extends OfficeExtension.ClientObject { + export 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; /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - size: number; + readonly bulletFormat: PowerPoint.BulletFormat; /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * 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] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; /** * 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.ShapeFontLoadOptions): PowerPoint.ShapeFont; + 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.ShapeFont; + 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. * @@ -2654,12 +2654,12 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ShapeFont; + }): 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.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. + * 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.ShapeFontData; + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. @@ -3218,6 +3218,68 @@ export declare namespace PowerPoint { export interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + export interface ShapeFillUpdateData { + /** + * 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 does not 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 `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + export interface ShapeFontUpdateData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ export interface ShapeCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3240,23 +3302,6 @@ export declare namespace PowerPoint { export interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - export interface ShapeFillUpdateData { - /** - * 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 does not 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 `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ export interface ShapeScopedCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3326,51 +3371,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - export interface ShapeFontUpdateData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ export interface TextRangeUpdateData { @@ -3532,6 +3532,75 @@ export declare namespace PowerPoint { export interface HyperlinkCollectionData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + export 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 does not 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()`. */ + export interface ShapeFontData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ export interface ShapeCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3605,30 +3674,6 @@ export declare namespace PowerPoint { */ id?: string; } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - export 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 does not 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 `shapeScopedCollection.toJSON()`. */ export interface ShapeScopedCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3698,51 +3743,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - export interface ShapeFontData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ export interface TextRangeData { @@ -3920,6 +3920,93 @@ export declare namespace PowerPoint { + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + export 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 does not 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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: boolean; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: boolean; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: boolean; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: boolean; + } /** * Represents the collection of shapes. * @@ -4165,39 +4252,6 @@ export declare namespace PowerPoint { */ id?: boolean; } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - export 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 does not 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 line formatting for the shape object. For images and geometric shapes, line formatting represents the border of the shape. @@ -4298,60 +4352,6 @@ export declare namespace PowerPoint { */ 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] - */ - export 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; - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - underline?: boolean; - } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. * diff --git a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_5/powerpoint.d.ts b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_5/powerpoint.d.ts index b018de1e5..7df3b96ee 100644 --- a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_5/powerpoint.d.ts +++ b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_5/powerpoint.d.ts @@ -171,6 +171,128 @@ export declare namespace PowerPoint { + /** + * Specifies the type of a shape. + * + * @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", + /** + * The shape is a geometric shape such as rectangle. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + geometricShape = "GeometricShape", + /** + * The shape is a group shape which contains sub-shapes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + group = "Group", + /** + * The shape is a line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + line = "Line", + /** + * The shape is a table. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + table = "Table", + /** + * The shape is a callout. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + callout = "Callout", + /** + * The shape is a chart. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + chart = "Chart", + /** + * The shape is a content Office Add-in. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + contentApp = "ContentApp", + /** + * The shape is a diagram. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + diagram = "Diagram", + /** + * The shape is a freeform object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + freeform = "Freeform", + /** + * The shape is a graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + graphic = "Graphic", + /** + * The shape is an ink object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ink = "Ink", + /** + * The shape is a media object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + media = "Media", + /** + * The shape is a 3D model. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + model3D = "Model3D", + /** + * The shape is an OLE (Object Linking and Embedding) object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ole = "Ole", + /** + * The shape is a placeholder. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + placeholder = "Placeholder", + /** + * The shape is a SmartArt graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + smartArt = "SmartArt", + /** + * The shape is a text box. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textBox = "TextBox", + } /** @@ -1392,164 +1514,359 @@ export declare namespace PowerPoint { systemDashDot = "SystemDashDot", } /** - * The type of underline applied to a font. + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ShapeFontUnderlineStyle { - /** - * No underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - none = "None", - /** - * Regular single line underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - single = "Single", - /** - * Underlining of text with double lines. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - double = "Double", - /** - * Underlining of text with a thick line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - heavy = "Heavy", + enum ParagraphHorizontalAlignment { /** - * Underlining of text with a dotted line. + * Align text to the left margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + left = "Left", /** - * Underlining of text with a thick, dotted line. + * Align text in the center. * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + center = "Center", /** - * Underlining of text with a line containing dashes. + * Align text to the right margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + right = "Right", /** - * Underlining of text with a thick line containing dashes. + * Align text so that it is justified across the whole line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + justify = "Justify", /** - * Underlining of text with a line containing long dashes. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + justifyLow = "JustifyLow", /** - * Underlining of text with a thick line containing long dashes. + * Distributes the text words across an entire text line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + distributed = "Distributed", /** - * Underlining of text with a line containing dots and dashes. + * Distributes Thai text specially, because each character is treated as a word. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + thaiDistributed = "ThaiDistributed", + } + /** + * Specifies a shape's fill type. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeFillType { /** - * Underlining of text with a thick line containing dots and dashes. + * Specifies that the shape should have no fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + noFill = "NoFill", /** - * Underlining of text with a line containing double dots and dashes. + * Specifies that the shape should have regular solid fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + solid = "Solid", /** - * Underlining of text with a thick line containing double dots and dashes. + * Specifies that the shape should have gradient fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + gradient = "Gradient", /** - * Underlining of text with a wavy line. + * Specifies that the shape should have pattern fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + pattern = "Pattern", /** - * Underlining of text with a thick, wavy line. + * Specifies that the shape should have picture or texture fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + pictureAndTexture = "PictureAndTexture", /** - * Underlining of text with double wavy lines. + * Specifies that the shape should have slide background fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", + slideBackground = "SlideBackground", } /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + * Represents the fill formatting of a shape object. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ParagraphHorizontalAlignment { + export 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; /** - * Align text to the left margin. + * 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] */ - left = "Left", + foregroundColor: string; /** - * Align text in the center. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type does not support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + transparency: number; /** - * Align text to the right margin. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; /** - * Align text so that it is justified across the whole line. + * Clears the fill formatting of this shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + clear(): void; /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * 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"). */ - justifyLow = "JustifyLow", + setSolidColor(color: string): void; /** - * Distributes the text words across an entire text line. - * @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. */ - distributed = "Distributed", + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** - * Distributes Thai text specially, because each character is treated as a word. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - thaiDistributed = "ThaiDistributed", + * 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 { + /** + * No underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + none = "None", + /** + * Regular single line underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + single = "Single", + /** + * Underlining of text with double lines. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + double = "Double", + /** + * Underlining of text with a thick line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + heavy = "Heavy", + /** + * Underlining of text with a dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotted = "Dotted", + /** + * Underlining of text with a thick, dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dottedHeavy = "DottedHeavy", + /** + * Underlining of text with a line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dash = "Dash", + /** + * Underlining of text with a thick line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashHeavy = "DashHeavy", + /** + * Underlining of text with a line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLong = "DashLong", + /** + * Underlining of text with a thick line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLongHeavy = "DashLongHeavy", + /** + * Underlining of text with a line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDash = "DotDash", + /** + * Underlining of text with a thick line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDashHeavy = "DotDashHeavy", + /** + * Underlining of text with a line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDash = "DotDotDash", + /** + * Underlining of text with a thick line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDashHeavy = "DotDotDashHeavy", + /** + * Underlining of text with a wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavy = "Wavy", + /** + * Underlining of text with a thick, wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavyHeavy = "WavyHeavy", + /** + * Underlining of text with double wavy lines. + * @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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + /** + * 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.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.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?: { + 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 vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. @@ -2153,123 +2470,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.SlideData; } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - 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] - */ - export 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; - /** - * 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 does not 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] - */ - 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 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.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; - } /** * Represents a collection of shapes. * @@ -2459,128 +2659,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } - /** - * Specifies the type of a shape. - * - * @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", - /** - * The shape is a geometric shape such as rectangle. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - geometricShape = "GeometricShape", - /** - * The shape is a group shape which contains sub-shapes. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - group = "Group", - /** - * The shape is a line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - line = "Line", - /** - * The shape is a table. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - table = "Table", - /** - * The shape is a callout. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - callout = "Callout", - /** - * The shape is a chart. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - chart = "Chart", - /** - * The shape is a content Office Add-in. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - contentApp = "ContentApp", - /** - * The shape is a diagram. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - diagram = "Diagram", - /** - * The shape is a freeform object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - freeform = "Freeform", - /** - * The shape is a graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - graphic = "Graphic", - /** - * The shape is an ink object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ink = "Ink", - /** - * The shape is a media object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - media = "Media", - /** - * The shape is a 3D model. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - model3D = "Model3D", - /** - * The shape is an OLE (Object Linking and Embedding) object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ole = "Ole", - /** - * The shape is a placeholder. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - placeholder = "Placeholder", - /** - * The shape is a SmartArt graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - smartArt = "SmartArt", - /** - * The shape is a text box. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - textBox = "TextBox", - } /** * Determines the type of automatic sizing allowed. * @@ -2611,86 +2689,36 @@ export declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.4] */ - autoSizeMixed = "AutoSizeMixed", - } - /** - * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - export 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; - /** - * Specifies if the bullets in the paragraph are visible. Returns 'null' if the 'TextRange' includes text fragments with different bullet visibility values. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - visible: boolean; - /** - * 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.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.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?: { - 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. - */ - toJSON(): PowerPoint.Interfaces.BulletFormatData; + autoSizeMixed = "AutoSizeMixed", } /** - * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. + * Represents the bullet formatting properties of a text that is attached to the {@link PowerPoint.ParagraphFormat}. * * @remarks * [Api set: PowerPointApi 1.4] */ - export class ParagraphFormat extends OfficeExtension.ClientObject { + export 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; /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @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. + * Specifies if the bullets in the paragraph are visible. Returns 'null' if the 'TextRange' includes text fragments with different bullet visibility values. * * @remarks * [Api set: PowerPointApi 1.4] */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; + visible: boolean; /** * 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.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.ParagraphFormat; + 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. * @@ -2699,76 +2727,48 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ParagraphFormat; + }): 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.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.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.ParagraphFormatData; + toJSON(): PowerPoint.Interfaces.BulletFormatData; } /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. * * @remarks * [Api set: PowerPointApi 1.4] */ - export class ShapeFont extends OfficeExtension.ClientObject { + export 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; /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - size: number; + readonly bulletFormat: PowerPoint.BulletFormat; /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * 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] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; /** * 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.ShapeFontLoadOptions): PowerPoint.ShapeFont; + 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.ShapeFont; + 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. * @@ -2777,12 +2777,12 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ShapeFont; + }): 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.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. + * 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.ShapeFontData; + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. @@ -3482,6 +3482,68 @@ export declare namespace PowerPoint { export interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + export interface ShapeFillUpdateData { + /** + * 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 does not 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 `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + export interface ShapeFontUpdateData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ export interface ShapeCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3504,23 +3566,6 @@ export declare namespace PowerPoint { export interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - export interface ShapeFillUpdateData { - /** - * 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 does not 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 `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ export interface ShapeScopedCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3590,51 +3635,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - export interface ShapeFontUpdateData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ export interface TextRangeUpdateData { /** @@ -3816,6 +3816,75 @@ export declare namespace PowerPoint { export interface HyperlinkCollectionData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + export 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 does not 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()`. */ + export interface ShapeFontData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ export interface ShapeCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3889,30 +3958,6 @@ export declare namespace PowerPoint { */ id?: string; } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - export 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 does not 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 `shapeScopedCollection.toJSON()`. */ export interface ShapeScopedCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3982,51 +4027,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - export interface ShapeFontData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ export interface TextRangeData { /** @@ -4224,6 +4224,93 @@ export declare namespace PowerPoint { + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + export 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 does not 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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: boolean; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: boolean; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: boolean; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: boolean; + } /** * Represents the collection of shapes. * @@ -4469,39 +4556,6 @@ export declare namespace PowerPoint { */ id?: boolean; } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - export 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 does not 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 a collection of shapes. * @@ -4683,60 +4737,6 @@ export declare namespace PowerPoint { */ 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] - */ - export 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; - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - underline?: boolean; - } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. * diff --git a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_6/powerpoint.d.ts b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_6/powerpoint.d.ts index 0e52de36c..e7a436a0b 100644 --- a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_6/powerpoint.d.ts +++ b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_6/powerpoint.d.ts @@ -171,6 +171,128 @@ export declare namespace PowerPoint { + /** + * Specifies the type of a shape. + * + * @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", + /** + * The shape is a geometric shape such as rectangle. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + geometricShape = "GeometricShape", + /** + * The shape is a group shape which contains sub-shapes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + group = "Group", + /** + * The shape is a line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + line = "Line", + /** + * The shape is a table. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + table = "Table", + /** + * The shape is a callout. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + callout = "Callout", + /** + * The shape is a chart. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + chart = "Chart", + /** + * The shape is a content Office Add-in. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + contentApp = "ContentApp", + /** + * The shape is a diagram. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + diagram = "Diagram", + /** + * The shape is a freeform object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + freeform = "Freeform", + /** + * The shape is a graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + graphic = "Graphic", + /** + * The shape is an ink object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ink = "Ink", + /** + * The shape is a media object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + media = "Media", + /** + * The shape is a 3D model. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + model3D = "Model3D", + /** + * The shape is an OLE (Object Linking and Embedding) object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ole = "Ole", + /** + * The shape is a placeholder. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + placeholder = "Placeholder", + /** + * The shape is a SmartArt graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + smartArt = "SmartArt", + /** + * The shape is a text box. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textBox = "TextBox", + } /** * Represents a single hyperlink. * @@ -1493,164 +1615,359 @@ export declare namespace PowerPoint { systemDashDot = "SystemDashDot", } /** - * The type of underline applied to a font. + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ShapeFontUnderlineStyle { - /** - * No underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - none = "None", - /** - * Regular single line underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - single = "Single", - /** - * Underlining of text with double lines. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - double = "Double", - /** - * Underlining of text with a thick line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - heavy = "Heavy", + enum ParagraphHorizontalAlignment { /** - * Underlining of text with a dotted line. + * Align text to the left margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + left = "Left", /** - * Underlining of text with a thick, dotted line. + * Align text in the center. * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + center = "Center", /** - * Underlining of text with a line containing dashes. + * Align text to the right margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + right = "Right", /** - * Underlining of text with a thick line containing dashes. + * Align text so that it is justified across the whole line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + justify = "Justify", /** - * Underlining of text with a line containing long dashes. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + justifyLow = "JustifyLow", /** - * Underlining of text with a thick line containing long dashes. + * Distributes the text words across an entire text line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + distributed = "Distributed", /** - * Underlining of text with a line containing dots and dashes. + * Distributes Thai text specially, because each character is treated as a word. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + thaiDistributed = "ThaiDistributed", + } + /** + * Specifies a shape's fill type. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeFillType { /** - * Underlining of text with a thick line containing dots and dashes. + * Specifies that the shape should have no fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + noFill = "NoFill", /** - * Underlining of text with a line containing double dots and dashes. + * Specifies that the shape should have regular solid fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + solid = "Solid", /** - * Underlining of text with a thick line containing double dots and dashes. + * Specifies that the shape should have gradient fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + gradient = "Gradient", /** - * Underlining of text with a wavy line. + * Specifies that the shape should have pattern fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + pattern = "Pattern", /** - * Underlining of text with a thick, wavy line. + * Specifies that the shape should have picture or texture fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + pictureAndTexture = "PictureAndTexture", /** - * Underlining of text with double wavy lines. + * Specifies that the shape should have slide background fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", + slideBackground = "SlideBackground", } /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + * Represents the fill formatting of a shape object. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ParagraphHorizontalAlignment { + export 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; /** - * Align text to the left margin. + * 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] */ - left = "Left", + foregroundColor: string; /** - * Align text in the center. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type does not support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + transparency: number; /** - * Align text to the right margin. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; /** - * Align text so that it is justified across the whole line. + * Clears the fill formatting of this shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + clear(): void; /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * 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"). */ - justifyLow = "JustifyLow", + setSolidColor(color: string): void; /** - * Distributes the text words across an entire text line. - * @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. */ - distributed = "Distributed", + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** - * Distributes Thai text specially, because each character is treated as a word. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - thaiDistributed = "ThaiDistributed", + * 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 { + /** + * No underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + none = "None", + /** + * Regular single line underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + single = "Single", + /** + * Underlining of text with double lines. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + double = "Double", + /** + * Underlining of text with a thick line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + heavy = "Heavy", + /** + * Underlining of text with a dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotted = "Dotted", + /** + * Underlining of text with a thick, dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dottedHeavy = "DottedHeavy", + /** + * Underlining of text with a line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dash = "Dash", + /** + * Underlining of text with a thick line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashHeavy = "DashHeavy", + /** + * Underlining of text with a line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLong = "DashLong", + /** + * Underlining of text with a thick line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLongHeavy = "DashLongHeavy", + /** + * Underlining of text with a line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDash = "DotDash", + /** + * Underlining of text with a thick line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDashHeavy = "DotDashHeavy", + /** + * Underlining of text with a line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDash = "DotDotDash", + /** + * Underlining of text with a thick line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDashHeavy = "DotDotDashHeavy", + /** + * Underlining of text with a wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavy = "Wavy", + /** + * Underlining of text with a thick, wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavyHeavy = "WavyHeavy", + /** + * Underlining of text with double wavy lines. + * @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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + /** + * 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.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.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?: { + 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 vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. @@ -2260,123 +2577,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.SlideData; } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - 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] - */ - export 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; - /** - * 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 does not 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] - */ - 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 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.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; - } /** * Represents a collection of shapes. * @@ -2566,128 +2766,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } - /** - * Specifies the type of a shape. - * - * @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", - /** - * The shape is a geometric shape such as rectangle. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - geometricShape = "GeometricShape", - /** - * The shape is a group shape which contains sub-shapes. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - group = "Group", - /** - * The shape is a line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - line = "Line", - /** - * The shape is a table. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - table = "Table", - /** - * The shape is a callout. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - callout = "Callout", - /** - * The shape is a chart. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - chart = "Chart", - /** - * The shape is a content Office Add-in. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - contentApp = "ContentApp", - /** - * The shape is a diagram. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - diagram = "Diagram", - /** - * The shape is a freeform object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - freeform = "Freeform", - /** - * The shape is a graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - graphic = "Graphic", - /** - * The shape is an ink object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ink = "Ink", - /** - * The shape is a media object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - media = "Media", - /** - * The shape is a 3D model. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - model3D = "Model3D", - /** - * The shape is an OLE (Object Linking and Embedding) object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ole = "Ole", - /** - * The shape is a placeholder. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - placeholder = "Placeholder", - /** - * The shape is a SmartArt graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - smartArt = "SmartArt", - /** - * The shape is a text box. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - textBox = "TextBox", - } /** * Determines the type of automatic sizing allowed. * @@ -2735,69 +2813,19 @@ export declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.4] */ - visible: boolean; - /** - * 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.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.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?: { - 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. - */ - 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] - */ - export 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; - /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @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. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; + visible: boolean; /** * 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.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.ParagraphFormat; + 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. * @@ -2806,76 +2834,48 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ParagraphFormat; + }): 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.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.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.ParagraphFormatData; + toJSON(): PowerPoint.Interfaces.BulletFormatData; } /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. * * @remarks * [Api set: PowerPointApi 1.4] */ - export class ShapeFont extends OfficeExtension.ClientObject { + export 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; /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - size: number; + readonly bulletFormat: PowerPoint.BulletFormat; /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * 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] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; /** * 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.ShapeFontLoadOptions): PowerPoint.ShapeFont; + 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.ShapeFont; + 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. * @@ -2884,12 +2884,12 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ShapeFont; + }): 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.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. + * 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.ShapeFontData; + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. @@ -3601,6 +3601,68 @@ export declare namespace PowerPoint { export interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + export interface ShapeFillUpdateData { + /** + * 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 does not 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 `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + export interface ShapeFontUpdateData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ export interface ShapeCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3623,23 +3685,6 @@ export declare namespace PowerPoint { export interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - export interface ShapeFillUpdateData { - /** - * 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 does not 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 `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ export interface ShapeScopedCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -3709,51 +3754,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - export interface ShapeFontUpdateData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ export interface TextRangeUpdateData { /** @@ -3934,18 +3934,87 @@ export declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.6] */ - address?: string; + 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()`. */ + export interface HyperlinkCollectionData { + items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + export 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 does not 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()`. */ + export interface ShapeFontData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; /** - * Specifies the string displayed when hovering over the hyperlink. + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.4] */ - screenTip?: string; - } - /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ - export interface HyperlinkCollectionData { - items?: PowerPoint.Interfaces.HyperlinkData[]; + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ export interface ShapeCollectionData { @@ -4020,30 +4089,6 @@ export declare namespace PowerPoint { */ id?: string; } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - export 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 does not 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 `shapeScopedCollection.toJSON()`. */ export interface ShapeScopedCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -4113,51 +4158,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - export interface ShapeFontData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ export interface TextRangeData { /** @@ -4405,6 +4405,93 @@ export declare namespace PowerPoint { */ screenTip?: boolean; } + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + export 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 does not 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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: boolean; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: boolean; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: boolean; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: boolean; + } /** * Represents the collection of shapes. * @@ -4650,39 +4737,6 @@ export declare namespace PowerPoint { */ id?: boolean; } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - export 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 does not 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 a collection of shapes. * @@ -4864,60 +4918,6 @@ export declare namespace PowerPoint { */ 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] - */ - export 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; - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - underline?: boolean; - } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. * diff --git a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_7/powerpoint.d.ts b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_7/powerpoint.d.ts index 84d2e4adf..ef4d37e10 100644 --- a/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_7/powerpoint.d.ts +++ b/generate-docs/api-extractor-inputs-powerpoint-release/PowerPoint_1_7/powerpoint.d.ts @@ -415,6 +415,128 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.CustomXmlPartCollectionData; } + /** + * Specifies the type of a shape. + * + * @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", + /** + * The shape is a geometric shape such as rectangle. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + geometricShape = "GeometricShape", + /** + * The shape is a group shape which contains sub-shapes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + group = "Group", + /** + * The shape is a line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + line = "Line", + /** + * The shape is a table. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + table = "Table", + /** + * The shape is a callout. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + callout = "Callout", + /** + * The shape is a chart. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + chart = "Chart", + /** + * The shape is a content Office Add-in. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + contentApp = "ContentApp", + /** + * The shape is a diagram. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + diagram = "Diagram", + /** + * The shape is a freeform object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + freeform = "Freeform", + /** + * The shape is a graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + graphic = "Graphic", + /** + * The shape is an ink object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ink = "Ink", + /** + * The shape is a media object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + media = "Media", + /** + * The shape is a 3D model. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + model3D = "Model3D", + /** + * The shape is an OLE (Object Linking and Embedding) object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ole = "Ole", + /** + * The shape is a placeholder. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + placeholder = "Placeholder", + /** + * The shape is a SmartArt graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + smartArt = "SmartArt", + /** + * The shape is a text box. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textBox = "TextBox", + } /** * Represents a single hyperlink. * @@ -1737,164 +1859,359 @@ export declare namespace PowerPoint { systemDashDot = "SystemDashDot", } /** - * The type of underline applied to a font. + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ShapeFontUnderlineStyle { - /** - * No underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - none = "None", - /** - * Regular single line underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - single = "Single", - /** - * Underlining of text with double lines. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - double = "Double", - /** - * Underlining of text with a thick line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - heavy = "Heavy", + enum ParagraphHorizontalAlignment { /** - * Underlining of text with a dotted line. + * Align text to the left margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + left = "Left", /** - * Underlining of text with a thick, dotted line. + * Align text in the center. * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + center = "Center", /** - * Underlining of text with a line containing dashes. + * Align text to the right margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + right = "Right", /** - * Underlining of text with a thick line containing dashes. + * Align text so that it is justified across the whole line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + justify = "Justify", /** - * Underlining of text with a line containing long dashes. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + justifyLow = "JustifyLow", /** - * Underlining of text with a thick line containing long dashes. + * Distributes the text words across an entire text line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + distributed = "Distributed", /** - * Underlining of text with a line containing dots and dashes. + * Distributes Thai text specially, because each character is treated as a word. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + thaiDistributed = "ThaiDistributed", + } + /** + * Specifies a shape's fill type. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeFillType { /** - * Underlining of text with a thick line containing dots and dashes. + * Specifies that the shape should have no fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + noFill = "NoFill", /** - * Underlining of text with a line containing double dots and dashes. + * Specifies that the shape should have regular solid fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + solid = "Solid", /** - * Underlining of text with a thick line containing double dots and dashes. + * Specifies that the shape should have gradient fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + gradient = "Gradient", /** - * Underlining of text with a wavy line. + * Specifies that the shape should have pattern fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + pattern = "Pattern", /** - * Underlining of text with a thick, wavy line. + * Specifies that the shape should have picture or texture fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + pictureAndTexture = "PictureAndTexture", /** - * Underlining of text with double wavy lines. + * Specifies that the shape should have slide background fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", + slideBackground = "SlideBackground", } /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + * Represents the fill formatting of a shape object. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ParagraphHorizontalAlignment { + export 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; /** - * Align text to the left margin. + * 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] */ - left = "Left", + foregroundColor: string; /** - * Align text in the center. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type does not support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + transparency: number; /** - * Align text to the right margin. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; /** - * Align text so that it is justified across the whole line. + * Clears the fill formatting of this shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + clear(): void; /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * 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"). */ - justifyLow = "JustifyLow", + setSolidColor(color: string): void; /** - * Distributes the text words across an entire text line. - * @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. */ - distributed = "Distributed", + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** - * Distributes Thai text specially, because each character is treated as a word. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - thaiDistributed = "ThaiDistributed", + * 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 { + /** + * No underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + none = "None", + /** + * Regular single line underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + single = "Single", + /** + * Underlining of text with double lines. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + double = "Double", + /** + * Underlining of text with a thick line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + heavy = "Heavy", + /** + * Underlining of text with a dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotted = "Dotted", + /** + * Underlining of text with a thick, dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dottedHeavy = "DottedHeavy", + /** + * Underlining of text with a line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dash = "Dash", + /** + * Underlining of text with a thick line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashHeavy = "DashHeavy", + /** + * Underlining of text with a line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLong = "DashLong", + /** + * Underlining of text with a thick line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLongHeavy = "DashLongHeavy", + /** + * Underlining of text with a line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDash = "DotDash", + /** + * Underlining of text with a thick line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDashHeavy = "DotDashHeavy", + /** + * Underlining of text with a line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDash = "DotDotDash", + /** + * Underlining of text with a thick line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDashHeavy = "DotDotDashHeavy", + /** + * Underlining of text with a wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavy = "Wavy", + /** + * Underlining of text with a thick, wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavyHeavy = "WavyHeavy", + /** + * Underlining of text with double wavy lines. + * @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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + /** + * 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.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.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?: { + 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 vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. @@ -2522,123 +2839,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.SlideData; } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - 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] - */ - export 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; - /** - * 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 does not 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] - */ - 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 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.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; - } /** * Represents a collection of shapes. * @@ -2828,128 +3028,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } - /** - * Specifies the type of a shape. - * - * @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", - /** - * The shape is a geometric shape such as rectangle. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - geometricShape = "GeometricShape", - /** - * The shape is a group shape which contains sub-shapes. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - group = "Group", - /** - * The shape is a line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - line = "Line", - /** - * The shape is a table. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - table = "Table", - /** - * The shape is a callout. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - callout = "Callout", - /** - * The shape is a chart. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - chart = "Chart", - /** - * The shape is a content Office Add-in. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - contentApp = "ContentApp", - /** - * The shape is a diagram. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - diagram = "Diagram", - /** - * The shape is a freeform object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - freeform = "Freeform", - /** - * The shape is a graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - graphic = "Graphic", - /** - * The shape is an ink object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ink = "Ink", - /** - * The shape is a media object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - media = "Media", - /** - * The shape is a 3D model. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - model3D = "Model3D", - /** - * The shape is an OLE (Object Linking and Embedding) object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ole = "Ole", - /** - * The shape is a placeholder. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - placeholder = "Placeholder", - /** - * The shape is a SmartArt graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - smartArt = "SmartArt", - /** - * The shape is a text box. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - textBox = "TextBox", - } /** * Determines the type of automatic sizing allowed. * @@ -2997,69 +3075,19 @@ export declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.4] */ - visible: boolean; - /** - * 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.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.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?: { - 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. - */ - 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] - */ - export 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; - /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @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. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; + visible: boolean; /** * 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.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.ParagraphFormat; + 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. * @@ -3068,76 +3096,48 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ParagraphFormat; + }): 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.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.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.ParagraphFormatData; + toJSON(): PowerPoint.Interfaces.BulletFormatData; } /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. * * @remarks * [Api set: PowerPointApi 1.4] */ - export class ShapeFont extends OfficeExtension.ClientObject { + export 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; /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - size: number; + readonly bulletFormat: PowerPoint.BulletFormat; /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * 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] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; /** * 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.ShapeFontLoadOptions): PowerPoint.ShapeFont; + 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.ShapeFont; + 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. * @@ -3146,12 +3146,12 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ShapeFont; + }): 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.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. + * 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.ShapeFontData; + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. @@ -4166,6 +4166,68 @@ export declare namespace PowerPoint { export interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + export interface ShapeFillUpdateData { + /** + * 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 does not 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 `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + export interface ShapeFontUpdateData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ export interface ShapeCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -4188,23 +4250,6 @@ export declare namespace PowerPoint { export interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - export interface ShapeFillUpdateData { - /** - * 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 does not 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 `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ export interface ShapeScopedCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -4274,51 +4319,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - export interface ShapeFontUpdateData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ export interface TextRangeUpdateData { /** @@ -4572,18 +4572,87 @@ export declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.6] */ - address?: string; + 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()`. */ + export interface HyperlinkCollectionData { + items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + export 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 does not 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()`. */ + export interface ShapeFontData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; /** - * Specifies the string displayed when hovering over the hyperlink. + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.4] */ - screenTip?: string; - } - /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ - export interface HyperlinkCollectionData { - items?: PowerPoint.Interfaces.HyperlinkData[]; + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ export interface ShapeCollectionData { @@ -4658,30 +4727,6 @@ export declare namespace PowerPoint { */ id?: string; } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - export 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 does not 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 `shapeScopedCollection.toJSON()`. */ export interface ShapeScopedCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -4751,51 +4796,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - export interface ShapeFontData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ export interface TextRangeData { /** @@ -5211,6 +5211,93 @@ export declare namespace PowerPoint { */ screenTip?: boolean; } + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + export 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 does not 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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: boolean; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: boolean; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: boolean; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: boolean; + } /** * Represents the collection of shapes. * @@ -5456,39 +5543,6 @@ export declare namespace PowerPoint { */ id?: boolean; } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - export 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 does not 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 a collection of shapes. * @@ -5670,60 +5724,6 @@ export declare namespace PowerPoint { */ 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] - */ - export 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; - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - underline?: boolean; - } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. * diff --git a/generate-docs/api-extractor-inputs-powerpoint/powerpoint.d.ts b/generate-docs/api-extractor-inputs-powerpoint/powerpoint.d.ts index 5d7b0e7d7..3e43df42e 100644 --- a/generate-docs/api-extractor-inputs-powerpoint/powerpoint.d.ts +++ b/generate-docs/api-extractor-inputs-powerpoint/powerpoint.d.ts @@ -415,6 +415,128 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.CustomXmlPartCollectionData; } + /** + * Specifies the type of a shape. + * + * @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", + /** + * The shape is a geometric shape such as rectangle. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + geometricShape = "GeometricShape", + /** + * The shape is a group shape which contains sub-shapes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + group = "Group", + /** + * The shape is a line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + line = "Line", + /** + * The shape is a table. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + table = "Table", + /** + * The shape is a callout. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + callout = "Callout", + /** + * The shape is a chart. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + chart = "Chart", + /** + * The shape is a content Office Add-in. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + contentApp = "ContentApp", + /** + * The shape is a diagram. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + diagram = "Diagram", + /** + * The shape is a freeform object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + freeform = "Freeform", + /** + * The shape is a graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + graphic = "Graphic", + /** + * The shape is an ink object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ink = "Ink", + /** + * The shape is a media object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + media = "Media", + /** + * The shape is a 3D model. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + model3D = "Model3D", + /** + * The shape is an OLE (Object Linking and Embedding) object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ole = "Ole", + /** + * The shape is a placeholder. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + placeholder = "Placeholder", + /** + * The shape is a SmartArt graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + smartArt = "SmartArt", + /** + * The shape is a text box. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textBox = "TextBox", + } /** * Represents a single hyperlink. * @@ -1737,164 +1859,359 @@ export declare namespace PowerPoint { systemDashDot = "SystemDashDot", } /** - * The type of underline applied to a font. + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ShapeFontUnderlineStyle { - /** - * No underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - none = "None", - /** - * Regular single line underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - single = "Single", - /** - * Underlining of text with double lines. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - double = "Double", - /** - * Underlining of text with a thick line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - heavy = "Heavy", + enum ParagraphHorizontalAlignment { /** - * Underlining of text with a dotted line. + * Align text to the left margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + left = "Left", /** - * Underlining of text with a thick, dotted line. + * Align text in the center. * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + center = "Center", /** - * Underlining of text with a line containing dashes. + * Align text to the right margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + right = "Right", /** - * Underlining of text with a thick line containing dashes. + * Align text so that it is justified across the whole line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + justify = "Justify", /** - * Underlining of text with a line containing long dashes. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + justifyLow = "JustifyLow", /** - * Underlining of text with a thick line containing long dashes. + * Distributes the text words across an entire text line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + distributed = "Distributed", /** - * Underlining of text with a line containing dots and dashes. + * Distributes Thai text specially, because each character is treated as a word. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + thaiDistributed = "ThaiDistributed", + } + /** + * Specifies a shape's fill type. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeFillType { /** - * Underlining of text with a thick line containing dots and dashes. + * Specifies that the shape should have no fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + noFill = "NoFill", /** - * Underlining of text with a line containing double dots and dashes. + * Specifies that the shape should have regular solid fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + solid = "Solid", /** - * Underlining of text with a thick line containing double dots and dashes. + * Specifies that the shape should have gradient fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + gradient = "Gradient", /** - * Underlining of text with a wavy line. + * Specifies that the shape should have pattern fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + pattern = "Pattern", /** - * Underlining of text with a thick, wavy line. + * Specifies that the shape should have picture or texture fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + pictureAndTexture = "PictureAndTexture", /** - * Underlining of text with double wavy lines. + * Specifies that the shape should have slide background fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", + slideBackground = "SlideBackground", } /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + * Represents the fill formatting of a shape object. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ParagraphHorizontalAlignment { + export 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; /** - * Align text to the left margin. + * 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] */ - left = "Left", + foregroundColor: string; /** - * Align text in the center. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type does not support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + transparency: number; /** - * Align text to the right margin. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; /** - * Align text so that it is justified across the whole line. + * Clears the fill formatting of this shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + clear(): void; /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * 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"). */ - justifyLow = "JustifyLow", + setSolidColor(color: string): void; /** - * Distributes the text words across an entire text line. - * @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. */ - distributed = "Distributed", + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** - * Distributes Thai text specially, because each character is treated as a word. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - thaiDistributed = "ThaiDistributed", + * 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 { + /** + * No underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + none = "None", + /** + * Regular single line underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + single = "Single", + /** + * Underlining of text with double lines. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + double = "Double", + /** + * Underlining of text with a thick line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + heavy = "Heavy", + /** + * Underlining of text with a dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotted = "Dotted", + /** + * Underlining of text with a thick, dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dottedHeavy = "DottedHeavy", + /** + * Underlining of text with a line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dash = "Dash", + /** + * Underlining of text with a thick line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashHeavy = "DashHeavy", + /** + * Underlining of text with a line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLong = "DashLong", + /** + * Underlining of text with a thick line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLongHeavy = "DashLongHeavy", + /** + * Underlining of text with a line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDash = "DotDash", + /** + * Underlining of text with a thick line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDashHeavy = "DotDashHeavy", + /** + * Underlining of text with a line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDash = "DotDotDash", + /** + * Underlining of text with a thick line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDashHeavy = "DotDotDashHeavy", + /** + * Underlining of text with a wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavy = "Wavy", + /** + * Underlining of text with a thick, wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavyHeavy = "WavyHeavy", + /** + * Underlining of text with double wavy lines. + * @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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + /** + * 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.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.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?: { + 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 vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. @@ -2883,123 +3200,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.SlideData; } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - 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] - */ - export 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; - /** - * 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 does not 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] - */ - 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 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.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; - } /** * Represents a collection of shapes. * @@ -3268,128 +3468,6 @@ export declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } - /** - * Specifies the type of a shape. - * - * @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", - /** - * The shape is a geometric shape such as rectangle. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - geometricShape = "GeometricShape", - /** - * The shape is a group shape which contains sub-shapes. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - group = "Group", - /** - * The shape is a line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - line = "Line", - /** - * The shape is a table. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - table = "Table", - /** - * The shape is a callout. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - callout = "Callout", - /** - * The shape is a chart. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - chart = "Chart", - /** - * The shape is a content Office Add-in. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - contentApp = "ContentApp", - /** - * The shape is a diagram. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - diagram = "Diagram", - /** - * The shape is a freeform object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - freeform = "Freeform", - /** - * The shape is a graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - graphic = "Graphic", - /** - * The shape is an ink object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ink = "Ink", - /** - * The shape is a media object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - media = "Media", - /** - * The shape is a 3D model. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - model3D = "Model3D", - /** - * The shape is an OLE (Object Linking and Embedding) object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ole = "Ole", - /** - * The shape is a placeholder. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - placeholder = "Placeholder", - /** - * The shape is a SmartArt graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - smartArt = "SmartArt", - /** - * The shape is a text box. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - textBox = "TextBox", - } /** * Determines the type of automatic sizing allowed. * @@ -3437,69 +3515,19 @@ export declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.4] */ - visible: boolean; - /** - * 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.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.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?: { - 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. - */ - 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] - */ - export 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; - /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @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. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; + visible: boolean; /** * 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.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.ParagraphFormat; + 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. * @@ -3508,76 +3536,48 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ParagraphFormat; + }): 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.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.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.ParagraphFormatData; + toJSON(): PowerPoint.Interfaces.BulletFormatData; } /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. * * @remarks * [Api set: PowerPointApi 1.4] */ - export class ShapeFont extends OfficeExtension.ClientObject { + export 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; /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - size: number; + readonly bulletFormat: PowerPoint.BulletFormat; /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * 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] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; /** * 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.ShapeFontLoadOptions): PowerPoint.ShapeFont; + 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.ShapeFont; + 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. * @@ -3586,12 +3586,12 @@ export declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ShapeFont; + }): 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.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. + * 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.ShapeFontData; + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. @@ -4638,6 +4638,68 @@ export declare namespace PowerPoint { export interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + export interface ShapeFillUpdateData { + /** + * 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 does not 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 `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + export interface ShapeFontUpdateData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ export interface ShapeCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -4660,23 +4722,6 @@ export declare namespace PowerPoint { export interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - export interface ShapeFillUpdateData { - /** - * 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 does not 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 `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ export interface ShapeScopedCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -4746,51 +4791,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - export interface ShapeFontUpdateData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ export interface TextRangeUpdateData { /** @@ -5044,18 +5044,87 @@ export declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.6] */ - address?: string; + 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()`. */ + export interface HyperlinkCollectionData { + items?: PowerPoint.Interfaces.HyperlinkData[]; + } + /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ + export 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 does not 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()`. */ + export interface ShapeFontData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; /** - * Specifies the string displayed when hovering over the hyperlink. + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.4] */ - screenTip?: string; - } - /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ - export interface HyperlinkCollectionData { - items?: PowerPoint.Interfaces.HyperlinkData[]; + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ export interface ShapeCollectionData { @@ -5146,30 +5215,6 @@ export declare namespace PowerPoint { */ index?: number; } - /** An interface describing the data returned by calling `shapeFill.toJSON()`. */ - export 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 does not 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 `shapeScopedCollection.toJSON()`. */ export interface ShapeScopedCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -5250,51 +5295,6 @@ export declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - export interface ShapeFontData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ export interface TextRangeData { /** @@ -5724,6 +5724,93 @@ export declare namespace PowerPoint { */ screenTip?: boolean; } + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + export 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 does not 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] + */ + export 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: boolean; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: boolean; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: boolean; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: boolean; + } /** * Represents the collection of shapes. * @@ -6025,39 +6112,6 @@ export declare namespace PowerPoint { */ index?: boolean; } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - export 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 does not 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 a collection of shapes. * @@ -6300,60 +6354,6 @@ export declare namespace PowerPoint { */ 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] - */ - export 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; - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - underline?: boolean; - } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. * diff --git a/generate-docs/script-inputs/office.d.ts b/generate-docs/script-inputs/office.d.ts index 9f4e0e463..bb26d07ea 100644 --- a/generate-docs/script-inputs/office.d.ts +++ b/generate-docs/script-inputs/office.d.ts @@ -117817,6 +117817,128 @@ declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.CustomXmlPartCollectionData; } + /** + * Specifies the type of a shape. + * + * @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", + /** + * The shape is a geometric shape such as rectangle. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + geometricShape = "GeometricShape", + /** + * The shape is a group shape which contains sub-shapes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + group = "Group", + /** + * The shape is a line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + line = "Line", + /** + * The shape is a table. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + table = "Table", + /** + * The shape is a callout. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + callout = "Callout", + /** + * The shape is a chart. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + chart = "Chart", + /** + * The shape is a content Office Add-in. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + contentApp = "ContentApp", + /** + * The shape is a diagram. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + diagram = "Diagram", + /** + * The shape is a freeform object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + freeform = "Freeform", + /** + * The shape is a graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + graphic = "Graphic", + /** + * The shape is an ink object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ink = "Ink", + /** + * The shape is a media object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + media = "Media", + /** + * The shape is a 3D model. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + model3D = "Model3D", + /** + * The shape is an OLE (Object Linking and Embedding) object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ole = "Ole", + /** + * The shape is a placeholder. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + placeholder = "Placeholder", + /** + * The shape is a SmartArt graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + smartArt = "SmartArt", + /** + * The shape is a text box. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textBox = "TextBox", + } /** * Represents a single hyperlink. * @@ -119139,164 +119261,359 @@ declare namespace PowerPoint { systemDashDot = "SystemDashDot", } /** - * The type of underline applied to a font. + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ShapeFontUnderlineStyle { - /** - * No underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - none = "None", - /** - * Regular single line underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - single = "Single", - /** - * Underlining of text with double lines. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - double = "Double", - /** - * Underlining of text with a thick line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - heavy = "Heavy", + enum ParagraphHorizontalAlignment { /** - * Underlining of text with a dotted line. + * Align text to the left margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + left = "Left", /** - * Underlining of text with a thick, dotted line. + * Align text in the center. * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + center = "Center", /** - * Underlining of text with a line containing dashes. + * Align text to the right margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + right = "Right", /** - * Underlining of text with a thick line containing dashes. + * Align text so that it is justified across the whole line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + justify = "Justify", /** - * Underlining of text with a line containing long dashes. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + justifyLow = "JustifyLow", /** - * Underlining of text with a thick line containing long dashes. + * Distributes the text words across an entire text line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + distributed = "Distributed", /** - * Underlining of text with a line containing dots and dashes. + * Distributes Thai text specially, because each character is treated as a word. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + thaiDistributed = "ThaiDistributed", + } + /** + * Specifies a shape's fill type. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeFillType { /** - * Underlining of text with a thick line containing dots and dashes. + * Specifies that the shape should have no fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + noFill = "NoFill", /** - * Underlining of text with a line containing double dots and dashes. + * Specifies that the shape should have regular solid fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + solid = "Solid", /** - * Underlining of text with a thick line containing double dots and dashes. + * Specifies that the shape should have gradient fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + gradient = "Gradient", /** - * Underlining of text with a wavy line. + * Specifies that the shape should have pattern fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + pattern = "Pattern", /** - * Underlining of text with a thick, wavy line. + * Specifies that the shape should have picture or texture fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + pictureAndTexture = "PictureAndTexture", /** - * Underlining of text with double wavy lines. + * Specifies that the shape should have slide background fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", + slideBackground = "SlideBackground", } /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + * Represents the fill formatting of a shape object. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ParagraphHorizontalAlignment { + 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; /** - * Align text to the left margin. + * 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] */ - left = "Left", + foregroundColor: string; /** - * Align text in the center. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type does not support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + transparency: number; /** - * Align text to the right margin. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; /** - * Align text so that it is justified across the whole line. + * Clears the fill formatting of this shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + clear(): void; /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * 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"). */ - justifyLow = "JustifyLow", + setSolidColor(color: string): void; /** - * Distributes the text words across an entire text line. - * @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. */ - distributed = "Distributed", + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** - * Distributes Thai text specially, because each character is treated as a word. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - thaiDistributed = "ThaiDistributed", + * 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 { + /** + * No underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + none = "None", + /** + * Regular single line underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + single = "Single", + /** + * Underlining of text with double lines. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + double = "Double", + /** + * Underlining of text with a thick line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + heavy = "Heavy", + /** + * Underlining of text with a dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotted = "Dotted", + /** + * Underlining of text with a thick, dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dottedHeavy = "DottedHeavy", + /** + * Underlining of text with a line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dash = "Dash", + /** + * Underlining of text with a thick line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashHeavy = "DashHeavy", + /** + * Underlining of text with a line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLong = "DashLong", + /** + * Underlining of text with a thick line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLongHeavy = "DashLongHeavy", + /** + * Underlining of text with a line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDash = "DotDash", + /** + * Underlining of text with a thick line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDashHeavy = "DotDashHeavy", + /** + * Underlining of text with a line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDash = "DotDotDash", + /** + * Underlining of text with a thick line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDashHeavy = "DotDotDashHeavy", + /** + * Underlining of text with a wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavy = "Wavy", + /** + * Underlining of text with a thick, wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavyHeavy = "WavyHeavy", + /** + * Underlining of text with double wavy lines. + * @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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + /** + * 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.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.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?: { + 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 vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. @@ -119924,123 +120241,6 @@ declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.SlideData; } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - 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; - /** - * 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 does not 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] - */ - 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 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.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; - } /** * Represents a collection of shapes. * @@ -120230,128 +120430,6 @@ declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } - /** - * Specifies the type of a shape. - * - * @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", - /** - * The shape is a geometric shape such as rectangle. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - geometricShape = "GeometricShape", - /** - * The shape is a group shape which contains sub-shapes. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - group = "Group", - /** - * The shape is a line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - line = "Line", - /** - * The shape is a table. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - table = "Table", - /** - * The shape is a callout. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - callout = "Callout", - /** - * The shape is a chart. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - chart = "Chart", - /** - * The shape is a content Office Add-in. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - contentApp = "ContentApp", - /** - * The shape is a diagram. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - diagram = "Diagram", - /** - * The shape is a freeform object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - freeform = "Freeform", - /** - * The shape is a graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - graphic = "Graphic", - /** - * The shape is an ink object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ink = "Ink", - /** - * The shape is a media object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - media = "Media", - /** - * The shape is a 3D model. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - model3D = "Model3D", - /** - * The shape is an OLE (Object Linking and Embedding) object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ole = "Ole", - /** - * The shape is a placeholder. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - placeholder = "Placeholder", - /** - * The shape is a SmartArt graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - smartArt = "SmartArt", - /** - * The shape is a text box. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - textBox = "TextBox", - } /** * Determines the type of automatic sizing allowed. * @@ -120399,69 +120477,19 @@ declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.4] */ - visible: boolean; - /** - * 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.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.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?: { - 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. - */ - 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; - /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @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. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; + visible: boolean; /** * 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.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.ParagraphFormat; + 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. * @@ -120470,76 +120498,48 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ParagraphFormat; + }): 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.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.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.ParagraphFormatData; + toJSON(): PowerPoint.Interfaces.BulletFormatData; } /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. * * @remarks * [Api set: PowerPointApi 1.4] */ - class ShapeFont extends OfficeExtension.ClientObject { + 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; /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - size: number; + readonly bulletFormat: PowerPoint.BulletFormat; /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * 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] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; /** * 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.ShapeFontLoadOptions): PowerPoint.ShapeFont; + 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.ShapeFont; + 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. * @@ -120548,12 +120548,12 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ShapeFont; + }): 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.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. + * 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.ShapeFontData; + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. @@ -121568,6 +121568,68 @@ declare namespace PowerPoint { interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + interface ShapeFillUpdateData { + /** + * 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 does not 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 `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + interface ShapeFontUpdateData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ interface ShapeCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -121590,23 +121652,6 @@ declare namespace PowerPoint { interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - interface ShapeFillUpdateData { - /** - * 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 does not 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 `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ interface ShapeScopedCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -121676,51 +121721,6 @@ declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - interface ShapeFontUpdateData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ interface TextRangeUpdateData { /** @@ -121974,18 +121974,87 @@ declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.6] */ - address?: string; + 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[]; + } + /** 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 does not 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 { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; /** - * Specifies the string displayed when hovering over the hyperlink. + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.4] */ - screenTip?: string; - } - /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ - interface HyperlinkCollectionData { - items?: PowerPoint.Interfaces.HyperlinkData[]; + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ interface ShapeCollectionData { @@ -122060,30 +122129,6 @@ declare namespace PowerPoint { */ id?: string; } - /** 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 does not 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 `shapeScopedCollection.toJSON()`. */ interface ShapeScopedCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -122153,51 +122198,6 @@ declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - interface ShapeFontData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ interface TextRangeData { /** @@ -122613,6 +122613,93 @@ declare namespace PowerPoint { */ screenTip?: boolean; } + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [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 does not 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: boolean; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: boolean; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: boolean; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: boolean; + } /** * Represents the collection of shapes. * @@ -122858,39 +122945,6 @@ declare namespace PowerPoint { */ id?: boolean; } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [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 does not 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 a collection of shapes. * @@ -123072,60 +123126,6 @@ declare namespace PowerPoint { */ 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 { - /** - 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 bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - underline?: boolean; - } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. * diff --git a/generate-docs/script-inputs/office_preview.d.ts b/generate-docs/script-inputs/office_preview.d.ts index e093cc971..0edad0af6 100644 --- a/generate-docs/script-inputs/office_preview.d.ts +++ b/generate-docs/script-inputs/office_preview.d.ts @@ -128902,6 +128902,128 @@ declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.CustomXmlPartCollectionData; } + /** + * Specifies the type of a shape. + * + * @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", + /** + * The shape is a geometric shape such as rectangle. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + geometricShape = "GeometricShape", + /** + * The shape is a group shape which contains sub-shapes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + group = "Group", + /** + * The shape is a line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + line = "Line", + /** + * The shape is a table. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + table = "Table", + /** + * The shape is a callout. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + callout = "Callout", + /** + * The shape is a chart. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + chart = "Chart", + /** + * The shape is a content Office Add-in. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + contentApp = "ContentApp", + /** + * The shape is a diagram. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + diagram = "Diagram", + /** + * The shape is a freeform object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + freeform = "Freeform", + /** + * The shape is a graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + graphic = "Graphic", + /** + * The shape is an ink object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ink = "Ink", + /** + * The shape is a media object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + media = "Media", + /** + * The shape is a 3D model. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + model3D = "Model3D", + /** + * The shape is an OLE (Object Linking and Embedding) object. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + ole = "Ole", + /** + * The shape is a placeholder. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + placeholder = "Placeholder", + /** + * The shape is a SmartArt graphic. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + smartArt = "SmartArt", + /** + * The shape is a text box. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + textBox = "TextBox", + } /** * Represents a single hyperlink. * @@ -130224,164 +130346,359 @@ declare namespace PowerPoint { systemDashDot = "SystemDashDot", } /** - * The type of underline applied to a font. + * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ShapeFontUnderlineStyle { - /** - * No underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - none = "None", - /** - * Regular single line underlining. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - single = "Single", - /** - * Underlining of text with double lines. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - double = "Double", - /** - * Underlining of text with a thick line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - heavy = "Heavy", + enum ParagraphHorizontalAlignment { /** - * Underlining of text with a dotted line. + * Align text to the left margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dotted = "Dotted", + left = "Left", /** - * Underlining of text with a thick, dotted line. + * Align text in the center. * @remarks * [Api set: PowerPointApi 1.4] */ - dottedHeavy = "DottedHeavy", + center = "Center", /** - * Underlining of text with a line containing dashes. + * Align text to the right margin. * @remarks * [Api set: PowerPointApi 1.4] */ - dash = "Dash", + right = "Right", /** - * Underlining of text with a thick line containing dashes. + * Align text so that it is justified across the whole line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashHeavy = "DashHeavy", + justify = "Justify", /** - * Underlining of text with a line containing long dashes. + * Specifies the alignment or adjustment of kashida length in Arabic text. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLong = "DashLong", + justifyLow = "JustifyLow", /** - * Underlining of text with a thick line containing long dashes. + * Distributes the text words across an entire text line. * @remarks * [Api set: PowerPointApi 1.4] */ - dashLongHeavy = "DashLongHeavy", + distributed = "Distributed", /** - * Underlining of text with a line containing dots and dashes. + * Distributes Thai text specially, because each character is treated as a word. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDash = "DotDash", + thaiDistributed = "ThaiDistributed", + } + /** + * Specifies a shape's fill type. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + enum ShapeFillType { /** - * Underlining of text with a thick line containing dots and dashes. + * Specifies that the shape should have no fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDashHeavy = "DotDashHeavy", + noFill = "NoFill", /** - * Underlining of text with a line containing double dots and dashes. + * Specifies that the shape should have regular solid fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDash = "DotDotDash", + solid = "Solid", /** - * Underlining of text with a thick line containing double dots and dashes. + * Specifies that the shape should have gradient fill. * @remarks * [Api set: PowerPointApi 1.4] */ - dotDotDashHeavy = "DotDotDashHeavy", + gradient = "Gradient", /** - * Underlining of text with a wavy line. + * Specifies that the shape should have pattern fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavy = "Wavy", + pattern = "Pattern", /** - * Underlining of text with a thick, wavy line. + * Specifies that the shape should have picture or texture fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyHeavy = "WavyHeavy", + pictureAndTexture = "PictureAndTexture", /** - * Underlining of text with double wavy lines. + * Specifies that the shape should have slide background fill. * @remarks * [Api set: PowerPointApi 1.4] */ - wavyDouble = "WavyDouble", + slideBackground = "SlideBackground", } /** - * Represents the horizontal alignment of the {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. + * Represents the fill formatting of a shape object. * * @remarks * [Api set: PowerPointApi 1.4] */ - enum ParagraphHorizontalAlignment { + 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; /** - * Align text to the left margin. + * 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] */ - left = "Left", + foregroundColor: string; /** - * Align text in the center. + * Specifies the transparency percentage of the fill as a value from 0.0 (opaque) through 1.0 (clear). Returns `null` if the shape type does not support transparency or the shape fill has inconsistent transparency, such as with a gradient fill type. + * * @remarks * [Api set: PowerPointApi 1.4] */ - center = "Center", + transparency: number; /** - * Align text to the right margin. + * Returns the fill type of the shape. See {@link PowerPoint.ShapeFillType} for details. + * * @remarks * [Api set: PowerPointApi 1.4] */ - right = "Right", + readonly type: PowerPoint.ShapeFillType | "NoFill" | "Solid" | "Gradient" | "Pattern" | "PictureAndTexture" | "SlideBackground"; /** - * Align text so that it is justified across the whole line. + * Clears the fill formatting of this shape. + * * @remarks * [Api set: PowerPointApi 1.4] */ - justify = "Justify", + clear(): void; /** - * Specifies the alignment or adjustment of kashida length in Arabic text. + * 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"). */ - justifyLow = "JustifyLow", + setSolidColor(color: string): void; /** - * Distributes the text words across an entire text line. - * @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. */ - distributed = "Distributed", + load(options?: PowerPoint.Interfaces.ShapeFillLoadOptions): PowerPoint.ShapeFill; /** - * Distributes Thai text specially, because each character is treated as a word. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - thaiDistributed = "ThaiDistributed", + * 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 { + /** + * No underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + none = "None", + /** + * Regular single line underlining. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + single = "Single", + /** + * Underlining of text with double lines. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + double = "Double", + /** + * Underlining of text with a thick line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + heavy = "Heavy", + /** + * Underlining of text with a dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotted = "Dotted", + /** + * Underlining of text with a thick, dotted line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dottedHeavy = "DottedHeavy", + /** + * Underlining of text with a line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dash = "Dash", + /** + * Underlining of text with a thick line containing dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashHeavy = "DashHeavy", + /** + * Underlining of text with a line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLong = "DashLong", + /** + * Underlining of text with a thick line containing long dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dashLongHeavy = "DashLongHeavy", + /** + * Underlining of text with a line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDash = "DotDash", + /** + * Underlining of text with a thick line containing dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDashHeavy = "DotDashHeavy", + /** + * Underlining of text with a line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDash = "DotDotDash", + /** + * Underlining of text with a thick line containing double dots and dashes. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + dotDotDashHeavy = "DotDotDashHeavy", + /** + * Underlining of text with a wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavy = "Wavy", + /** + * Underlining of text with a thick, wavy line. + * @remarks + * [Api set: PowerPointApi 1.4] + */ + wavyHeavy = "WavyHeavy", + /** + * Underlining of text with double wavy lines. + * @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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + /** + * 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.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.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?: { + 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 vertical alignment of a {@link PowerPoint.TextFrame} in a {@link PowerPoint.Shape}. @@ -131370,123 +131687,6 @@ declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.SlideData; } - /** - * Specifies a shape's fill type. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - 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; - /** - * 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 does not 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] - */ - 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 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.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; - } /** * Represents a collection of shapes. * @@ -131755,128 +131955,6 @@ declare namespace PowerPoint { */ toJSON(): PowerPoint.Interfaces.ShapeLineFormatData; } - /** - * Specifies the type of a shape. - * - * @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", - /** - * The shape is a geometric shape such as rectangle. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - geometricShape = "GeometricShape", - /** - * The shape is a group shape which contains sub-shapes. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - group = "Group", - /** - * The shape is a line. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - line = "Line", - /** - * The shape is a table. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - table = "Table", - /** - * The shape is a callout. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - callout = "Callout", - /** - * The shape is a chart. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - chart = "Chart", - /** - * The shape is a content Office Add-in. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - contentApp = "ContentApp", - /** - * The shape is a diagram. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - diagram = "Diagram", - /** - * The shape is a freeform object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - freeform = "Freeform", - /** - * The shape is a graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - graphic = "Graphic", - /** - * The shape is an ink object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ink = "Ink", - /** - * The shape is a media object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - media = "Media", - /** - * The shape is a 3D model. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - model3D = "Model3D", - /** - * The shape is an OLE (Object Linking and Embedding) object. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - ole = "Ole", - /** - * The shape is a placeholder. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - placeholder = "Placeholder", - /** - * The shape is a SmartArt graphic. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - smartArt = "SmartArt", - /** - * The shape is a text box. - * @remarks - * [Api set: PowerPointApi 1.4] - */ - textBox = "TextBox", - } /** * Determines the type of automatic sizing allowed. * @@ -131924,69 +132002,19 @@ declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.4] */ - visible: boolean; - /** - * 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.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.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?: { - 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. - */ - 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; - /** - * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. - * - * @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. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; + visible: boolean; /** * 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.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.ParagraphFormat; + 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. * @@ -131995,76 +132023,48 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ParagraphFormat; + }): 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.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.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.ParagraphFormatData; + toJSON(): PowerPoint.Interfaces.BulletFormatData; } /** - * Represents the font attributes, such as font name, font size, and color, for a shape's TextRange object. + * Represents the paragraph formatting properties of a text that is attached to the {@link PowerPoint.TextRange}. * * @remarks * [Api set: PowerPointApi 1.4] */ - class ShapeFont extends OfficeExtension.ClientObject { + 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; /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * Represents the bullet format of the paragraph. See {@link PowerPoint.BulletFormat} for details. * * @remarks * [Api set: PowerPointApi 1.4] */ - size: number; + readonly bulletFormat: PowerPoint.BulletFormat; /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * 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] */ - underline: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; + horizontalAlignment: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; /** * 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.ShapeFontLoadOptions): PowerPoint.ShapeFont; + 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.ShapeFont; + 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. * @@ -132073,12 +132073,12 @@ declare namespace PowerPoint { load(propertyNamesAndPaths?: { select?: string; expand?: string; - }): PowerPoint.ShapeFont; + }): 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.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. + * 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.ShapeFontData; + toJSON(): PowerPoint.Interfaces.ParagraphFormatData; } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. @@ -133125,6 +133125,68 @@ declare namespace PowerPoint { interface HyperlinkCollectionUpdateData { items?: PowerPoint.Interfaces.HyperlinkData[]; } + /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ + interface ShapeFillUpdateData { + /** + * 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 does not 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 `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ + interface ShapeFontUpdateData { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; + } /** An interface for updating data on the `ShapeCollection` object, for use in `shapeCollection.set({ ... })`. */ interface ShapeCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -133147,23 +133209,6 @@ declare namespace PowerPoint { interface TagCollectionUpdateData { items?: PowerPoint.Interfaces.TagData[]; } - /** An interface for updating data on the `ShapeFill` object, for use in `shapeFill.set({ ... })`. */ - interface ShapeFillUpdateData { - /** - * 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 does not 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 `ShapeScopedCollection` object, for use in `shapeScopedCollection.set({ ... })`. */ interface ShapeScopedCollectionUpdateData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -133233,51 +133278,6 @@ declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface for updating data on the `ShapeFont` object, for use in `shapeFont.set({ ... })`. */ - interface ShapeFontUpdateData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface for updating data on the `TextRange` object, for use in `textRange.set({ ... })`. */ interface TextRangeUpdateData { /** @@ -133531,18 +133531,87 @@ declare namespace PowerPoint { * @remarks * [Api set: PowerPointApi 1.6] */ - address?: string; + 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[]; + } + /** 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 does not 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 { + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: string; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: string; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: number; /** - * Specifies the string displayed when hovering over the hyperlink. + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. * * @remarks - * [Api set: PowerPointApi 1.6] + * [Api set: PowerPointApi 1.4] */ - screenTip?: string; - } - /** An interface describing the data returned by calling `hyperlinkCollection.toJSON()`. */ - interface HyperlinkCollectionData { - items?: PowerPoint.Interfaces.HyperlinkData[]; + underline?: PowerPoint.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"; } /** An interface describing the data returned by calling `shapeCollection.toJSON()`. */ interface ShapeCollectionData { @@ -133633,30 +133702,6 @@ declare namespace PowerPoint { */ index?: number; } - /** 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 does not 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 `shapeScopedCollection.toJSON()`. */ interface ShapeScopedCollectionData { items?: PowerPoint.Interfaces.ShapeData[]; @@ -133737,51 +133782,6 @@ declare namespace PowerPoint { */ horizontalAlignment?: PowerPoint.ParagraphHorizontalAlignment | "Left" | "Center" | "Right" | "Justify" | "JustifyLow" | "Distributed" | "ThaiDistributed"; } - /** An interface describing the data returned by calling `shapeFont.toJSON()`. */ - interface ShapeFontData { - /** - * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: string; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: string; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: number; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes 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"; - } /** An interface describing the data returned by calling `textRange.toJSON()`. */ interface TextRangeData { /** @@ -134211,6 +134211,93 @@ declare namespace PowerPoint { */ screenTip?: boolean; } + /** + * Represents the fill formatting of a shape object. + * + * @remarks + * [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 does not 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; + /** + * Represents the bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + bold?: boolean; + /** + * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + color?: boolean; + /** + * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + italic?: boolean; + /** + * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + name?: boolean; + /** + * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + size?: boolean; + /** + * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. + * + * @remarks + * [Api set: PowerPointApi 1.4] + */ + underline?: boolean; + } /** * Represents the collection of shapes. * @@ -134512,39 +134599,6 @@ declare namespace PowerPoint { */ index?: boolean; } - /** - * Represents the fill formatting of a shape object. - * - * @remarks - * [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 does not 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 a collection of shapes. * @@ -134787,60 +134841,6 @@ declare namespace PowerPoint { */ 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 { - /** - 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 bold status of font. Returns `null` if the `TextRange` includes both bold and non-bold text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - bold?: boolean; - /** - * HTML color code representation of the text color (e.g., "#FF0000" represents red). Returns `null` if the `TextRange` includes text fragments with different colors. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - color?: boolean; - /** - * Represents the italic status of font. Returns 'null' if the 'TextRange' includes both italic and non-italic text fragments. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - italic?: boolean; - /** - * Represents font name (e.g., "Calibri"). If the text is a Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - name?: boolean; - /** - * Represents font size in points (e.g., 11). Returns null if the TextRange includes text fragments with different font sizes. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - size?: boolean; - /** - * Type of underline applied to the font. Returns `null` if the `TextRange` includes text fragments with different underline styles. See {@link PowerPoint.ShapeFontUnderlineStyle} for details. - * - * @remarks - * [Api set: PowerPointApi 1.4] - */ - underline?: boolean; - } /** * Contains the text that is attached to a shape, in addition to properties and methods for manipulating the text. *