Interface IGridCellRenderer
Namespace: Syncfusion.UI.Xaml.CellGrid.GridCellRenderer
Assembly: Syncfusion.SfCellGrid.UWP.dll
Syntax
public interface IGridCellRenderer : IDisposable
Properties
CurrentCellElement
Gets a value indicating the current cell(GridCell) UIElement in
Declaration
UIElement CurrentCellElement { get; }
Property Value
Type | Description |
---|---|
Windows.UI.Xaml.UIElement | An instance of |
CurrentCellRendererElement
Gets a value indicating edit UIElement of current cell. It should be null when current cell is not in editing.
Declaration
UIElement CurrentCellRendererElement { get; }
Property Value
Type | Description |
---|---|
Windows.UI.Xaml.UIElement | An instance of |
DisplayElementOptimization
Gets or sets a value indicating whether to load the UIElement to display its content or not.
Declaration
bool DisplayElementOptimization { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true it will loads the display element for the cell only when it have content which should not empty; otherwise, false. |
Grid
Gets or sets the value indicating the instance of SfCellGrid.
Declaration
SfCellGrid Grid { get; set; }
Property Value
Type | Description |
---|---|
SfCellGrid | An instance of SfCellGrid |
HasCurrentCellState
Gets a value indicating whether the current cell renderer is set or not.
Declaration
bool HasCurrentCellState { get; }
Property Value
Type | Description |
---|---|
System.Boolean | Returns true if the current cell state is maintained; otherwise , false. |
SupportDrawingOptimization
Gets or sets a value whether the cell content should be drawn or not. If true, draw its content else loads display element to display its content.
Declaration
bool SupportDrawingOptimization { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true if the user wants to draw the content instead of loading the display uiElement; otherwise, false. |
SupportRenderOptimization
Gets or sets a value indicates whether the edit element directly loads to display the content even the cell is not in edit mode.
Declaration
bool SupportRenderOptimization { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true if the renderer supports directly to the drawing context ; otherwise, false. |
UseOnlyRendererElement
Gets or sets a value indicates whether to use the cell element (GridCell) to display its content.
Declaration
bool UseOnlyRendererElement { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true if the grid cell is placed inside the renderer element; otherwise, false. |
Methods
Arrange(RowColumnIndex, UIElement, Rect)
Invoked when the visual children of cell is arranged in view.
Declaration
void Arrange(RowColumnIndex cellRowColumnIndex, UIElement uiElement, Rect cellRect)
Parameters
Type | Name | Description |
---|---|---|
RowColumnIndex | cellRowColumnIndex | The Coordinates of the cell. |
Windows.UI.Xaml.UIElement | uiElement | The corresponding UIElement that is to be arranged. |
Windows.Foundation.Rect | cellRect | The corresponding size of cell element for arranging the UIElement. |
BeginEdit(RowColumnIndex, GridCell, GridStyleInfo, String)
Declaration
bool BeginEdit(RowColumnIndex CellRowColumnIndex, GridCell EditElement, GridStyleInfo Style, string text)
Parameters
Type | Name | Description |
---|---|---|
RowColumnIndex | CellRowColumnIndex | |
GridCell | EditElement | |
GridStyleInfo | Style | |
System.String | text |
Returns
Type |
---|
System.Boolean |
CharacterReceived(CharacterReceivedEventArgs)
Declaration
void CharacterReceived(CharacterReceivedEventArgs args)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Core.CharacterReceivedEventArgs | args |
ClearRecycleBin()
Clears all the items from RecycleBin.
Declaration
void ClearRecycleBin()
EndEdit(RowColumnIndex, GridCell, GridStyleInfo)
Declaration
bool EndEdit(RowColumnIndex cellRowColumnIndex, GridCell cellElement, GridStyleInfo style)
Parameters
Type | Name | Description |
---|---|---|
RowColumnIndex | cellRowColumnIndex | |
GridCell | cellElement | |
GridStyleInfo | style |
Returns
Type |
---|
System.Boolean |
GetControlValue()
Used to get the control value for the current cell.
Declaration
object GetControlValue()
Returns
Type | Description |
---|---|
System.Object | null. |
GetFormattedText(GridStyleInfo)
Used to get the formatted text for the particular cell
Declaration
string GetFormattedText(GridStyleInfo style)
Parameters
Type | Name | Description |
---|---|---|
GridStyleInfo | style | An instance of IStyle. |
Returns
Type | Description |
---|---|
System.String | An empty string |
Measure(RowColumnIndex, UIElement, Size)
Determines the size of the current cell in
Declaration
void Measure(RowColumnIndex cellRowColumnIndex, UIElement uiElement, Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
RowColumnIndex | cellRowColumnIndex | Coordinates of a cell. |
Windows.UI.Xaml.UIElement | uiElement | Corresponing UI element to measure . |
Windows.Foundation.Size | availableSize | The size of element. |
PrepareUIElements(RowColumnIndex, GridCell, GridStyleInfo, String, Boolean)
Declaration
GridCell PrepareUIElements(RowColumnIndex cellRowColumnIndex, GridCell cellContainer, GridStyleInfo style, string text, bool isInEdit)
Parameters
Type | Name | Description |
---|---|---|
RowColumnIndex | cellRowColumnIndex | |
GridCell | cellContainer | |
GridStyleInfo | style | |
System.String | text | |
System.Boolean | isInEdit |
Returns
Type |
---|
GridCell |
RaiseSaveChanges()
Invoked to save the current cell changes in
Declaration
void RaiseSaveChanges()
ResetCurrentCellState()
Resets or updates the current cell state and style.
Declaration
void ResetCurrentCellState()
SetControlValue(Object)
Used to set the value for the current cell.
Declaration
bool SetControlValue(object value)
Parameters
Type | Name | Description |
---|---|---|
System.Object | value | Current cell value. |
Returns
Type |
---|
System.Boolean |
SetCurrentCellState(RowColumnIndex, UIElement, Boolean, Boolean)
Set the current cell state when the current cell is active.
Declaration
void SetCurrentCellState(RowColumnIndex currentCellIndex, UIElement currentCellElement, bool isInEditing, bool isFocused)
Parameters
Type | Name | Description |
---|---|---|
RowColumnIndex | currentCellIndex | Coordinates of a current cell |
Windows.UI.Xaml.UIElement | currentCellElement | An instance of |
System.Boolean | isInEditing | True or False . |
System.Boolean | isFocused | True or False . |
SetFocus(Boolean)
Used to invoke the Focus method to set the focus on the given UIElement.
Declaration
void SetFocus(bool needToFocus)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | needToFocus | True or False . |
ShouldGridTryToHandleKeyDown(KeyRoutedEventArgs)
Handles all the key down operations for the current cell in
Declaration
bool ShouldGridTryToHandleKeyDown(KeyRoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
Windows.UI.Xaml.Input.KeyRoutedEventArgs | e | An System.Windows.Input.KeyEventArgs that contains the event data. |
Returns
Type | Description |
---|---|
System.Boolean | True or False. |
UnloadUIElements(GridCell)
Invoked when the cell is scrolled out of view or unloaded from the view.
Declaration
void UnloadUIElements(GridCell uiElement)
Parameters
Type | Name | Description |
---|---|---|
GridCell | uiElement | An instance of GridCell. |
UpdateCellStyle(RowColumnIndex, GridCell, GridStyleInfo, String, Boolean)
Declaration
void UpdateCellStyle(RowColumnIndex cellRowColumnIndex, GridCell uiElement, GridStyleInfo style, string text, bool isInEdit)
Parameters
Type | Name | Description |
---|---|---|
RowColumnIndex | cellRowColumnIndex | |
GridCell | uiElement | |
GridStyleInfo | style | |
System.String | text | |
System.Boolean | isInEdit |