From 0c91eeba07ff9df39c6bbb9b940f88b066928fc3 Mon Sep 17 00:00:00 2001 From: Anshul Singhvi Date: Tue, 5 Nov 2024 14:53:22 -0800 Subject: [PATCH] Allow negative values in PDF bounding boxes (#61) --- src/rendering/pdf_utils.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rendering/pdf_utils.jl b/src/rendering/pdf_utils.jl index 93737e1..9f055f7 100644 --- a/src/rendering/pdf_utils.jl +++ b/src/rendering/pdf_utils.jl @@ -128,7 +128,7 @@ function get_pdf_bbox(path::String) println(read(err, String)) error() end - bbox_match = match(r"%%BoundingBox: ([0-9.]+) ([0-9.]+) ([0-9.]+) ([0-9.]+)", result) + bbox_match = match(r"%%BoundingBox: ([-0-9.]+) ([-0-9.]+) ([-0-9.]+) ([-0-9.]+)", result) return parse.(Int, ( bbox_match.captures[1], bbox_match.captures[2],