/// <summary> /// Draws a TextBox in the specified state, on the specified graphics /// surface, and within the specified bounds /// </summary> /// <param name="g">The Graphics to draw on</param> /// <param name="textRect">The Rectangle that represents the dimensions /// of the TextBox</param> /// <param name="clipRect">The Rectangle that represents the clipping area</param> /// <param name="state">A TextBoxStates value that specifies the /// state to draw the TextBox in</param> public static void DrawTextBox(Graphics g, Rectangle textRect, Rectangle clipRect, I3TextBoxStates state) { if (g == null || textRect.Width <= 0 || textRect.Height <= 0 || clipRect.Width <= 0 || clipRect.Height <= 0) { return; } if (I3ThemeManager.VisualStylesEnabled) { I3ThemeManager.DrawThemeBackground(g, I3ThemeClasses.TextBox, (int)I3TextBoxParts.EditText, (int)state, textRect, clipRect); } else { ControlPaint.DrawBorder3D(g, textRect, Border3DStyle.Sunken); } }
/// <summary> /// Draws a TextBox in the specified state, on the specified graphics /// surface, and within the specified bounds /// </summary> /// <param name="g">The Graphics to draw on</param> /// <param name="textRect">The Rectangle that represents the dimensions /// of the TextBox</param> /// <param name="state">A TextBoxStates value that specifies the /// state to draw the TextBox in</param> public static void DrawTextBox(Graphics g, Rectangle textRect, I3TextBoxStates state) { I3ThemeManager.DrawTextBox(g, textRect, textRect, state); }