Hello, what is the difference between UltraGridRow.Appearance vs UltraGridRow.CellAppearance? When would you use one over the other? Thanks.
Thank you.
Hi,
For the vast majority of applications, it doesn't really matter. You can use either one.
Basically, when a cell resolves what appearances it will use when painting, it goes through a resolution process that includes it's own appearances, the row appearances, the override appearances, etc. And this is further complicated by AppStyilst appearances.
The row.CellAppearance applies to every cell in the row. But as you probably noticed, the row.Appearance also applies to every cell in the row. The CellAppearance is applied first, so if you set both, the CellAppearance will take precedence.
Most of the time, the cells cover the row, but there are ways you can make it so that the row is visible behind the cells. For example, you could set CellPadding and this would create padding around the cells where the row is visible without being covered by a cell and so you might want the appearance of the row to be one color and the cells within that row be another color.
I think it might also be useful for cases where you are applying a row appearance via AppStylist. AppStylist generally takes precedence over the application settings. But the CellAppearance is more specific than the row appearance, so you could essentially use CellAppearance to override the AppStylist row UI Role in some cases.