Skip to main content
Box

PageCanvas.FillRectangle(RichEditBrushBase, Rectangle) Method

Draws a filled custom rectangle.

Namespace: DevExpress.XtraRichEdit.API.Layout

Assembly: DevExpress.RichEdit.v24.1.Core.dll

NuGet Packages: DevExpress.RichEdit.Core, DevExpress.Win.Navigation

Declaration

public void FillRectangle(
    RichEditBrushBase brush,
    Rectangle bounds
)

Parameters

Name Type Description
brush RichEditBrushBase

The RichEditBrushBasedescendant that sets the shape’s color and thickness.

bounds Rectangle

Sets the shape’s location and size.

Example

This code snippet illustrates the implementation of the PageCanvas.FillRectangle method. It draws a filled color rectangle in place of the numbering list mark.

View Example

Public Overrides Sub DrawNumberingListWithSeparatorBox(ByVal numberingListWithSeparatorBox As NumberingListWithSeparatorBox)
    If Form1.customDrawSeparator = True Then
        Canvas.FillRectangle(New RichEditBrush(Color.DarkRed), numberingListWithSeparatorBox.Bounds)
    Else
        MyBase.DrawNumberingListWithSeparatorBox(numberingListWithSeparatorBox)
    End If
End Sub

The following code snippets (auto-collected from DevExpress Examples) contain references to the FillRectangle(RichEditBrushBase, Rectangle) method.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also