Proposal: Add IsReadOnly / IsValueLocked property to NumberBox
See original GitHub issueThe NumberBox
control is very useful.
In many cases I want to make the property that’s bound to it’s ValueProperty
unchangeable, keeping it readable, which is what the IsReadOnly
property does with the TextBox
control.
If it had an event like the TextChanging
event of TextBox
, there could be a work around, but it doesn’t have that.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:6
- Comments:7 (6 by maintainers)
Top Results From Across the Web
WinUI - NumberBox
Identifies the PreventKeyboardDisplayOnProgrammaticFocus dependency property. This documentation applies to WinUI 2 for UWP (for WinUI in the Windows App ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
How about some kind of lock icon that will be visible when it is locked? Like this:
This way user can easily distinguish it with editable NumberBoxes. Besides, if the spin buttons are inlined, then in
IsReadOnly
mode, those spins buttons won’t be visible anymore. That’s another indicator.@MuziburRahman It looks nice but no other control uses this convention. I think the lock button should be a proposal for the TextBox to start. Such visual cues should really be uniform in all of WinUI. However, for some controls this convention wouldn’t always work so well – when existing search or calendar icons are present for example.