Back to Devexpress

RibbonPageCategoryOptions.AutoCorrectForeColor Property

windowsforms-devexpress-dot-xtrabars-dot-ribbon-dot-ribbonpagecategoryoptions-49b85943.md

latest2.7 KB
Original Source

RibbonPageCategoryOptions.AutoCorrectForeColor Property

Gets or sets whether Ribbon categories automatically adjust their forecolors depending on a background color. Fore colors are adjusted when a contrast between fore and background colors is too low.

Namespace : DevExpress.XtraBars.Ribbon

Assembly : DevExpress.XtraBars.v25.2.dll

NuGet Package : DevExpress.Win.Navigation

Declaration

csharp
[DefaultValue(DefaultBoolean.Default)]
[DXCategory("Appearance")]
[XtraSerializableProperty]
public DefaultBoolean AutoCorrectForeColor { get; set; }
vb
<DefaultValue(DefaultBoolean.Default)>
<DXCategory("Appearance")>
<XtraSerializableProperty>
Public Property AutoCorrectForeColor As DefaultBoolean

Property Value

TypeDefaultDescription
DefaultBooleanDefault

DefaultBoolean.False or DefaultBoolean.Default if categories should use text fore colors assigned to their Appearance.ForeColor properties (or use a default skin color for categories with no custom color assigned). DefaultBoolean.True if categories should automatically change their caption fore colors.

|

Available values:

NameDescriptionReturn Value
True

The value is true.

|

0

| | False |

The value is false.

|

1

| | Default |

The value is specified by a global option or a higher-level object.

|

2

|

Property Paths

You can access this nested property as listed below:

Object TypePath to AutoCorrectForeColor
RibbonControl

.OptionsPageCategories .AutoCorrectForeColor

|

Remarks

The figure below illustrates how two Ribbon categories with LightPink and Gainsboro background colors change their fore color from light to dark when the AutoCorrectForeColor setting is enabled. The active skin is “Basic”.

See Also

RibbonPageCategoryOptions Class

RibbonPageCategoryOptions Members

DevExpress.XtraBars.Ribbon Namespace