From 46f6c45f6c2b7b899cb877591a06dac338ab6d91 Mon Sep 17 00:00:00 2001 From: PJ Fanning Date: Fri, 16 Nov 2018 07:57:49 +0000 Subject: [PATCH] put back XSSFColor(java.awt.Color clr) constructor git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1846701 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/poi/xssf/usermodel/XSSFColor.java | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFColor.java b/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFColor.java index ae206f3c34..be632b3c46 100644 --- a/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFColor.java +++ b/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFColor.java @@ -47,7 +47,7 @@ public class XSSFColor extends ExtendedColor { * @deprecated 3.17 beta 1 - pass the workbook styles indexed color map, if any */ @Deprecated - @Removal(version="3.19") + @Removal(version="4.2") public XSSFColor(CTColor color) { this(color, new DefaultIndexedColorMap()); } @@ -59,6 +59,7 @@ public class XSSFColor extends ExtendedColor { * @deprecated 4.0.0 - use the factory {@link #from(CTColor, IndexedColorMap)} method instead to check for null CTColor instances. Make private eventually */ @Deprecated + @Removal(version = "4.2") public XSSFColor(CTColor color, IndexedColorMap map) { this.ctColor = color; this.indexedColorMap = map; @@ -72,7 +73,7 @@ public class XSSFColor extends ExtendedColor { * @see #from(CTColor, IndexedColorMap) */ @Deprecated - @Removal(version="4.1") + @Removal(version="4.2") public XSSFColor() { this(CTColor.Factory.newInstance(), new DefaultIndexedColorMap()); } @@ -84,7 +85,18 @@ public class XSSFColor extends ExtendedColor { public XSSFColor(IndexedColorMap colorMap) { this(CTColor.Factory.newInstance(), colorMap); } - + + /** + * Create an instance of XSSFColor from the awt Color + * @param clr awt Color + * @deprecated 3.17 beta 1 - pass the workbook styles indexed color map, if any + */ + @Deprecated + @Removal(version="4.2") + public XSSFColor(java.awt.Color clr) { + this(clr, new DefaultIndexedColorMap()); + } + /** * TEST ONLY * @param clr awt Color