We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

GridModelSelections.GetInvertStateRowCol has confusing name and broken links

Essential Suite release candidate. The description for this method says "Determines if the specified cell position is found in a range list." I would suggest that the grid would be more approachable for new customers if the method were named something like: IsRowColInRangeList() IsCellSelected() IsCellInRangeList() or something. "InvertState" means nothing. I can search the entire class reference for "InvertState" and no hits come up. Consequently it took me awhile to find this method. Also - the links for these are broken in the suite class reference help file: GridModelSelections.SetModelInt() GridControl.IntDrawInvertCell()

1 Reply

AD Administrator Syncfusion Team March 19, 2004 10:48 PM UTC

Below is the source with included help on that method. It relies on the GridRangeInfoList.AnyRangeContains which is seems to be a ''reasonably'' named method which is probably a better method to be aware of than GetInvertStateRowCol. The reason that this method is named GetInvertStateRowCol is that selections can be indicated by just inverting the selected range. If you turn off the AlphaBlend flag in AllowSelections, you can see this behavior. Historically, this is how selections were done. But with alphablending available with GDI+, the selections look better using blending. So, GetInvertStateRowCol makes more sense if you use inverting to mark selections. Thank you for reporting the broken links. We will get them fix. /// /// Determines if the specified cell position is found in a range list. /// /// The row index. /// The column index. /// The range list with ranges to be searched. /// true if cell position was found; false otherwise. public bool GetInvertStateRowCol(int rowIndex, int colIndex, GridRangeInfoList rl) { return rl != null && rl.AnyRangeContains(GridRangeInfo.Cell(rowIndex, colIndex)); }

Live Chat Icon For mobile
Up arrow icon