duck
duck

Reputation: 867

Changing MenuItem

Using the style code below, I am able to change every menu item on my form to white with no border. It works great except when the item is a sub menu item, like in the attached picture. I cannot figure out how to remove the inner-border around it. I figured 0 border with a white background would do the trick. Any idea how to remove it? enter image description here

    <Style TargetType="{x:Type MenuItem}">
        <Setter Property="Background" Value="White"></Setter>
        <Setter Property="BorderBrush" Value="White"></Setter>
        <Setter Property="BorderThickness" Value="0"></Setter>
        <Style.Triggers>

        </Style.Triggers>
    </Style>

Upvotes: 1

Views: 71

Answers (1)

Daniel Oliveira
Daniel Oliveira

Reputation: 1141

I think you will have to edit the ControlTemplate for the submenu, like showed here.

Upvotes: 2

Related Questions