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

BorderLineStyle

Enum Class BorderLineStyle

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

public enum BorderLineStyle extends Enum<BorderLineStyle>
指定边框的线型。

将此枚举与边框相关 API(例如 IBorder.setLineStyle(BorderLineStyle))一起使用,以控制单元格或区域边框的绘制方式。


 IRange range = worksheet.getRange("A1:B2");
 range.setValue("Test");
 range.getBorders().get(BordersIndex.EdgeBottom).setColor(Color.GetBlue());
 range.getBorders().get(BordersIndex.EdgeBottom).setLineStyle(BorderLineStyle.Thick);
 
  • Enum Constant Details

    • None

      public static final BorderLineStyle None
      指定不应用边框。
    • Hair

      public static final BorderLineStyle Hair
      指定一个发丝细的边框。
    • DashDotDot

      public static final BorderLineStyle DashDotDot
      指定短划线-点-点边框。
    • DashDot

      public static final BorderLineStyle DashDot
      指定一个点划线边框。
    • Dotted

      public static final BorderLineStyle Dotted
      指定一个点线边框。
    • Dashed

      public static final BorderLineStyle Dashed
      指定一个虚线边框。
    • Thin

      public static final BorderLineStyle Thin
      指定细边框线样式。
    • MediumDashDotDot

      public static final BorderLineStyle MediumDashDotDot
      指定中等划线-点-点边框。
    • SlantDashDot

      public static final BorderLineStyle SlantDashDot
      指定一个斜杠虚线边框。
    • MediumDashDot

      public static final BorderLineStyle MediumDashDot
      指定一个中等点划线边框。
    • MediumDashed

      public static final BorderLineStyle MediumDashed
      指定中等虚线边框线。
    • Medium

      public static final BorderLineStyle Medium
      指定一个中等边框。
    • Thick

      public static final BorderLineStyle Thick
      指定一个粗线边框。
    • Double

      public static final BorderLineStyle Double
      指定双线边框。
  • Method Details

    • values

      public static BorderLineStyle[] 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 BorderLineStyle 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
    • getValue

      public int getValue()
      获取表示枚举常量的整数值。
      Returns:
      枚举常量的序数值
    • forValue

      public static BorderLineStyle forValue(int value)
      获取与指定整数值对应的枚举常量。

      使用此方法可将整数值(例如从 getValue() 获取的值)转换回匹配的 BorderLineStyle 常量。

      Parameters:
      value - 表示枚举常量的整数值。
      Returns:
      与指定值对应的 BorderLineStyle 枚举常量。
      Throws:
      ArrayIndexOutOfBoundsException - 如果 value 超出已定义枚举值的范围。