Skybound Rebar

RebarButtonRenderer.DrawText Method 

Draws the text of the button onto a specified Graphics object.

[Visual Basic]
Overridable Public Sub DrawText( _
   ByVal graphics As Graphics _
)
[C#]
public virtual void DrawText(
   Graphics graphics
);

Parameters

graphics
The Graphics surface on which the text is drawn.

Remarks

This method draws the text of a rebar button. The position of text in relation to the image is specified with the TextAlign property. You can obtain the bounds in which the text will be drawn by calling GetTextRectangle.

When visual styles are enabled and BandType is RebarBandType.MenuBar, the text is drawn using the SystemColors.HighlightText. Otherwise, the color of the text is specified by the ForeColor property.

If ShouldRenderText is false, no text is drawn.

See Also

RebarButtonRenderer Class | Skybound.Rebar.Rendering Namespace