[]
• new TimelineStyles()
内置的时间线样式集合
▸ Static
dark1(): TimelineStyle
dark1风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.light1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.dark1();
timeline.style(style);
▸ Static
dark2(): TimelineStyle
dark2风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.light1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.dark2();
timeline.style(style);
▸ Static
dark3(): TimelineStyle
dark3风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.light1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.dark3();
timeline.style(style);
▸ Static
dark4(): TimelineStyle
dark4风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.light1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.dark4();
timeline.style(style);
▸ Static
dark5(): TimelineStyle
dark5风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.light1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.dark5();
timeline.style(style);
▸ Static
dark6(): TimelineStyle
dark6风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.light1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.dark6();
timeline.style(style);
▸ Static
light1(): TimelineStyle
light1风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.dark1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.light1();
timeline.style(style);
▸ Static
light2(): TimelineStyle
light2风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.dark1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.light2();
timeline.style(style);
▸ Static
light3(): TimelineStyle
light3风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.dark1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.light3();
timeline.style(style);
▸ Static
light4(): TimelineStyle
light4风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.dark1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.light4();
timeline.style(style);
▸ Static
light5(): TimelineStyle
light5风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.dark1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.light5();
timeline.style(style);
▸ Static
light6(): TimelineStyle
light6风格
代码示例
var spread = new GC.Spread.Sheets.Workbook(document.getElementById("ss"), { sheetCount: 2 });
var activeSheet = spread.getActiveSheet();
var datas = [
["1", "NewYork", new Date("1968/6/8"), "80", "180"],
["4", "NewYork", new Date("1972/7/3"), "72", "168"],
["4", "NewYork", new Date("1964/3/2"), "71", "179"],
["5", "Washington", new Date("1972/8/8"),"80", "171"],
["6", "Washington", new Date("1986/2/2"), "89", "161"],
["7", "Washington", new Date("2012/2/15"), "71", "240"]];
var table = activeSheet.tables.addFromDataSource("table1", 2, 2, datas);
var dataColumns = ["Name", "City", "Birthday", "Weight", "Height"];
table.setColumnName(0, dataColumns[0]);
table.setColumnName(1, dataColumns[1]);
table.setColumnName(2, dataColumns[2]);
table.setColumnName(3, dataColumns[3]);
table.setColumnName(4, dataColumns[4]);
var pivotTable = sheet.pivotTables.add('pivotTable1', table.name(), 11, 1);
var timeline = sheet.slicers.add('timeline1', 'pivotTable1', 'Birthday', GC.Spread.Sheets.Slicers.TimelineStyles.dark1(), GC.Spread.Sheets.Slicers.SlicerType.pivotTimeline);
var style = new GC.Spread.Sheets.Slicers.SlicerStyles.light6();
timeline.style(style);