This documentation is archived and is not being maintained.

ControlPaint.DrawMenuGlyph Method (Graphics, Rectangle, MenuGlyph)

.NET Framework 1.1

Draws the specified menu glyph on a menu item control within the specified bounds and on the specified surface.

[Visual Basic]
Overloads Public Shared Sub DrawMenuGlyph( _
   ByVal graphics As Graphics, _
   ByVal rectangle As Rectangle, _
   ByVal glyph As MenuGlyph _
public static void DrawMenuGlyph(
 Graphics graphics,
 Rectangle rectangle,
 MenuGlyph glyph
public: static void DrawMenuGlyph(
 Graphics* graphics,
 Rectangle rectangle,
 MenuGlyph glyph
public static function DrawMenuGlyph(
   graphics : Graphics,
 rectangle : Rectangle,
 glyph : MenuGlyph


The Graphics to draw on.
The Rectangle that represents the dimensions of the glyph.
One of the MenuGlyph values that specifies the image to draw.


When owner-drawing 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 need to draw a Checkmark glyph on the MenuItem.


Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

ControlPaint Class | ControlPaint Members | System.Windows.Forms Namespace | ControlPaint.DrawMenuGlyph Overload List | MenuItem | MenuGlyph