[api-minor] Deprecate the imageLayer
functionality
This functionality has never been used anywhere in the PDF.js library/viewer itself, since it was added in 2013. Furthermore this functionality is, and has always been, *completely untested* and also unmaintained. Finally, there's (at least) one old issue about `appendImage` not returning the correct position; see issue 4182. All-in-all, it seems that keeping very old, untested, unmaintained, and partially broken code around probably isn't what we want here. (On the off-chance that any future a11y-work requires getting access to image-positions, it'd likely be much better to re-implement the necessary functionality from scratch and also make sure that it's properly tested from the beginning.)
This commit is contained in:
parent
3c8aeb445a
commit
118da8e85d
@ -13,6 +13,13 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import {
|
||||
deprecated,
|
||||
getCurrentTransform,
|
||||
getCurrentTransformInverse,
|
||||
getRGB,
|
||||
PixelsPerInch,
|
||||
} from "./display_utils.js";
|
||||
import {
|
||||
FeatureTest,
|
||||
FONT_IDENTITY_MATRIX,
|
||||
@ -26,12 +33,6 @@ import {
|
||||
Util,
|
||||
warn,
|
||||
} from "../shared/util.js";
|
||||
import {
|
||||
getCurrentTransform,
|
||||
getCurrentTransformInverse,
|
||||
getRGB,
|
||||
PixelsPerInch,
|
||||
} from "./display_utils.js";
|
||||
import {
|
||||
getShadingPattern,
|
||||
PathType,
|
||||
@ -1184,6 +1185,9 @@ class CanvasGraphics {
|
||||
this.baseTransform = getCurrentTransform(this.ctx);
|
||||
|
||||
if (this.imageLayer) {
|
||||
deprecated(
|
||||
"The `imageLayer` functionality will be removed in the future."
|
||||
);
|
||||
this.imageLayer.beginLayout();
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user