Custom Flat-style Numeric UpDown Control
-
For those looking for an alternative to the standard Winforms numeric UpDown Control, I made a Custom Flat-style Numeric UpDown Control that functions largely the same but does not have those pesky tiny buttons. The real reason for developing this however was that in some of our (complicated) forms in .NET 6 the standard numeric UpDown Control behaved very badly when changing the font size of the form and sometimes completely disappeared :~ It can be downloaded here: GitHub - A Custom Numeric UpDown Control[^]
-
For those looking for an alternative to the standard Winforms numeric UpDown Control, I made a Custom Flat-style Numeric UpDown Control that functions largely the same but does not have those pesky tiny buttons. The real reason for developing this however was that in some of our (complicated) forms in .NET 6 the standard numeric UpDown Control behaved very badly when changing the font size of the form and sometimes completely disappeared :~ It can be downloaded here: GitHub - A Custom Numeric UpDown Control[^]
An article or tip is probably a better place to put this?
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!
-
An article or tip is probably a better place to put this?
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!
Exactly! but it still needs some work I think, so when it's finished (and I have some time left) it will become a tip :-\
-
For those looking for an alternative to the standard Winforms numeric UpDown Control, I made a Custom Flat-style Numeric UpDown Control that functions largely the same but does not have those pesky tiny buttons. The real reason for developing this however was that in some of our (complicated) forms in .NET 6 the standard numeric UpDown Control behaved very badly when changing the font size of the form and sometimes completely disappeared :~ It can be downloaded here: GitHub - A Custom Numeric UpDown Control[^]
What I would want in a NumericUpDown is the ability to set a factor for the up and down buttons rather than adding/subtracting a value, multiply/divide by the factor. So, for instance, I can set it to double/halve the value. On the other hand, I have only one place I want that, so it's not a high priority for me.
-
What I would want in a NumericUpDown is the ability to set a factor for the up and down buttons rather than adding/subtracting a value, multiply/divide by the factor. So, for instance, I can set it to double/halve the value. On the other hand, I have only one place I want that, so it's not a high priority for me.
-
What I would want in a NumericUpDown is the ability to set a factor for the up and down buttons rather than adding/subtracting a value, multiply/divide by the factor. So, for instance, I can set it to double/halve the value. On the other hand, I have only one place I want that, so it's not a high priority for me.
Should not be too difficult to implement, just clone the GitHub repo and add a new property named Factor, if it has a value use it in the AddValue() method :-\
-
For those looking for an alternative to the standard Winforms numeric UpDown Control, I made a Custom Flat-style Numeric UpDown Control that functions largely the same but does not have those pesky tiny buttons. The real reason for developing this however was that in some of our (complicated) forms in .NET 6 the standard numeric UpDown Control behaved very badly when changing the font size of the form and sometimes completely disappeared :~ It can be downloaded here: GitHub - A Custom Numeric UpDown Control[^]
I've started using semi-opaque backgrounds (UWP) on my app's "tool boxes" (user controls). The buttons (with icons) reflect the transparency while the icons remain fully opaque. It actually works (with a border); the visuals behind can be made out (a topo map in this case) so you don't have to scroll or drag things out of the way. Like a HUD. Probably "gained" 25% screen space. A different experience.
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
-
What I would want in a NumericUpDown is the ability to set a factor for the up and down buttons rather than adding/subtracting a value, multiply/divide by the factor. So, for instance, I can set it to double/halve the value. On the other hand, I have only one place I want that, so it's not a high priority for me.
-
Ooooohhhhhh...
-
I've started using semi-opaque backgrounds (UWP) on my app's "tool boxes" (user controls). The buttons (with icons) reflect the transparency while the icons remain fully opaque. It actually works (with a border); the visuals behind can be made out (a topo map in this case) so you don't have to scroll or drag things out of the way. Like a HUD. Probably "gained" 25% screen space. A different experience.
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
Please post an article on this.
«The mind is not a vessel to be filled but a fire to be kindled» Plutarch
-
For those looking for an alternative to the standard Winforms numeric UpDown Control, I made a Custom Flat-style Numeric UpDown Control that functions largely the same but does not have those pesky tiny buttons. The real reason for developing this however was that in some of our (complicated) forms in .NET 6 the standard numeric UpDown Control behaved very badly when changing the font size of the form and sometimes completely disappeared :~ It can be downloaded here: GitHub - A Custom Numeric UpDown Control[^]
In your spare time ? Alt + up/down ... +- by factor #1 Control up/down... +- by factor #2 Then handle Alt + Control and right/left key variations :)
«The mind is not a vessel to be filled but a fire to be kindled» Plutarch
-
In your spare time ? Alt + up/down ... +- by factor #1 Control up/down... +- by factor #2 Then handle Alt + Control and right/left key variations :)
«The mind is not a vessel to be filled but a fire to be kindled» Plutarch
Nice suggestions, but my problem is where to find the time, we are in the midst of a very time consuming upgrade from .NET 4.8 to .NET 6, and so far it hasn't exactly been a smooth ride (due the complex nature of our main application).
-
Please post an article on this.
«The mind is not a vessel to be filled but a fire to be kindled» Plutarch
It sounds complicated but it's just using an "acrylic" Brush (available in UWP) instead of a regular "solid color brush" for the background. The same facility can be added to WPF using the "community tool kit". Or you can fake it varying the opacity of the background of a control ... though the "acrylic" brush seems to be a bit more "glassy".
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I