https://bz.apache.org/bugzilla/show_bug.cgi?id=65280
Bug ID: 65280
Summary: Upper cap missing while extracting LumMod percentage
value in method getPercentageValue of XSLFColor class
, returning more than 100% value in case of ppt if
lumMod is 120000
Product: POI
Version: unspecified
Hardware: PC
Status: NEW
Severity: normal
Priority: P2
Component: XSLF
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---
I am using poi version poi-ooxml-3.11.jar
While converting .pptx to images ,i am getting exception as
java.lang.IllegalArgumentException: Color parameter outside of expected range:
Red Green
at java.awt.Color.testColorValueRange(Color.java:310)
RCA:
In getPercentageValue mehod of XSLFColor class there is no upper bound if
percentage is coming more than 100% .
I am converting a pptx file whose color theme is coming with value as
<xml-fragment pos="0"
xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main">
<a:schemeClr val="phClr">
<a:tint val="90000"/>
<a:satMod val="92000"/>
<a:lumMod val="120000"/>
</a:schemeClr>
</xml-fragment>
Now lumMod percentage is coming as 120% which exceeds RGB color space of
(255,255,255) and exception is coming
In getPercentageValue method check should be there if percentage is exceeding
100% then it should return 100
--
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]