Spread Windows Forms 13.0 Product Documentation
FarPoint.Win.Spread Assembly / FarPoint.Win.Spread Namespace / FpSpread Class / FocusRenderer Property

In This Topic
    FocusRenderer Property (FpSpread)
    In This Topic
    Gets or sets the focus indicator renderer for drawing the focus rectangle in the component.
    Public Property FocusRenderer As IFocusIndicatorRenderer
    Dim instance As FpSpread
    Dim value As IFocusIndicatorRenderer
    instance.FocusRenderer = value
    value = instance.FocusRenderer
    public IFocusIndicatorRenderer FocusRenderer {get; set;}

    Property Value

    IFocusIndicatorRenderer instance that determines the focus renderer

    There are implementations of IFocusIndicatorRenderer that you can use to assign custom focus indicators with this property.

    • DefaultFocusIndicatorRenderer is the default renderer and applies unless you change it. You can customize the thickness of the line when you create a renderer based on the default renderer. You can create one with a custom thickness and assign it to with this property.
    • SolidFocusIndicatorRenderer draws a solid border using a custom color and thickness.
    • ImageFocusIndicatorRenderer uses an Image object. The image is drawn scaled to the size of the cell, so it may be stretched or contracted in width or height as needed to paint around the cell.
    This example changes the focus rectangle to solid.
    fpSpread1.FocusRenderer = new FarPoint.Win.Spread.SolidFocusIndicatorRenderer(Color.Cyan, 1);
    FpSpread1.FocusRenderer = New FarPoint.Win.Spread.SolidFocusIndicatorRenderer(Color.Cyan, 1)
    See Also