We are currently using Infragistics v14.1. With Infragistics v14.1 we have an issue (application is crashing due to a problem with XamDockManager). The issue was fixed with Infragistics v14.2. Therefore, we have to switch from v14.1 to v14.2.
We are customizing the Infragistic control styles and colors. Especially the ribbon is styled a lot. With v14.2 we now face an issue that we cannot restyle the colors of the RibbonButtonChrome anymore. Previously (v14.1) we customized the colors with for example the following two keys:
- igRibbon:RibbonBrushKeys.ButtonToolHoverCenterFillKey
- igRibbon:RibbonBrushKeys.ButtonToolCheckedCenterFillKey
and the colors got correctly applied to our button tools shown in the ribbon. With v14.2 the colors with the above mentioned keys are no longer applied to the ribbon button tools. Is RibbonButtonChrome using different keys in v14.2 than in v14.1? How to customize the ribbon button tool background with v14.2?
Hello unassal,
I have found that overriding the following two keys appears to modify the colors of a hovered and pressed ButtonTool with the latest service release for 14.2 (14.2.20142.2283):
RibbonBrushKeys.ButtonToolHoverCenterFillKeyRibbonBrushKeys.ButtonToolPressedCenterFillKey
I am rather unsure why the override for the HoverCenterFillKey is not working for you in 14.2, but perhaps you have a separate style for your ButtonTool or some theming applied to your XamRibbon? I am attaching a sample project to demonstrate the above.
If this sample project does not accurately depict the behavior that you are seeing in your application, would it be possible for you to please modify it and send it back such that it does? Or, if you have an isolated sample project of your own that you could share, that may be helpful as well.
Please let me know if you have any other questions or concerns on this matter.
Sincerely,AndrewAssociate Developer
Hi Andrew,
thank you very much for your reply and your sample project.
You are actually right with your assumption that we are using custom styles. Our styles are actually based of the Infragistics RibbonOffice2013.xmal styles. I managed to extend your original sample project to show you the issue. The only (real) change that I made to your project was to explicitly load the ORIGINAL default RibbonOffice2013.xaml into the resource dictionary in the file App.xaml.
Observation:
- Without loading RibbonOffice2013.xaml into the resource dictionary I am able to style the button backgrounds.
- With loading RibbonOffice2013.xaml into the resource dictionary specifying custom colors for the above mentioned keys have no effect anymore.
With v14.1 it was working. We see the issue only with v14.2
So what is the correct way to style the button tool background buttons using RibbonOffice2013.xaml and v14.2?
Thank you and best regards!