PowerPoint.SlideBackgroundFill class
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Represents the fill formatting of a slide background object.
- Extends
Remarks
Properties
| context | The request context associated with the object. This connects the add-in's process to the Office host application's process. |
| type | Returns the fill type of the slide background. See PowerPoint.SlideBackgroundFillType for details. |
Methods
| get |
Gets the gradient fill properties. If the fill type is not |
| get |
Gets the pattern fill properties. If the fill type is not |
| get |
Gets the picture or texture fill properties. If the fill type is not |
| get |
Gets the solid fill properties. If the fill type is not |
| load(options) | Queues up a command to load the specified properties of the object. You must call |
| load(property |
Queues up a command to load the specified properties of the object. You must call |
| load(property |
Queues up a command to load the specified properties of the object. You must call |
| set |
Sets the fill formatting of the slide background to a gradient fill. This changes the fill type to |
| set |
Sets the fill formatting of the slide background to a pattern fill. This changes the fill type to |
| set |
Sets the fill formatting of the slide background to a picture or texture fill. This changes the fill type to |
| set |
Sets the fill formatting of the slide background to a solid fill. This changes the fill type to |
| toJSON() | Overrides the JavaScript |
Property Details
context
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
The request context associated with the object. This connects the add-in's process to the Office host application's process.
context: RequestContext;
Property Value
type
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Returns the fill type of the slide background. See PowerPoint.SlideBackgroundFillType for details.
readonly type: PowerPoint.SlideBackgroundFillType | "Unsupported" | "Solid" | "Gradient" | "PictureOrTexture" | "Pattern";
Property Value
PowerPoint.SlideBackgroundFillType | "Unsupported" | "Solid" | "Gradient" | "PictureOrTexture" | "Pattern"
Remarks
Method Details
getGradientFillOrNullObject()
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Gets the gradient fill properties. If the fill type is not gradient, an object with an isNullObject property set to true is returned. For further information, see *OrNullObject methods and properties.
getGradientFillOrNullObject(): PowerPoint.SlideBackgroundGradientFill;
Returns
Remarks
getPatternFillOrNullObject()
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Gets the pattern fill properties. If the fill type is not pattern, an object with an isNullObject property set to true is returned. For further information, see *OrNullObject methods and properties.
getPatternFillOrNullObject(): PowerPoint.SlideBackgroundPatternFill;
Returns
Remarks
getPictureOrTextureFillOrNullObject()
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Gets the picture or texture fill properties. If the fill type is not pictureOrTexture, an object with an isNullObject property set to true is returned. For further information, see *OrNullObject methods and properties.
getPictureOrTextureFillOrNullObject(): PowerPoint.SlideBackgroundPictureOrTextureFill;
Returns
Remarks
getSolidFillOrNullObject()
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Gets the solid fill properties. If the fill type is not solid, an object with an isNullObject property set to true is returned. For further information, see *OrNullObject methods and properties.
getSolidFillOrNullObject(): PowerPoint.SlideBackgroundSolidFill;
Returns
Remarks
load(options)
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Queues up a command to load the specified properties of the object. You must call context.sync() before reading the properties.
load(options?: PowerPoint.Interfaces.SlideBackgroundFillLoadOptions): PowerPoint.SlideBackgroundFill;
Parameters
Provides options for which properties of the object to load.
Returns
load(propertyNames)
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Queues up a command to load the specified properties of the object. You must call context.sync() before reading the properties.
load(propertyNames?: string | string[]): PowerPoint.SlideBackgroundFill;
Parameters
- propertyNames
-
string | string[]
A comma-delimited string or an array of strings that specify the properties to load.
Returns
load(propertyNamesAndPaths)
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Queues up a command to load the specified properties of the object. You must call context.sync() before reading the properties.
load(propertyNamesAndPaths?: {
select?: string;
expand?: string;
}): PowerPoint.SlideBackgroundFill;
Parameters
- propertyNamesAndPaths
-
{ select?: string; expand?: string; }
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.
Returns
setGradientFill(options)
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Sets the fill formatting of the slide background to a gradient fill. This changes the fill type to gradient.
setGradientFill(options?: PowerPoint.SlideBackgroundGradientFillOptions): void;
Parameters
Options for the gradient fill.
Returns
void
Remarks
setPatternFill(options)
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Sets the fill formatting of the slide background to a pattern fill. This changes the fill type to pattern.
setPatternFill(options?: PowerPoint.SlideBackgroundPatternFillOptions): void;
Parameters
Options for the pattern fill.
Returns
void
Remarks
setPictureOrTextureFill(options)
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Sets the fill formatting of the slide background to a picture or texture fill. This changes the fill type to pictureOrTexture.
setPictureOrTextureFill(options?: PowerPoint.SlideBackgroundPictureOrTextureFillOptions): void;
Parameters
Options for the picture or texture fill.
Returns
void
Remarks
setSolidFill(options)
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Sets the fill formatting of the slide background to a solid fill. This changes the fill type to solid.
setSolidFill(options?: PowerPoint.SlideBackgroundSolidFillOptions): void;
Parameters
Options for the solid fill.
Returns
void
Remarks
toJSON()
Note
This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Overrides the JavaScript toJSON() method in order to provide more useful output when an API object is passed to JSON.stringify(). (JSON.stringify, in turn, calls the toJSON method of the object that's passed to it.) Whereas the original PowerPoint.SlideBackgroundFill object is an API object, the toJSON method returns a plain JavaScript object (typed as PowerPoint.Interfaces.SlideBackgroundFillData) that contains shallow copies of any loaded child properties from the original object.
toJSON(): PowerPoint.Interfaces.SlideBackgroundFillData;