# Modifier.Foreground class

Namespace: [Grasshopper2.UI.Skinning](https://developer.rhino3d.com/api/gh2/namespace/grasshopper2.ui.skinning.md) · Assembly: [Grasshopper2](https://developer.rhino3d.com/api/gh2/assembly/grasshopper2.md)

```cs
public sealed class Modifier.Foreground : Modifier
```

Produces a foreground colour that reads against the incoming colour: white for dark colours, black for light ones, moved by the given percentage. At 100% the result is pure black or white.

## Constructors

- [Modifier.Foreground](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier.foreground/ctor.md)

## Fields

- [DarkThreshold](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier.foreground/darkthreshold.md): (static) Lightness below which a colour counts as dark and gets a light foreground. For neutral colours this agrees with the hand-tuned rule in ColourExtensionMethods.IsDarkBackground, which flips around 60% grey.

## Properties

- [Kind](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier.foreground/kind.md)
- [Percent](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier.foreground/percent.md)

## Methods

- [Apply](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier.foreground/apply.md)
- [ToText](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier.foreground/totext.md)

## Inherited Members

- From [Modifier](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier.md): [Dependencies](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier/dependencies.md), [ToString](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier/tostring.md), [WithoutReferences](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.skinning.modifier/withoutreferences.md)
