I have a Xamribbon control, in which I have an ApplicationMenu with several MenuTool's as you can view in the code:
<igWPF:XamRibbon Theme="Onyx" IsMinimized="False" HorizontalAlignment="Right" VerticalAlignment="Top" IsEnabled="True" >
<igWPF:XamRibbon.ApplicationMenu >
<igWPF:ApplicationMenu UseLargeImages="True" Opened="ApplicationMenuOpened" Closed="ApplicationMenuClosed" >
<igWPF:MenuTool Caption="Prueba 1" LargeImage="/Imagenes/Bullet_check.png">
<igWPF:LabelTool Caption="Prueba 1"/>
<igWPF:MenuTool Caption="Prueba 1" LargeImage="/Imagenes/Bullet_check.png" >
<igWPF:ToggleButtonTool Caption="Prueba 1" SmallImage="/Imagenes/Bullet_check.png"/>
</igWPF:MenuTool>
<igWPF:MenuTool Caption="Prueba 2" LargeImage="/Imagenes/Bullet_check.png">
<igWPF:LabelTool Caption="Prueba 2"/>
<igWPF:ToggleButtonTool Caption="Prueba 2" SmallImage="/Imagenes/Bullet_check.png"/>
<igWPF:MenuTool Caption="Prueba 3" LargeImage="/Imagenes/Bullet_check.png">
<igWPF:LabelTool Caption="Prueba 3"/>
<igWPF:ToggleButtonTool Caption="Prueba 3" SmallImage="/Imagenes/Bullet_check.png"/>
</igWPF:ApplicationMenu>
</igWPF:XamRibbon.ApplicationMenu >
</igWPF:XamRibbon>
As you can check, at the end of each MenuTool there is a ToggleButtonTool, which is supposed to represent an external application.
MenuTool
ToggleButtonTool
My point is that, each time I add a new MenuTool with its corresponding ToggleButtonTool, I need all the path gets highlighted (from outer MenuTool to the ToggleButtonTool), in the same way a Windows does in the system start menu when a new application is installed:
I tried to do this by turning the "IsChecked" property to true, but this action only highlight the icon area, and not the whole MenuTool or ToggleButtonTool item. I though the way to get it would be setting true the "IsMouseOver" property, but it is an 'only read' property.
IsChecked
IsMouseOver
I have also tried to change background color of the items, but it is not working.
Anyone has done something similar and could help me, please? If you require further information please ask me :)
Thank you for your help in advance.
Regards,
Hello, Victor,
Please find attached a sample project application in which each menu item which IsChecked=true will be displayed the way you need. This is done by modifying the DefaultStyles of the control.
If you have any further questions on this matter please do not hesitate to let me know.
Sincerely,
Horen
Software Developer
Infragistics
Hello Horen,
I'm testing your solution and it's working great!! It is exactly what I needed. :D
Thank you very much!
Best regards,
Víctor
Hi Victor,
Thank you for the feedback. I'm glad you have resolved your issue.
Hi Horen,
The solution proposed is working great. However, it's a problem that I've tried to solve but I cannot fix. I would like that the MenuTool's and ToggleButtonTool's would maintain the MouseOver property, because with the previous solution there's no difference if mouse is over the ítem or not. Would it be possible to carry out?
Please, let me know if I have not expressed correctly what I am trying to develop.
Thank you very much in advance.
Hello Victor,
I glad to hear that my solution does what you needed.
It works perfectly. It's doing exactly what I was trying. Thank you very much for your help once more :D
I have attached an updated project in which the highlight is applied correctly after hovering over the items.