ThmxTheme.GetThemeShadeByName method (String, Boolean)
Gets a theme shade by name
Namespace: Microsoft.SharePoint.Utilities
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'Declaration
Public Function GetThemeShadeByName ( _
themeColorName As String, _
fixContrast As Boolean _
) As Color
'Usage
Dim instance As ThmxTheme
Dim themeColorName As String
Dim fixContrast As Boolean
Dim returnValue As Color
returnValue = instance.GetThemeShadeByName(themeColorName, _
fixContrast)
public Color GetThemeShadeByName(
string themeColorName,
bool fixContrast
)
Parameters
themeColorName
Type: System.StringA theme shade name string of the format: ColorName[-ShadeName] where valid ShadeNames are: Darkest, Darker, Medium, Lighter, Lightest (and no shade to get the color's default shade).
fixContrast
Type: System.BooleanWhether to edit the contrast of the color based on whether the theme as a whole is inverted.
Return value
Type: System.Drawing.Color
A color representing the theme shade.