UNPKG

sprotty

Version:

A next-gen framework for graphical views

46 lines 2.36 kB
/******************************************************************************** * Copyright (c) 2017-2024 TypeFox and others. * * This program and the accompanying materials are made available under the * terms of the Eclipse Public License v. 2.0 which is available at * http://www.eclipse.org/legal/epl-2.0. * * This Source Code may also be made available under the following Secondary * Licenses when the conditions for such availability set forth in the Eclipse * Public License v. 2.0 are satisfied: GNU General Public License, version 2 * with the GNU Classpath Exception which is available at * https://www.gnu.org/software/classpath/license.html. * * SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 ********************************************************************************/ import { Action, ExportSvgOptions, RequestExportSvgAction, ResponseAction } from 'sprotty-protocol/lib/actions'; import { Bounds } from 'sprotty-protocol/lib/utils/geometry'; import { ActionDispatcher } from '../../base/actions/action-dispatcher'; import { SModelRootImpl } from '../../base/model/smodel'; import { ViewerOptions } from '../../base/views/viewer-options'; import { ILogger } from '../../utils/logging'; import { ISvgExportPostProcessor } from './svg-export-postprocessor'; /** * @deprecated Use the definition from `sprotty-protocol` instead. */ export interface ExportSvgAction extends ResponseAction { kind: typeof ExportSvgAction.KIND; svg: string; responseId: string; options?: ExportSvgOptions; } export declare namespace ExportSvgAction { const KIND = "exportSvg"; function create(svg: string, requestId: string, options?: ExportSvgOptions): ExportSvgAction; } export declare class SvgExporter { protected options: ViewerOptions; protected actionDispatcher: ActionDispatcher; protected log: ILogger; protected postprocessors: ISvgExportPostProcessor[]; export(root: SModelRootImpl, request?: RequestExportSvgAction): void; protected createSvg(svgElementOrig: SVGSVGElement, root: SModelRootImpl, options?: ExportSvgOptions, cause?: Action): string; protected copyStyles(source: Element, target: Element, skippedProperties: string[]): void; protected getBounds(root: SModelRootImpl, document: Document): Bounds; } //# sourceMappingURL=svg-exporter.d.ts.map