[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.Theme

Theme Class

Contains the theme information.

A Theme describes a workbook theme, including its name, whether it is built in, and the associated IThemeColorScheme and IThemeFontScheme.

Inheritance
Theme
Implements
Namespace: GrapeCity.Documents.Excel
Assembly: DS.Documents.Excel.dll
Syntax
public class Theme : ITheme
Public Class Theme
    Implements ITheme
Examples
ITheme theme = new Theme("Custom Theme", Themes.Berlin);
string name = theme.Name;
bool builtIn = theme.IsBuiltIn;
IThemeColorScheme colorScheme = theme.ThemeColorScheme;
IThemeFontScheme fontScheme = theme.ThemeFontScheme;

Constructors

Name Description
Theme(string, ITheme)

Initializes a new instance of the Theme class with the specified theme name and base theme.

Creates a custom theme by copying settings from the specified base ITheme. If baseTheme is null, the new theme is initialized from the Office theme.

The theme name must be unique and must not be empty or match a built-in theme name.

Properties

Name Description
IsBuiltIn

Gets whether the theme is a built-in theme.

Built-in themes are the predefined themes returned by the Themes utility methods. Custom themes created programmatically return false.

Name

Gets or sets the name of the theme.

The returned name identifies the current theme and can be used to look up a theme from the Themes collection.

ThemeColorScheme

Gets or sets the color scheme within the theme.

Represents a color scheme within the theme and provides access to the theme colors by IThemeColor.

ThemeFontScheme

Gets or sets the font scheme within the theme.

Represents the theme font scheme and provides access to the major and minor theme font collections through Major and Minor.