[api-minor] Deprecate the SVG back-end

This commit is contained in:
Jonas Jenwald 2022-07-16 10:24:24 +02:00
parent de7d1d2167
commit 90bf659b29

View File

@ -14,6 +14,7 @@
*/ */
/* globals __non_webpack_require__ */ /* globals __non_webpack_require__ */
import { deprecated, DOMSVGFactory } from "./display_utils.js";
import { import {
FONT_IDENTITY_MATRIX, FONT_IDENTITY_MATRIX,
IDENTITY_MATRIX, IDENTITY_MATRIX,
@ -24,7 +25,6 @@ import {
Util, Util,
warn, warn,
} from "../shared/util.js"; } from "../shared/util.js";
import { DOMSVGFactory } from "./display_utils.js";
import { isNodeJS } from "../shared/is_node.js"; import { isNodeJS } from "../shared/is_node.js";
/** @type {any} */ /** @type {any} */
@ -467,6 +467,9 @@ if (
SVGGraphics = class { SVGGraphics = class {
constructor(commonObjs, objs, forceDataSchema = false) { constructor(commonObjs, objs, forceDataSchema = false) {
deprecated(
"The SVG back-end is no longer maintained and *may* be removed in the future."
);
this.svgFactory = new DOMSVGFactory(); this.svgFactory = new DOMSVGFactory();
this.current = new SVGExtraState(); this.current = new SVGExtraState();