question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to override CommandBar's MoreButton "EllipsisButton" style

See original GitHub issue

Describe the bug

I want to override the style of the CommandBar’s “more button”. This button is using the EllipsisButton style but overriding this style does not have any effect.

Steps to reproduce the bug

Use the following code and start the app.

<Page [...]>
    <Page.Resources>
        <Style x:Key="EllipsisButton" TargetType="Button">
            <Setter Property="Foreground" Value="Red" />
            <Setter Property="BorderThickness" Value="4" />
            <Setter Property="BorderBrush" Value="Red" />
        </Style>
    </Page.Resources>

    <Grid>
        <CommandBar DefaultLabelPosition="Right">
            <AppBarButton Icon="Accept" Label="Action 1" />
            <AppBarButton Icon="Account" Label="Action 2" />

            <CommandBar.SecondaryCommands>
                <AppBarButton Icon="Add" Label="Action 3" />
                <AppBarButton Icon="AddFriend" Label="Action 4" />
            </CommandBar.SecondaryCommands>
        </CommandBar>
    </Grid>
</Page>

The “more button” content should be red and it should have a big red border.

Expected behavior

The custom style should be applied to the “more button”

Screenshots

image

NuGet package version

Microsoft.UI.Xaml 2.7.0

Windows app type

  • UWP
  • Win32

Device form factor

Desktop

Windows version

No response

Additional context

No response

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
chingucodingcommented, Sep 30, 2021

I would like to fix this.

0reactions
msftbot[bot]commented, Jan 3, 2023

🎉This issue was addressed in #6004, which has now been successfully released as Microsoft.UI.Xaml v2.8.2.🎉

Handy links:

Read more comments on GitHub >

github_iconTop Results From Across the Web

Hiding the ellipsis within an AppBar
Open your page in Blend, right click on CommandBar > Edit Template > Edit a Copy. Then make sure you select Define in...
Read more >
[Solved]-Hiding the ellipsis within an AppBar-C#
Open your page in Blend, right click on CommandBar > Edit Template > Edit a Copy. Then make sure you select Define in...
Read more >
Stylus Themes · GitHub
github-dark.css ... {color:#8f9d6a!important;font-weight:700!important}.pl-pdc{color:#5f5a60!important;font-style:italic!important} ... CodeMirror-overwrite .
Read more >
xamlbrewer | XAML Brewer, by Diederik Krols | Page 5
a Frame to host the pages on a background with parallax effect,; a Hamburger button, and; a CommandBar for secondary navigation. Here's how...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found