Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
9364
Setting cell Appearance attributes relative to another cell
posted

 From a earlier post, I read that the Appearance set in code take precedence over the AppStylist setting. I have not spent time working with AppStylist but as I understand if affects the Appearance objects for the cells

In my grid, some cells need to have certain display attributes different relative to other cells. For example, some cell need bold fonts but the other attributes should be what AppStylist decides. In other cases, I want different foreground color for text but other attributes as set by AppStylist.That way when the AppStylist is used, it would affect the default look of the cell while the code would apply the special attributes to those cell relative to that default look.

Possible?

Thanks!

Parents
  • 469350
    Verified Answer
    Offline posted

    The appearance of a cell is resolved through a very robust process. The cell looks at it's own appearance, then the CellAppearance of the column, then the CellAppearance of the Row, then it takes into account the selected or active state, and then when you add AppStylist into it, it becomes quite mind-boggling. Smile

    But what you are describing here is very easy. The Appearance resolution only resolves properties that have actually been set. So if you set a cell.Appearance.ForeColor, then only the forecolor is resolved. If the BackColor is not set, it will get resolved by some other appearances further up the chain.

Reply Children