WinUI and removing transparency on menus

Posted by: lime_harpist.0n on 1 September 2022, 1:59 am EST

    • Post Options:
    • Link

    Posted 1 September 2022, 1:59 am EST

    I would like to have the background on menu bars, menuitem and flyouts without the transparency.

    Does anyone have a solution to this? I can set a unique color/brush but I want the current color/brush just without the transparency.

  • Posted 2 September 2022, 4:53 am EST

    Hi Soham,

    WinUI applies the transparency to the controls based on the Window transparency setting. If your windows is set to allow transparency then WinUI app will also show transparent effects.

    So, the only possible way is to disable the windows transparency as follows:

    1. Go to windows settings.
    2. Navigate to Personalization > Colors.
    3. Turn of the ‘Transparency effects’ toggle button.

    Note: This will disable the transparency effects at the windows level.

    I hope it will help.

    Best Regards,

    Kartik

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels