[]
        
首页
开发者学堂
文档
论坛
市场
生态机会
活动
立即试用
(Showing Draft Content)

DataBarFillType

Enum Class DataBarFillType

java.lang.Object
java.lang.Enum<DataBarFillType>
com.grapecity.documents.excel.DataBarFillType
All Implemented Interfaces:
Serializable, Comparable<DataBarFillType>, Constable

public enum DataBarFillType extends Enum<DataBarFillType>
指定数据条如何用颜色填充。

使用此枚举可以控制条件格式中的数据条是以纯色填充还是渐变填充显示。


 worksheet.getRange("A1:A3").setValue(new Object[][] {
     {10},
     {20},
     {30}
 });
 IDataBar dataBar = worksheet.getRange("A1:A3").getFormatConditions().addDatabar();
 dataBar.setBarFillType(DataBarFillType.Gradient);
 
  • Enum Constant Details

    • Solid

      public static final DataBarFillType Solid
      指定数据条使用均匀的纯色填充,而不是渐变。
    • Gradient

      public static final DataBarFillType Gradient
      指定数据条使用颜色渐变填充,而不是纯色。
  • Method Details

    • values

      public static DataBarFillType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static DataBarFillType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null