You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pdfbox.apache.org by ti...@apache.org on 2022/01/20 18:20:51 UTC
svn commit: r1897265 - /pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/handlers/CloudyBorder.java
Author: tilman
Date: Thu Jan 20 18:20:51 2022
New Revision: 1897265
URL: http://svn.apache.org/viewvc?rev=1897265&view=rev
Log:
PDFBOX-4892: LGTM fix
Modified:
pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/handlers/CloudyBorder.java
Modified: pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/handlers/CloudyBorder.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/handlers/CloudyBorder.java?rev=1897265&r1=1897264&r2=1897265&view=diff
==============================================================================
--- pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/handlers/CloudyBorder.java (original)
+++ pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/interactive/annotation/handlers/CloudyBorder.java Thu Jan 20 18:20:51 2022
@@ -85,7 +85,7 @@ class CloudyBorder
*/
void createCloudyRectangle(PDRectangle rd) throws IOException
{
- rectWithDiff = applyRectDiff(rd, lineWidth / 2);
+ rectWithDiff = applyRectDiff(rd, (float) (lineWidth / 2));
double left = rectWithDiff.getLowerLeftX();
double bottom = rectWithDiff.getLowerLeftY();
double right = rectWithDiff.getUpperRightX();
@@ -493,7 +493,7 @@ class CloudyBorder
}
}
- private PDRectangle applyRectDiff(PDRectangle rd, double min)
+ private PDRectangle applyRectDiff(PDRectangle rd, float min)
{
float rectLeft = annotRect.getLowerLeftX();
float rectBottom = annotRect.getLowerLeftY();
@@ -506,10 +506,10 @@ class CloudyBorder
rectRight = Math.max(rectLeft, rectRight);
rectTop = Math.max(rectBottom, rectTop);
- double rdLeft;
- double rdBottom;
- double rdRight;
- double rdTop;
+ float rdLeft;
+ float rdBottom;
+ float rdRight;
+ float rdTop;
if (rd != null)
{