Spread Windows Forms 7.0 Product Documentation
FocusRenderer Property
See Also  Example Support Options
FarPoint.Win.Spread Assembly > FarPoint.Win.Spread Namespace > FpSpread Class : FocusRenderer Property


Glossary Item Box

Gets or sets the focus indicator renderer for drawing the focus rectangle in the component.

Syntax

Visual Basic (Declaration) 
Public Property FocusRenderer As IFocusIndicatorRenderer
Visual Basic (Usage)Copy Code
Dim instance As FpSpread
Dim value As IFocusIndicatorRenderer
 
instance.FocusRenderer = value
 
value = instance.FocusRenderer
C# 
public IFocusIndicatorRenderer FocusRenderer {get; set;}

Property Value

IFocusIndicatorRenderer instance that determines the focus renderer

Remarks

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.

Example

This example changes the focus rectangle to solid.
C#Copy Code
fpSpread1.FocusRenderer = new FarPoint.Win.Spread.SolidFocusIndicatorRenderer(Color.Cyan, 1);
Visual BasicCopy Code
FpSpread1.FocusRenderer = New FarPoint.Win.Spread.SolidFocusIndicatorRenderer(Color.Cyan, 1)

Requirements

Target Platforms: Windows 2000 Professional (SP4), Windows 2000 Server, Windows 2003 Server (SP1), Windows 2008, Windows XP (SP2), Windows Vista, Windows 7, Windows 8

See Also

© 2002-2014 ComponentOne, a division of GrapeCity. All Rights Reserved.