Draws the specified menu glyph on a menu item control within the specified bounds and on the specified surface, replacing System.Drawing.Color.White with the color specified in the backColor parameter and replacing System.Drawing.Color.Black with the color specified in the foreColor parameter.
- graphics
The System.Drawing.Graphics to draw on.
- rectangle
The System.Drawing.Rectangle that represents the dimensions of the glyph.
- glyph
One of the System.Windows.Forms.MenuGlyph values that specifies the image to draw.
- foreColor
The color that replaces System.Drawing.Color.White as the foreground color.
- backColor
The color that replaces System.Drawing.Color.Black as the background color.
When owner-drawing System.Windows.Forms.MenuItem controls, you need to verify property values to determine the correct glyph to draw or remove. For example, when the MenuItem.Checked property is set to true, you must call the MenuGlyph.Checkmark value of System.Windows.Forms.MenuGlyph to draw a check mark on the System.Windows.Forms.MenuItem.