Home » U++ Library support » U++ Widgets - General questions or Mixed problems » State of "button"
State of "button" [message #15143] |
Wed, 02 April 2008 17:32  |
cbpporter
Messages: 1427 Registered: September 2007
|
Ultimate Contributor |
|
|
OK, I've done it again! I had to write custom code to be able to do some very basic and common things with a button.
I'm a little unhappy with the state of button classes in U++. Button is by far the most advanced of them, but it does not feature a "down" state. A lot of my buttons need a down state. You can use ButtonOption, but that class is semi useless. Or you can use ToolButton, but that need a lot of visual tweaks to get it to behave nicely. Worst of all, if you change class, you have to modify a lot of code, since interfaces are different(one has Label, other has SetLabel).
So I propose a number of changes:
1. Uniform interface. Pretty self-explanatory.
2. Get rid of ButtonOption and add down state to Button (add typedef Button ButtonOption) or make ButtonOption inherit Button, add a label property, StyleDefault, etc.
3. Either add a StyleFlat to Button, or tweak ToolButton so that it can be used as a generic button.
4. Make styles compatible between button classes.
These are just some suggestions and the list is open, but before stable 2008 I think that it would be great if buttons wouldn't cause such headaches. I implemented partially on a by need bases a lot of these ideas, and would be relatively easy to gather them and implement this, but I need to know what you think.
|
|
|
 |
|
State of "button"
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
By: mrjt on Tue, 15 April 2008 10:48
|
 |
|
Re: State of "button"
By: mirek on Wed, 16 April 2008 10:17
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
By: mirek on Sat, 26 April 2008 09:59
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
By: mirek on Tue, 29 April 2008 19:30
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
By: mirek on Mon, 16 March 2009 10:31
|
 |
|
Re: State of "button"
By: mrjt on Mon, 16 March 2009 17:26
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
By: mirek on Thu, 19 March 2009 18:29
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
By: mirek on Thu, 19 March 2009 19:32
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
|
 |
|
Re: State of "button"
By: mirek on Fri, 20 March 2009 21:02
|
 |
|
Re: State of "button"
By: mirek on Thu, 19 March 2009 19:28
|
Goto Forum:
Current Time: Sun May 11 08:58:30 CEST 2025
Total time taken to generate the page: 0.01741 seconds
|