Merge pull request #18941 from paultrudel/pres-dim-error-fix-30

fix: Page dimension parse error with decimal numbers
This commit is contained in:
Gustavo Trott 2023-10-13 17:47:26 -03:00 committed by GitHub
commit 21a05950ba
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -84,11 +84,11 @@ object MsgBuilder {
val imgUrl = new URL(svgUrl) val imgUrl = new URL(svgUrl)
val imgContent = XML.load(imgUrl) val imgContent = XML.load(imgUrl)
val w = (imgContent \ "@width").text.replaceAll("[^\\d]", "") val w = (imgContent \ "@width").text.replaceAll("[^.0-9]", "")
val h = (imgContent \ "@height").text.replaceAll("[^\\d]", "") val h = (imgContent \ "@height").text.replaceAll("[^.0-9]", "")
val width = w.toInt val width = w.toDouble
val height = h.toInt val height = h.toDouble
PresentationPageConvertedVO( PresentationPageConvertedVO(
id = id, id = id,