[]
• new ColorScheme(name
, background1
, background2
, text1
, text2
, accent1
, accent2
, accent3
, accent4
, accent5
, accent6
, link
, followedLink
)
Creates a ColorScheme instance.
classdesc
Represents the theme color.
example
//This example creates colors for the theme.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("accent 1 30");
Name | Type | Description |
---|---|---|
name |
string |
The owner that contains the named variable. |
background1 |
string |
The theme color for background1. |
background2 |
string |
The theme color for background2. |
text1 |
string |
The theme color for text1. |
text2 |
string |
The theme color for text2. |
accent1 |
string |
The theme color for accent1. |
accent2 |
string |
The theme color for accent2. |
accent3 |
string |
The theme color for accent3. |
accent4 |
string |
The theme color for accent4. |
accent5 |
string |
The theme color for accent5. |
accent6 |
string |
The theme color for accent6. |
link |
string |
The color of the link. |
followedLink |
string |
The color of the followedLink. |
▸ accent1(value?
): any
Gets or sets the accent1 theme color of the color scheme.
example
//This example sets the accent1 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("accent 1 30");
Name | Type | Description |
---|---|---|
value? |
string |
The accent1 theme color string. |
any
If no value is set, returns the accent1 theme color; otherwise, returns the color scheme.
▸ accent2(value?
): any
Gets or sets the accent2 theme color of the color scheme.
example
//This example sets the accent2 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().accent2("red");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("accent 2");
Name | Type | Description |
---|---|---|
value? |
string |
The accent2 theme color string. |
any
If no value is set, returns the accent2 theme color; otherwise, returns the color scheme.
▸ accent3(value?
): any
Gets or sets the accent3 theme color of the color scheme.
example
//This example sets the accent3 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().accent3("yellow");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("accent 3");
Name | Type | Description |
---|---|---|
value? |
string |
The accent3 theme color string. |
any
If no value is set, returns the accent3 theme color; otherwise, returns the color scheme.
▸ accent4(value?
): any
Gets or sets the accent4 theme color of the color scheme.
example
//This example sets the accent4 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().accent4("blue");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("accent 4");
Name | Type | Description |
---|---|---|
value? |
string |
The accent4 theme color string. |
any
If no value is set, returns the accent4 theme color; otherwise, returns the color scheme.
▸ accent5(value?
): any
Gets or sets the accent5 theme color of the color scheme.
example
//This example sets the accent5 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().accent5("blue");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("accent 5");
Name | Type | Description |
---|---|---|
value? |
string |
The accent5 theme color string. |
any
If no value is set, returns the accent5 theme color; otherwise, returns the color scheme.
▸ accent6(value?
): any
Gets or sets the accent6 theme color of the color scheme.
example
//This example sets the accent6 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().accent6("blue");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("accent 6");
Name | Type | Description |
---|---|---|
value? |
string |
The accent6 theme color string. |
any
If no value is set, returns the accent6 theme color; otherwise, returns the color scheme.
▸ background1(value?
): any
Gets or sets the background1 theme color of the color scheme.
example
//This example sets the background1 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().background1("orange");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("background 1");
Name | Type | Description |
---|---|---|
value? |
string |
The background1 theme color string. |
any
If no value is set, returns the background1 theme color; otherwise, returns the color scheme.
▸ background2(value?
): any
Gets or sets the background2 theme color of the color scheme.
example
//This example sets the background2 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().background2("orange");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("background 2");
Name | Type | Description |
---|---|---|
value? |
string |
The background2 theme color string. |
any
If no value is set, returns the background2 theme color; otherwise, returns the color scheme.
▸ followedHyperlink(value?
): any
Gets or sets the followed hyperlink theme color of the color scheme.
example
//This example sets the followedHyperline color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().followedHyperlink("orange");
ntheme.colors().hyperlink("red");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("followedHyperlink");
activeSheet.getCell(2, 0).backColor("hyperlink");
Name | Type | Description |
---|---|---|
value? |
string |
The followed hyperlink theme color string. |
any
If no value is set, returns the followed hyperlink theme color; otherwise, returns the color scheme.
▸ getColor(name
): string
Gets the color based on the theme color.
example
//This example gets the theme color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().followedHyperlink("orange");
ntheme.colors().hyperlink("red");
ntheme.colors().name("test");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("followedHyperlink");
activeSheet.getCell(2, 0).backColor("hyperlink");
var cname = ntheme.getColor("accent 1");
alert(cname);
Name | Type | Description |
---|---|---|
name |
string |
The theme color name. |
string
The theme color.
▸ hyperlink(value?
): any
Gets or sets the hyperlink theme color of the color scheme.
example
//This example sets the hyperline color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().followedHyperlink("orange");
ntheme.colors().hyperlink("red");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("followedHyperlink");
activeSheet.getCell(2, 0).backColor("hyperlink");
Name | Type | Description |
---|---|---|
value? |
string |
The hyperlink theme color string. |
any
If no value is set, returns the hyperlink theme color; otherwise, returns the color scheme.
▸ name(value?
): any
Gets or sets the name of the color scheme.
example
//This example sets the theme name.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().name("green theme");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
Name | Type | Description |
---|---|---|
value? |
string |
The name. |
any
If no value is set, returns the name; otherwise, returns the color scheme.
▸ textColor1(value?
): any
Gets or sets the textcolor1 theme color of the color scheme.
example
//This example sets the textColor1 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().textColor1("orange");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("Text 1");
Name | Type | Description |
---|---|---|
value? |
string |
The textcolor1 theme color string. |
any
If no value is set, returns the textcolor1 theme color; otherwise, returns the color scheme.
▸ textColor2(value?
): any
Gets or sets the textcolor2 theme color of the color scheme.
example
//This example sets the textColor2 color.
var ntheme = new GC.Spread.Sheets.Theme("customThemeColor");
ntheme.colors().accent1("lightgreen");
ntheme.colors().textColor2("orange");
activeSheet.currentTheme(ntheme);
activeSheet.getCell(0, 0).backColor("accent 1");
activeSheet.getCell(1, 0).backColor("Text 2");
Name | Type | Description |
---|---|---|
value? |
string |
The textcolor2 theme color string. |
any
If no value is set, returns the textcolor2 theme color; otherwise, returns the color scheme.