Class DrawingUtils
Contains static methods related to drawing.
public static class DrawingUtils
- Inheritance
-
DrawingUtils
Methods
- DebugImageFromTextWithFontStyle(TextAndFontStyle[])
Creates debug image from the specified array of TextAndFontStyle.
- DistanceIsLess(PointD, PointD, double)
Compares distance between two points and specified value.
- DrawBorder(AbstractControl?, Graphics, RectD, BorderSettings?)
Draws border in the specified rectangle of the drawing context.
- DrawBorderWithBrush(Graphics, Brush, RectD, Thickness)
Draws rectangle border using the specified brush and FillRectangle(Brush, RectD). This method doesn't fill background, it only draws border.
- DrawBorderWithBrush(Graphics, Brush, RectD, double)
Draws rectangle border using the specified brush and FillRectangle(Brush, RectD). This method doesn't fill background, it only draws border.
- DrawBordersWithBrush(Graphics, Brush, RectD[], Thickness[]?)
Draws rectangles border using FillRectangle(Brush, RectD).
- DrawDoubleBorder(Graphics, RectD, Color, Color)
Draws inner and outer border with the specified colors.
- DrawHorzLine(Graphics, Brush, PointD, double, double)
Draws horizontal line using FillRectangle(Brush, RectD).
- DrawVertLine(Graphics, Brush, PointD, double, double)
Draws vertical line using FillRectangle(Brush, RectD).
- FillBorderRectangle(Graphics, RectD, Brush?, BorderSettings?, bool, AbstractControl?)
Fills rectangle background and draws its border using the specified border settings.
- GetBottomLineRect(RectD, double)
Gets rectangle of the bottom border edge with the specified width.
- GetCenterLineHorz(RectD)
Gets rectangle of the horizontal center line of the rectangle.
- GetCenterLineVert(RectD)
Gets rectangle of the vertical center line of the rectangle.
- GetCheckBoxSize(AbstractControl, CheckState, VisualControlState)
Gets default checkbox size.
- GetDistance(PointD, PointD)
Calculates distance between two points.
- GetDistanceSquared(PointD, PointD)
Gets squared distance between two points.
- GetLeftLineRect(RectD, double)
Gets rectangle of the left border edge with the specified width.
- GetPointOnCircle(PointD, double, double)
Gets point on circle.
- GetRightLineRect(RectD, double)
Gets rectangle of the right border edge with the specified width.
- GetTopLineRect(RectD, double)
Gets rectangle of the top border edge with the specified width.
- ImageFromAction(double, Func<Graphics, SizeD>, Action<Graphics>?)
Creates Image with the size specified by
sizeAndDrawFunc
and with pixels filled withdrawAction
(orsizeAndDrawFunc
if it is null).
- ImageFromTextWithBoldTag(string, double, Font, Color, Color?)
Creates image from the specified text with html bold tags.
- ImageFromTextWithFontStyle(TextAndFontStyle[], double, Font, Color, Color?)
Creates image from the specified array of TextAndFontStyle.
- IsPointInCircle(PointD, PointD, double)
Gets whether point is inside the circle.
- MeasureText(IEnumerable, Font, Graphics, double)
Calculates total size of the text strings.
- SetDebugBackgroundToParents(AbstractControl?)
Sets background of the control's parents to Red, Green, Blue and Yellow colors.
- WrapTextLineToList(string, ref double, Font, Graphics)
Performs word wrapping of the single text line which doesn't contain new line characters.
- WrapTextToList(string, ref double, Font, Graphics)
Performs word wrapping of the multiple text lines which can contain new line characters.
- WrapTextToMultipleLines(string, ref double, Font, Graphics)
Performs word wrapping of the text.