NavigationView "crop" items text if PaneDisplayMode=LeftFluent #1086
Replies: 2 comments
-
I've made the button width into a property by changing the following source code: In
This creates a new property called
This will bind the width of this button to your dynamic property. Now you can change the width through the designer:
I hope the developers of this can embed this into their permanent codebase. |
Beta Was this translation helpful? Give feedback.
-
Alternatively, you could reduce the font size of your button: #934 Both these methods are of course workarounds for now. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone,
I started to play with WPF-UI and I think it's really great, so thank you guys for all effort that was put into it.
Ok, now, I'm pretty new to the WPF world and I'm a little bit frustrated with something. When using NavigationView, if I set PaneDisplayMode to LeftFluent, it "crops" the item text if it's too large. The sample in WPFUI Gallery has the same issue.
I try to use Snoop to find if there was a property that could change this behavior and what I found was that the Border control (MainBorder), inside the NavigationViewItem has a fixed width value of 60, defined in a resource called NavigationViewConstants (PaneFluentButtonWidth). If I change it (with Snoop) to another value, let's say 120, we then have more "room" and the text is displayed correctly.
So, my question, is there a way to change PaneFluentButtonWidth? Without need to override the NavigationViewItem whole template.
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions