Class GridMetroStyle
Implements the Metro look and feel
Inheritance
Inherited Members
Namespace: Syncfusion.Windows.Forms
Assembly: Syncfusion.Shared.Base.dll
Syntax
public class GridMetroStyle : Disposable, IDisposable, IVisualStylesDrawing, IThemeStyle
Constructors
GridMetroStyle(GridVisualStyles)
Creates a new instance of GridMetroStyle class.
Declaration
public GridMetroStyle(GridVisualStyles style)
Parameters
Type | Name | Description |
---|---|---|
GridVisualStyles | style | The current visual style. |
GridMetroStyle(GridVisualStyles, GridMetroColors)
Declaration
public GridMetroStyle(GridVisualStyles style, GridMetroColors metroColors)
Parameters
Type | Name | Description |
---|---|---|
GridVisualStyles | style | |
GridMetroColors | metroColors |
GridMetroStyle(GridVisualStyles, Boolean)
Declaration
public GridMetroStyle(GridVisualStyles style, bool legacyStyle)
Parameters
Type | Name | Description |
---|---|---|
GridVisualStyles | style | |
System.Boolean | legacyStyle |
GridMetroStyle(GridVisualStyles, Boolean, Color, Color, Color, Color)
Declaration
public GridMetroStyle(GridVisualStyles style, bool legacyStyle, Color metroColorSelection, Color metroHoverColor, Color metroPressedColor, Color metroGroupBarColor)
Parameters
Type | Name | Description |
---|---|---|
GridVisualStyles | style | |
System.Boolean | legacyStyle | |
System.Drawing.Color | metroColorSelection | |
System.Drawing.Color | metroHoverColor | |
System.Drawing.Color | metroPressedColor | |
System.Drawing.Color | metroGroupBarColor |
GridMetroStyle(String)
Creates a new instance of GridMetroStyle class.
Declaration
public GridMetroStyle(string themeName)
Parameters
Type | Name | Description |
---|---|---|
System.String | themeName | The current theme name. |
Properties
SkinCollection
Declaration
public virtual GridMetroColors SkinCollection { get; }
Property Value
Type |
---|
GridMetroColors |
ThemeName
Gets the current theme name.
Declaration
public string ThemeName { get; }
Property Value
Type |
---|
System.String |
VisualStyle
Gets the current VisualStyles.
Declaration
public GridVisualStyles VisualStyle { get; }
Property Value
Type |
---|
GridVisualStyles |
Methods
DrawCheckBoxStyle(Graphics, Rectangle, ButtonState, Boolean)
Draws the CheckBox skins
Declaration
public virtual void DrawCheckBoxStyle(Graphics g, Rectangle rect, ButtonState state, bool mixedState)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Graphics | g | A System.Drawing.Graphics object. |
System.Drawing.Rectangle | rect | A System.Drawing.Rectangle object that represents the drawing area. |
System.Windows.Forms.ButtonState | state | The current state of the checkbox |
System.Boolean | mixedState | Specifies whether the button is tri-stated. |
DrawCheckBoxStyle(Graphics, Rectangle, ButtonState, Boolean, Boolean)
Draws the CheckBox skins
Declaration
public virtual void DrawCheckBoxStyle(Graphics g, Rectangle rect, ButtonState state, bool mixedState, bool intermediate)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Graphics | g | A System.Drawing.Graphics object. |
System.Drawing.Rectangle | rect | A System.Drawing.Rectangle object that represents the drawing area. |
System.Windows.Forms.ButtonState | state | The current state of the checkbox |
System.Boolean | mixedState | Specifies whether the button is tri-stated. |
System.Boolean | intermediate | Specifies Whether the button is Intermediate state |
DrawComboBoxStyle(Graphics, Rectangle, ThemedComboBoxDrawing.DropDownState, Color)
Draws the ComboBox skins
Declaration
public virtual void DrawComboBoxStyle(Graphics g, Rectangle rect, ThemedComboBoxDrawing.DropDownState state, Color clrBack)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Graphics | g | A System.Drawing.Graphics object. |
System.Drawing.Rectangle | rect | A System.Drawing.Rectangle object that represents the drawing area. |
ThemedComboBoxDrawing.DropDownState | state | The current state of the combo button. |
System.Drawing.Color | clrBack |
DrawHeaderStyle(Graphics, Rectangle, ThemedHeaderDrawing.HeaderState)
Draws the header skins
Declaration
public virtual void DrawHeaderStyle(Graphics g, Rectangle rect, ThemedHeaderDrawing.HeaderState state)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Graphics | g | A System.Drawing.Graphics object. |
System.Drawing.Rectangle | rect | A System.Drawing.Rectangle object that represents the drawing area. |
ThemedHeaderDrawing.HeaderState | state | The current state of the header. |
DrawPushButtonStyle(Graphics, Rectangle, ButtonState)
Draws the PushButton skins
Declaration
public virtual void DrawPushButtonStyle(Graphics g, Rectangle rect, ButtonState state)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Graphics | g | A System.Drawing.Graphics object. |
System.Drawing.Rectangle | rect | A System.Drawing.Rectangle object that represents the drawing area. |
System.Windows.Forms.ButtonState | state | The current state of the button. |
DrawRadioStyle(Graphics, Rectangle, ButtonState)
Draws the RadioButton skins
Declaration
public virtual void DrawRadioStyle(Graphics g, Rectangle rect, ButtonState state)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Graphics | g | A System.Drawing.Graphics object. |
System.Drawing.Rectangle | rect | A System.Drawing.Rectangle object that represents the drawing area. |
System.Windows.Forms.ButtonState | state | The current state of the radio button |
DrawSpinButtonStyle(Graphics, Rectangle, ButtonID, ButtonState, Color)
Draws the SpinButton skins
Declaration
public virtual void DrawSpinButtonStyle(Graphics g, Rectangle rect, ButtonID btnId, ButtonState btnState, Color clrBack)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Graphics | g | A System.Drawing.Graphics object. |
System.Drawing.Rectangle | rect | A System.Drawing.Rectangle object that represents the drawing area. |
ButtonID | btnId | An integer that represents the type of the button. |
System.Windows.Forms.ButtonState | btnState | The current state of the spin button. |
System.Drawing.Color | clrBack |
GetGroupDropAreaColors(out Color, out Color, out Color)
Returns the backcolor and header interior for GroupDropArea.
Declaration
public virtual bool GetGroupDropAreaColors(out Color backColor, out Color headerBorderTop, out Color headerBorderLeft)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | backColor | The back color for GroupDropArea |
System.Drawing.Color | headerBorderTop | The top border color for GroupDropArea header |
System.Drawing.Color | headerBorderLeft | The left border color for GroupDropArea header |
Returns
Type |
---|
System.Boolean |
GetHeaderBorderColors(out Color, out Color, out Color, out Color)
Returns the Header Border Colors.
Declaration
public virtual bool GetHeaderBorderColors(out Color clrBottom, out Color clrRight, out Color clrInteriorFirst, out Color clrInteriorLast)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | clrBottom | The bottom border color |
System.Drawing.Color | clrRight | The right border color |
System.Drawing.Color | clrInteriorFirst | The gradient start color for the header interior |
System.Drawing.Color | clrInteriorLast | The gradient end color for the header interior |
Returns
Type |
---|
System.Boolean |
GetHeaderBottomBorderStyle(out Color, out GridBottomBorderWeight)
Returns the Header Border styles.
Declaration
public virtual bool GetHeaderBottomBorderStyle(out Color clrBottomBorder, out GridBottomBorderWeight borderWeight)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | clrBottomBorder | |
GridBottomBorderWeight | borderWeight | The bottom border weight. |
Returns
Type | Description |
---|---|
System.Boolean | returns the weight and color of bottom border. |
GetHeaderColors(out Color, out Color, out Color)
Header style color of Grid
Declaration
public virtual bool GetHeaderColors(out Color backColor, out Color hoverColor, out Color pressedColor)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | backColor | Header color |
System.Drawing.Color | hoverColor | hover color |
System.Drawing.Color | pressedColor | pressed color |
Returns
Type |
---|
System.Boolean |
GetHeaderTextColors(out Color, out Color, out Color)
Declaration
public virtual bool GetHeaderTextColors(out Color normalTextColor, out Color hoverTextColor, out Color pressedColor)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | normalTextColor | |
System.Drawing.Color | hoverTextColor | |
System.Drawing.Color | pressedColor |
Returns
Type |
---|
System.Boolean |
GetSortIconBrush(out Brush, out Pen)
Returns the SortIcon interior
Declaration
public virtual void GetSortIconBrush(out Brush brush, out Pen pen)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Brush | brush | The brush used to fill the sort icon |
System.Drawing.Pen | pen | The pen used to draw the sort icon |