Page evCreate API Section
The Page section of the evCreate API includes interfaces and functions to manage items on the page level of the Envision document hierarchy.
page namespace
The Page evCreate API section is accessed with the page namespace:
Interfaces
EvPageAttributesAn interface that defines the attributes of a given Envision document page.
Functions
AddLayer(page: EvItem, atIndex?: number, name?: string): Promise<EvItem>A function to add a new layer to a given page.
CountLayers(page: EvItem): Promise<number>A function to count the number of layers on a given page.
CountObjects(page: EvItem): Promise<number>A function to count the number of objects on a given page.
GetAttributes(page: EvItem): Promise<EvPageAttributes>A function to get an object with the attributes of a given page.
GetCurrentLayer(page: EvItem): Promise<EvItem>A function to get an object of the current layer on a given page.
GetLayers(page: EvItem): Promise<EvItem[]>A function to get objects of all layers on a given page.
GetObjects(page: EvItem): Promise<EvItem[]>A function to get all objects existing on a given page.
RemoveLayer(layer: EvItem, moveObjects: boolean): Promise<void>A function to remove a given layer from a page.
Render(page?: EvItem, options?: EvRenderOptions): Promise<EvItem>A function to render a given page into an image item object saved to the current page.
RenderTo(page?: EvItem, options?: EvRenderOptions, format?: EvImageFormat): Promise<string>A function to render a given page into an image encoded as a base64 string.
SetCurrentLayer(layer: EvItem): Promise<void>A function to set a given layer as current on the current page.
SetMargins(page: EvItem, margins: EvRect): Promise<void>A function to set the margins of a given page.
SetMasterPage(page: EvItem, masterPage?: EvItem): Promise<void>A function to link a given regular document page with a given master page or to remove such a link.
SetName(page: EvItem, name: string): Promise<void>A function to rename a given page.
SetSize(page: EvItem, width: number, height: number): Promise<void>A function to resize a given page.
SetUnit(page: EvItem, unit: EvDocUnit): Promise<void>A function to set a 2D length unit of measurement displayed on a given page.
SetVisible(page: EvItem, isVisible: boolean): Promise<void>A function to hide or show a given page.
SetZOrder(page: EvItem, index: number): Promise<void>A function to move the position of a given page along other pages in the document.