https://issues.apache.org/bugzilla/show_bug.cgi?id=55075
Bug ID: 55075
Summary: SXSSF: Pictures skewed on rows which have non-default
height
Product: POI
Version: 3.9
Hardware: PC
Status: NEW
Severity: normal
Priority: P2
Component: SXSSF
Assignee: [email protected]
Reporter: [email protected]
Created attachment 30405
--> https://issues.apache.org/bugzilla/attachment.cgi?id=30405&action=edit
patch fixing the problem (see description and comments in the code in the
files)
picture.resize() skews pictures in SXSSF if the picture is in a row having
non-default height. As we set the row height so that the picture fits into one
row in our code, this results in pictures scaled sometimes by a factor 2 or 3
in height, but having their correct width, looking very ugly.
The reason is that the XSSF code to which the SXSSF code delegates the size
calculation checks the rows in the XSSF sheet for their height, and - as all
rows are in the SXSSF sheet - does not find any rows and assumes the default
row height.
I have attached a fix for the problem that works fine with POI 3.9. This
contains two new SXSSF classes which in the current 3.9 code do not exist, as
their role is taken by the XSSF classes, and a one line change of SXSSFSheet:
method createDrawingPatriarch() in line 1195 should return the new SXSSFDrawing
instead of an XSSFDrawing.
I would assume that in addition to Picture, Comment and Chart may have similar
issues, but as we do not need them, I did not check that.
Of course, as always with SXSSF, if the row is already flushed out, there will
be problems.
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]