Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.poi.xslf.usermodel
Class XSLFColor

    java.lang.Object
      org.apache.poi.xslf.usermodel.XSLFColor

    @Beta
    @Internal
    public class XSLFColor

extends java.lang.Object

Encapsulates logic to read color definitions from DrawingML and convert them to java.awt.Color

Constructor Summary
`XSLFColor(org.apache.xmlbeans.XmlObject obj, XSLFTheme theme, org.openxmlformats.schemas.drawingml.x2006.main.CTSchemeColor phClr)`

Method Summary
`java.awt.Color` | `getColor()`
`ColorStyle` | `getColorStyle()`
`int` | `getShade()` specifies a darker version of its input color.
`int` | `getTint()` specifies a lighter version of its input color.
`org.apache.xmlbeans.XmlObject` | `getXmlObject()`
`protected void` | `setColor(java.awt.Color color)` Sets the solid color

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### XSLFColor

    public XSLFColor(org.apache.xmlbeans.XmlObject obj,
                     XSLFTheme theme,
                     org.openxmlformats.schemas.drawingml.x2006.main.CTSchemeColor phClr)

Method Detail

### getXmlObject

    @Internal
    public org.apache.xmlbeans.XmlObject getXmlObject()

### getColor

    public java.awt.Color getColor()

  Returns:
    the displayed color as a Java Color. If not color information was found in the supplied xml object then a null is returned.

### getColorStyle

    public ColorStyle getColorStyle()

### setColor

    @Internal
    protected void setColor(java.awt.Color color)

  Sets the solid color

  Parameters:
    `color` - solid color

### getShade

    public int getShade()

  specifies a darker version of its input color. A 10% shade is 10% of the input color combined with 90% black.

  Returns:
    the value of the shade specified as a percentage with 0% indicating minimal shade and 100% indicating maximum or -1 if the value is not set

### getTint

    public int getTint()

  specifies a lighter version of its input color. A 10% tint is 10% of the input color combined with 90% white.

  Returns:
    the value of the tint specified as a percentage with 0% indicating minimal tint and 100% indicating maximum or -1 if the value is not set

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 2017 The Apache Software Foundation or its licensors, as applicable.