IFlexCelPalette Interface
Interface for passing palette and theme information. XlsFile implements IFlexCelPalette, so you can pass any XlsFile object whenever you need to use this interface.
Syntax
Namespace: FlexCel.Core
public interface IFlexCelPalette;
Methods
Name | Description |
---|---|
NearestColorTheme | Returns the most similar entry on the theme palette for a given color. |
NearestColorIndex | Returns the most similar entry on the excel palette for a given color. |
GetColorTheme | Returns a color from the active theme palette, including semantic colors. Only has effect in Excel 2007. To get the full theme, look at ExcelFile.GetTheme |
GetColorPalette | Returns a color from the color palette. This method will throw an exception if its "index" parameter is bigger than ExcelFile.ColorPaletteCount, (for example, for an automatic color). To get the real color, use ExcelFile.GetColorPalette(Int32, TUIColor) |
PaletteContainsColor | Returns true if the internal color palette contains the exact specified color. Note that Excel 2007 doesn't use the color palette, so this method is not needed there. |
GetTheme | This is an advanced method, that allows you to get the full theme in use. Normally you will just want to replace colors, and you can do this with ExcelFile.SetColorTheme(TPrimaryThemeColor, TDrawingColor) and ExcelFile.GetColorTheme(TPrimaryThemeColor)...[more] |
GetThemeNoClone | Internal use. This won't clone the internal structure for more performance. |
GetColorPaletteVersion | Internal use. Every time the palette changes, the number returned is incremented. |
Properties
Name | Description |
---|---|
ColorPaletteCount | The number of entries on an Excel color palette. This is always 56. |