[]
        
(Showing Draft Content)

GC.Spread.Sheets.LineBorder

类: LineBorder

Spread.Sheets.LineBorder

Table of contents

构造方法

属性

构造方法

constructor

new LineBorder(color?, style?)

边框

代码示例

//本示例创建一个边框
var border = new GC.Spread.Sheets.LineBorder
border.color = "#7FFFD4";
border.style = GC.Spread.Sheets.LineStyle.double;
var cell = activeSheet.getCell(1, 1, GC.Spread.Sheets.SheetArea.viewport);
cell.borderLeft(border);

参数

属性名 类型
color? string
style? LineStyle

属性

color

color: string

边框的颜色 使用已知的颜色名称或十六进制样式颜色值 默认值为黑色

代码示例

//本示例设置了颜色属性
var border = new GC.Spread.Sheets.LineBorder
border.color = "#7FFFD4";
border.style = GC.Spread.Sheets.LineStyle.double;
var cell = activeSheet.getCell(1, 1, GC.Spread.Sheets.SheetArea.viewport);
cell.borderLeft(border);

style

style: LineStyle

边框线的线条样式默认值为空

代码示例

//本示例设置了style属性
var border = new GC.Spread.Sheets.LineBorder
border.color = "#7FFFD4";
border.style = GC.Spread.Sheets.LineStyle.double;
var cell = activeSheet.getCell(1, 1, GC.Spread.Sheets.SheetArea.viewport);
cell.borderLeft(border);