/// <summary> /// Gets the first back color for the short text. /// </summary> /// <param name="style">Content style.</param> /// <param name="state">Palette value should be applicable to this state.</param> /// <returns>Color value.</returns> public override Color GetContentShortTextColor1(PaletteContentStyle style, PaletteState state) { // Do we need to override the text color if (OverrideTextColor(state) && (PaletteContent != null)) { return(PaletteContent.GetContentShortTextColor1(state)); } else { return(base.GetContentShortTextColor1(style, state)); } }
/// <summary> /// Gets the color to use in place of the image map color. /// </summary> /// <param name="style">Content style.</param> /// <param name="state">Palette value should be applicable to this state.</param> /// <returns>Color value.</returns> public override Color GetContentImageColorTo(PaletteContentStyle style, PaletteState state) { // If allowed to override then get the map color Color mapColor = OverrideImageColor(state); // If mapping occuring then return the target remap color if ((mapColor != Color.Empty) && (PaletteContent != null)) { PaletteState getState = PaletteState; // Honor the button disabled state if (state == PaletteState.Disabled) { getState = PaletteState.Disabled; } return(PaletteContent.GetContentShortTextColor1(getState)); } else { return(base.GetContentImageColorTo(style, state)); } }