UNPKG

gas-types-detailed

Version:

Enhanced Google Apps Script Type Definitions with detailed documentation. Includes type definitions plus code snippets, return values, required authorization scopes, and other details not found in @types/google-apps-script.

1,289 lines (1,212 loc) 825 kB
// Type definitions for Google Apps Script 2025-11-10 // Project: https://developers.google.com/apps-script/ // Definitions by: motemen <https://github.com/motemen/> // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped /// <reference path="google-apps-script.types.d.ts" /> /// <reference path="google-apps-script.base.d.ts" /> /// <reference path="google-apps-script.spreadsheet.d.ts" /> declare namespace GoogleAppsScript { namespace Slides { /** * A 3x3 matrix used to transform source coordinates (x1, y1) into destination coordinates (x2, y2) * according to matrix multiplication: * * [ x2 ] [ scaleX shearX translateX ] [ x1 ] * [ y2 ] = [ shearY scaleY translateY ] [ y1 ] * [ 1 ] [ 0 0 1 ] [ 1 ] * * After transformation, * * x2 = scaleX * x1 + shearX * y1 + translateX; * y2 = scaleY * y1 + shearY * x1 + translateY; */ interface AffineTransform { /** * Gets the X coordinate scaling element. * * Return: * - Number * * https://developers.google.com/apps-script/reference/slides/affine-transform#getScaleX() */ getScaleX(): number; /** * Gets the Y coordinate scaling element. * * Return: * - Number * * https://developers.google.com/apps-script/reference/slides/affine-transform#getScaleY() */ getScaleY(): number; /** * Gets the X coordinate shearing element. * * Return: * - Number * * https://developers.google.com/apps-script/reference/slides/affine-transform#getShearX() */ getShearX(): number; /** * Gets the Y coordinate shearing element. * * Return: * - Number * * https://developers.google.com/apps-script/reference/slides/affine-transform#getShearY() */ getShearY(): number; /** * Gets the X coordinate translation element in points. * * Return: * - Number * * https://developers.google.com/apps-script/reference/slides/affine-transform#getTranslateX() */ getTranslateX(): number; /** * Gets the Y coordinate translation element in points. * * Return: * - Number * * https://developers.google.com/apps-script/reference/slides/affine-transform#getTranslateY() */ getTranslateY(): number; /** * Returns a new AffineTransformBuilder based on this transform. * * Return: * - AffineTransformBuilder * * https://developers.google.com/apps-script/reference/slides/affine-transform#toBuilder() */ toBuilder(): AffineTransformBuilder; } /** * A builder for AffineTransform objects. Defaults to the identity transform. * * Call AffineTransformBuilder#build() to get the AffineTransform object. * * const transform = * SlidesApp.newAffineTransformBuilder().setScaleX(2.0).setShearY(1.1).build(); * * // The resulting transform matrix is * // [ 2.0 0.0 0.0 ] * // [ 1.1 1.0 0.0 ] * // [ 0 0 1 ] * } */ interface AffineTransformBuilder { /** * Creates an AffineTransform object initialized with the elements set in the builder. * * Return: * - AffineTransform * * https://developers.google.com/apps-script/reference/slides/affine-transform-builder#build() */ build(): AffineTransform; /** * Sets the X coordinate scaling element and returns the builder. * * Return: * - AffineTransformBuilder * * https://developers.google.com/apps-script/reference/slides/affine-transform-builder#setScaleX(Number) * @param scaleX */ setScaleX(scaleX: number): AffineTransformBuilder; /** * Sets the Y coordinate scaling element and returns the builder. * * Return: * - AffineTransformBuilder * * https://developers.google.com/apps-script/reference/slides/affine-transform-builder#setScaleY(Number) * @param scaleY */ setScaleY(scaleY: number): AffineTransformBuilder; /** * Sets the X coordinate shearing element and returns the builder. * * Return: * - AffineTransformBuilder * * https://developers.google.com/apps-script/reference/slides/affine-transform-builder#setShearX(Number) * @param shearX */ setShearX(shearX: number): AffineTransformBuilder; /** * Sets the Y coordinate shearing element and returns the builder. * * Return: * - AffineTransformBuilder * * https://developers.google.com/apps-script/reference/slides/affine-transform-builder#setShearY(Number) * @param shearY */ setShearY(shearY: number): AffineTransformBuilder; /** * Sets the X coordinate translation element in points, and returns the builder. * * Return: * - AffineTransformBuilder * * https://developers.google.com/apps-script/reference/slides/affine-transform-builder#setTranslateX(Number) * @param translateX */ setTranslateX(translateX: number): AffineTransformBuilder; /** * Sets the Y coordinate translation element in points, and returns the builder. * * Return: * - AffineTransformBuilder * * https://developers.google.com/apps-script/reference/slides/affine-transform-builder#setTranslateY(Number) * @param translateY */ setTranslateY(translateY: number): AffineTransformBuilder; } /** * The alignment position to apply. * * To call an enum, you call its parent class, name, and property. For example, * SlidesApp.AlignmentPosition.CENTER. */ enum AlignmentPosition { CENTER, HORIZONTAL_CENTER, VERTICAL_CENTER } /** * The kinds of start and end forms with which linear geometry can be rendered. * * Some values are based on the "ST_LineEndType" simple type described in section 20.1.10.33 of * of "Office Open XML File Formats - Fundamentals and Markup Language Reference", part 1 of ECMA-376 5th * edition. * * To call an enum, you call its parent class, name, and property. For example, * SlidesApp.ArrowStyle.FILL_ARROW. */ enum ArrowStyle { UNSUPPORTED, NONE, STEALTH_ARROW, FILL_ARROW, FILL_CIRCLE, FILL_SQUARE, FILL_DIAMOND, OPEN_ARROW, OPEN_CIRCLE, OPEN_SQUARE, OPEN_DIAMOND } /** * An element of text that is dynamically replaced with content that can change over time, such as a * slide number. */ interface AutoText { /** * Returns the type of auto text. Returns null if the auto text has been deleted. * * Return: * - AutoTextType * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/auto-text#getAutoTextType() */ getAutoTextType(): AutoTextType; /** * Returns the index of the auto text. Returns null if the auto text has been deleted. * * Return: * - Integer * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/auto-text#getIndex() */ getIndex(): Integer; /** * Returns a TextRange spanning the auto text. Returns null if the auto text has been deleted. * * Return: * - TextRange * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/auto-text#getRange() */ getRange(): TextRange; } /** * The types of auto text. * * To call an enum, you call its parent class, name, and property. For example, * SlidesApp.AutoTextType.SLIDE_NUMBER. */ enum AutoTextType { UNSUPPORTED, SLIDE_NUMBER } /** * Describes the autofit settings of a shape. If a change is made that might affect text fitting * within its bounding text box: * * Autofit is deactivated and set to AutofitType.NONE. * * The font scale is reset to the default value and applied to the font size. * * The line spacing reduction is reset to the default value and applied to the line spacing. */ interface Autofit { /** * Sets the AutofitType of a shape to AutofitType.NONE. * * Return: * - Autofit — The autofit, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/autofit#disableAutofit() */ disableAutofit(): Autofit; /** * Gets the AutofitType of the shape. * * Return: * - AutofitType — The autofit type. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/autofit#getAutofitType() */ getAutofitType(): AutofitType; /** * Gets the font scale applied to the shape. For shapes with AutofitType AutofitType.NONE or AutofitType.SHAPE_AUTOFIT, this value is the default value of 1. For AutofitType.TEXT_AUTOFIT, the value returned is what the original font size is multiplied by to fit within the shape. * * Return: * - Number — The font scale. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/autofit#getFontScale() */ getFontScale(): number; /** * Gets the line spacing reduction applied to the shape. For shapes with AutofitType AutofitType.NONE or AutofitType.SHAPE_AUTOFIT, this value is the default value of 0. For AutofitType.TEXT_AUTOFIT, the returned value is the amount of spacing subtracted from the original spacing to make the text fit within the shape. * * Return: * - Number — The line spacing. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/autofit#getLineSpacingReduction() */ getLineSpacingReduction(): number; } /** * The autofit types. * * To call an enum, you call its parent class, name, and property. For example, * SlidesApp.AutofitType.TEXT_AUTOFIT. */ enum AutofitType { UNSUPPORTED, NONE, TEXT_AUTOFIT, SHAPE_AUTOFIT } /** * Describes the border around an element. */ interface Border { /** * Gets the DashStyle of the border. * * Return: * - DashStyle * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/border#getDashStyle() */ getDashStyle(): DashStyle; /** * Gets the LineFill of the border. * * Return: * - LineFill * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/border#getLineFill() */ getLineFill(): LineFill; /** * Gets the thickness of the border in points. Returns null if the element does not have a border. * * Return: * - Number * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/border#getWeight() */ getWeight(): number; /** * Gets whether the border is visible or not. * * Return: * - Boolean * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/border#isVisible() */ isVisible(): boolean; /** * Sets the DashStyle of the border. * Setting a DashStyle on a transparent border makes it visible. * * Return: * - Border * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/border#setDashStyle(DashStyle) * @param style */ setDashStyle(style: DashStyle): Border; /** * Sets the border to be transparent. * * Return: * - Border * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/border#setTransparent() */ setTransparent(): Border; /** * Sets the thickness of the border in points. * Setting a weight on a transparent border makes it visible. * * Return: * - Border * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/border#setWeight(Number) * @param points */ setWeight(points: number): Border; } /** * The table cell merge states. * * To call an enum, you call its parent class, name, and property. For example, * SlidesApp.CellMergeState.NORMAL. */ enum CellMergeState { NORMAL, HEAD, MERGED } /** * An opaque color */ interface Color { /** * Converts this color to an RgbColor. * * Return: * - RgbColor * * Throws: * - Error — if the color is not an RgbColor * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/color#asRgbColor() */ asRgbColor(): Base.RgbColor; /** * Converts this color to a ThemeColor. * * Return: * - ThemeColor * * Throws: * - Error — if the color is not a ThemeColor * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/color#asThemeColor() */ asThemeColor(): ThemeColor; /** * Get the type of this color. * * Return: * - ColorType — The color type. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/color#getColorType() */ getColorType(): Base.ColorType; } /** * A color scheme defines a mapping from members of ThemeColorType to the actual colors used * to render them. */ interface ColorScheme { /** * Returns the concrete Color associated with the ThemeColorType in this color scheme. * The returned color is guaranteed to not be an instance of ThemeColor. * * Return: * - Color — The concrete color corresponding the theme color type in this scheme. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/color-scheme#getConcreteColor(ThemeColorType) * @param theme The theme color to derive the concrete color from. */ getConcreteColor(theme: ThemeColorType): Color; /** * Returns a list of all possible theme color types in a color scheme. * * Return: * - ThemeColorType[] — The possible theme color types in this scheme. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/color-scheme#getThemeColors() */ getThemeColors(): ThemeColorType[]; /** * Sets the concrete color associated with the ThemeColorType in this color scheme to the given color. * * Return: * - ColorScheme — This color scheme, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/color-scheme#setConcreteColor(ThemeColorType,Color) * @param type The theme color type. * @param color The color to set the theme color type to. */ setConcreteColor(type: ThemeColorType, color: Color): ColorScheme; /** * Sets the concrete color associated with the ThemeColorType in this color scheme to the given color in RGB format. * * Return: * - ColorScheme — This color scheme, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/color-scheme#setConcreteColor(ThemeColorType,Integer,Integer,Integer) * @param type The theme color type. * @param red The red value of the color to set the theme color type to (between 0 and 255). * @param green The green value of the color to set the theme color type to (between 0 and 255). * @param blue The blue value of the color to set the theme color type to (between 0 and 255). */ setConcreteColor(type: ThemeColorType, red: Integer, green: Integer, blue: Integer): ColorScheme; /** * Sets the concrete color associated with the ThemeColorType in this color scheme to the given color in HEX format. * The hex string must be in the format '#RRGGBB'. * * Return: * - ColorScheme — This color scheme, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/color-scheme#setConcreteColor(ThemeColorType,String) * @param type The theme color type. * @param hexColor The hex color to set the theme color type to, such as '#F304a7'. */ setConcreteColor(type: ThemeColorType, hexColor: string): ColorScheme; } /** * The connection site on a PageElement that can connect to a connector. */ interface ConnectionSite { /** * Returns the index of the connection site. The index is unique among all the connection sites on the same page element. * In most cases, it corresponds to the predefined connection site index from the ECMA-376 standard. More information on those connection sites can be found in the description of the "cnx" attribute in section 20.1.9.9 and Annex H. "Predefined DrawingML Shape and Text Geometries" of "Office Open XML File Formats-Fundamentals and Markup Language Reference", part 1 of ECMA-376 5th edition. * * Return: * - Integer — The index of the connection site. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/connection-site#getIndex() */ getIndex(): Integer; /** * Returns the PageElement that the connection site is on. * * Return: * - PageElement — The page element of the connection site. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/connection-site#getPageElement() */ getPageElement(): PageElement; } /** * The content alignments for a Shape or TableCell. The supported alignments * correspond to predefined text anchoring types from the ECMA-376 standard. * * More information on those alignments can be found in the description of * the ST_TextAnchoringType simple type in section 20.1.10.59 of "Office Open XML File * Formats - Fundamentals and Markup Language Reference", part 1 of ECMA-376 * 5th edition. * * To call an enum, you call its parent class, name, and property. For example, * SlidesApp.ContentAlignment.TOP. */ enum ContentAlignment { UNSUPPORTED, TOP, MIDDLE, BOTTOM } /** * The kinds of dashes with which linear geometry can be rendered. These values are based on the * "ST_PresetLineDashVal" simple type described in section 20.1.10.48 of "Office Open XML File * Formats - Fundamentals and Markup Language Reference", part 1 of ECMA-376 5th * edition. * * To call an enum, you call its parent class, name, and property. For example, * SlidesApp.DashStyle.DOT. */ enum DashStyle { UNSUPPORTED, SOLID, DOT, DASH, DASH_DOT, LONG_DASH, LONG_DASH_DOT } /** * Describes the page element's background */ interface Fill { /** * Get the solid fill of this background, or null if the fill type is not FillType.SOLID. * * Return: * - SolidFill — The solid fill setting, or null if this fill type is not solid. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#getSolidFill() */ getSolidFill(): SolidFill; /** * Get the type of this fill. * * Return: * - FillType — The type of this fill. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#getType() */ getType(): FillType; /** * Whether the background is visible. * * Return: * - Boolean — true if the background is visible; false otherwise. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#isVisible() */ isVisible(): boolean; /** * Sets the solid fill to the given Color. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setSolidFill(Color) * @param color */ setSolidFill(color: Color): void; /** * Sets the solid fill to the given alpha and Color. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setSolidFill(Color,Number) * @param color * @param alpha */ setSolidFill(color: Color, alpha: number): void; /** * Sets the solid fill to the given RGB values. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setSolidFill(Integer,Integer,Integer) * @param red * @param green * @param blue */ setSolidFill(red: Integer, green: Integer, blue: Integer): void; /** * Sets the solid fill to the given alpha and RGB values. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setSolidFill(Integer,Integer,Integer,Number) * @param red * @param green * @param blue * @param alpha */ setSolidFill(red: Integer, green: Integer, blue: Integer, alpha: number): void; /** * Sets the solid fill to the given hex color string. * The hex string must be in the format '#RRGGBB'. For example, pink is represented as '#FFC0CB'. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setSolidFill(String) * @param hexString */ setSolidFill(hexString: string): void; /** * Sets the solid fill to the given alpha and hex color string. * The hex string must be in the format '#RRGGBB'. For example, pink is represented as '#FFC0CB'. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setSolidFill(String,Number) * @param hexString * @param alpha */ setSolidFill(hexString: string, alpha: number): void; /** * Sets the solid fill to the given ThemeColorType. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setSolidFill(ThemeColorType) * @param color */ setSolidFill(color: ThemeColorType): void; /** * Sets the solid fill to the given alpha and ThemeColorType. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setSolidFill(ThemeColorType,Number) * @param color * @param alpha */ setSolidFill(color: ThemeColorType, alpha: number): void; /** * Sets the background to transparent. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/fill#setTransparent() */ setTransparent(): void; } /** * The kinds of fill. * * To call an enum, you call its parent class, name, and property. For example, * SlidesApp.FillType.SOLID. */ enum FillType { UNSUPPORTED, NONE, SOLID } /** * A collection of PageElements joined as a single unit. */ interface Group { /** * Aligns the element to the specified alignment position on the page. * * Return: * - Group — This page element, for chaining. * * https://developers.google.com/apps-script/reference/slides/group#alignOnPage(AlignmentPosition) * @param alignmentPosition The position to align this page element to on the page. */ alignOnPage(alignmentPosition: AlignmentPosition): Group; /** * Brings the page element forward on the page by one element. * The page element must not be in a group. * * Return: * - Group — This page element, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#bringForward() */ bringForward(): Group; /** * Brings the page element to the front of the page. * The page element must not be in a group. * * Return: * - Group — This page element, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#bringToFront() */ bringToFront(): Group; /** * Duplicates the page element. * The duplicate page element is placed on the same page at the same position as the original. * * Return: * - PageElement — The new duplicate of this page element. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#duplicate() */ duplicate(): PageElement; /** * Gets the collection of page elements in the group. The minimum size of a group is 2. * * Return: * - PageElement[] — The list of page elements in this group. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getChildren() */ getChildren(): PageElement[]; /** * Returns the list of ConnectionSites on the page element, or an empty list if the page element does not have any connection sites. * * Return: * - ConnectionSite[] — The connection sites list, which may be empty if this element has no connection sites. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getConnectionSites() */ getConnectionSites(): ConnectionSite[]; /** * Returns the page element's alt text description. The description is combined with the title to display and read alt text. * * Return: * - String — The page element's alt text description. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getDescription() */ getDescription(): string; /** * Gets the element's height in points, which is the height of the element's bounding box when the element has no rotation. * This method isn't compatible with all page elements. To learn which page elements aren't compatible with this method, refer to the sizing and positioning limitations. * * Return: * - Number — The page element's inherent height in points, or null if the page element does not have a height. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getHeight() */ getHeight(): number; /** * Returns the element's inherent height in points. * The page element's transform is relative to its inherent size. Use the inherent size in conjunction with the element's transform to determine the element's final visual appearance. * * Return: * - Number — The page element's inherent height in points, or null if the page element does not have a height. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getInherentHeight() */ getInherentHeight(): number; /** * Returns the element's inherent width in points. * The page element's transform is relative to its inherent size. Use the inherent size in conjunction with the element's transform to determine the element's final visual appearance. * * Return: * - Number — The page element's inherent width in points, or null if the page element does not have a width. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getInherentWidth() */ getInherentWidth(): number; /** * Returns the element's horizontal position in points, measured from the upper-left corner of the page when the element has no rotation. * * Return: * - Number — This element's horizontal position in points, from the upper-left corner of the page. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getLeft() */ getLeft(): number; /** * Returns the unique ID for this object. Object IDs used by pages and page elements share the same namespace. * * Return: * - String — The unique ID for this object. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getObjectId() */ getObjectId(): string; /** * Returns the page element's type, represented as a PageElementType enum. * * Return: * - PageElementType — The page element's type. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getPageElementType() */ getPageElementType(): PageElementType; /** * Returns the group this page element belongs to, or null if the element is not in a group. * * Return: * - Group — The group this page element belongs to, or null. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getParentGroup() */ getParentGroup(): Group; /** * Returns the page this page element is on. * * Return: * - Page — The page this element resides on. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getParentPage() */ getParentPage(): Page; /** * Returns the element's clockwise rotation angle around its center in degrees, where zero degrees means no rotation. * * Return: * - Number — The rotation angle in degrees between 0 (inclusive) and 360 (exclusive). * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getRotation() */ getRotation(): number; /** * Returns the page element's alt text title. The title is combined with the description to display and read alt text. * * Return: * - String — The page element's alt text title. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getTitle() */ getTitle(): string; /** * Gets the element's vertical position in points, measured from the upper-left corner of the page when the element has no rotation. * * Return: * - Number — This element's vertical position in points, from the upper-left corner of the page. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getTop() */ getTop(): number; /** * Gets the page element's transform. * The initial transform for a newly created Group is always the identity transform: 1.0 scale parameters, and 0.0 shear and translate parameters. * * Return: * - AffineTransform — The page element's transform. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getTransform() */ getTransform(): AffineTransform; /** * Returns the element's width in points, which is the width of the element's bounding box when the element has no rotation. * This method isn't compatible with all page elements. To learn which page elements aren't compatible with this method, refer to the sizing and positioning limitations. * * Return: * - Number — The page element's inherent width in points, or null if the page element does not have a width. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#getWidth() */ getWidth(): number; /** * Preconcatenates the provided transform to the existing transform of the page element. * * newTransform = argument * existingTransform; * * For example, to move a page elements 36 points to the left: * * const element = SlidesApp.getActivePresentation().getSlides()[0].getPageElements()[0]; * element.preconcatenateTransform( * SlidesApp.newAffineTransformBuilder().setTranslateX(-36.0).build(), * ); * * You can also replace the page element's transform with setTransform(transform). * * Return: * - Group — This page element, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#preconcatenateTransform(AffineTransform) * @param transform The transform to preconcatenate onto this page element's transform. */ preconcatenateTransform(transform: AffineTransform): Group; /** * Removes the page element. * If after a remove operation, a Group contains only one or no page elements, the group itself is also removed. * If a placeholder PageElement is removed on a master or layout, any empty inheriting placeholders are also removed. * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#remove() */ remove(): void; /** * Scales the element's height by the specified ratio. The element's height is the height of its bounding box when the element has no rotation. * This method isn't compatible with all page elements. To learn which page elements aren't compatible with this method, refer to the sizing and positioning limitations. * * Return: * - Group — This page element, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#scaleHeight(Number) * @param ratio The ratio to scale this page element's height by. */ scaleHeight(ratio: number): Group; /** * Scales the element's width by the specified ratio. The element's width is the width of its bounding box when the element has no rotation. * This method isn't compatible with all page elements. To learn which page elements aren't compatible with this method, refer to the sizing and positioning limitations. * * Return: * - Group — This page element, for chaining. * * Authorization: * * Scripts that use this method require authorization with one or more of the following scopes: * - https://www.googleapis.com/auth/presentations.currentonly * - https://www.googleapis.com/auth/presentations * * https://developers.google.com/apps-script/reference/slides/group#scaleWidth(Number) * @param ratio The ratio to scale this page element's width by. */ scaleWidth(ratio: number): Group; /** * Selects only the PageElement in the active presentation and removes any previous selection. This is the same as calling selec