I have a suggestion or two about the mark-up for the RadButton control.
At the moment, it is possible to include the ToggleStates element for a standard or link button. Likewise, it is possible to set the ToggleType attribute. What I'm about to suggest will, I think, make the mark-up a little more logical and, potentially, improve the functionality of the control overall.
First, I think that you should remove the "ToggleButton" option from the ButtonType attribute. A RadButton would be either a StandardButton or a LinkButton. The button (standard or link) takes on ToggleButton properties if it has a <ToggleStates> child element.
By default an RadButton would be a StandardButton unless, either, the ButtonType="LinkButton" or the <RadButtonToggleState> elements had a ImageUrl property.
The ToggleType property should be moved to the <ToggleStates> element as it has no relevance unless the button is to function as a ToggleButton.
So, you'd define a standard button with or without icons pretty much as you do now, and the same would go for a link button. But either (and the visual appearance wouldn't change unless the developer wanted it to) could be made in to a ToggleButton by simply adding <RadButtonToggleState> elements to the button's <ToggleStates> element. Creating a custom toggle button, like those in your examples, would work in the same way, but the user now has access to a standard-looking button that will toggle through a set of states just changing the text, or the icon or both.
I'm fairly confident that someone will tell me that it's too late now to change the code for the release of Q3, but I hope not. If, however, it is, I hope that you would consider introducing these changes, or something like them in a future release..
--
Stuart
At the moment, it is possible to include the ToggleStates element for a standard or link button. Likewise, it is possible to set the ToggleType attribute. What I'm about to suggest will, I think, make the mark-up a little more logical and, potentially, improve the functionality of the control overall.
First, I think that you should remove the "ToggleButton" option from the ButtonType attribute. A RadButton would be either a StandardButton or a LinkButton. The button (standard or link) takes on ToggleButton properties if it has a <ToggleStates> child element.
By default an RadButton would be a StandardButton unless, either, the ButtonType="LinkButton" or the <RadButtonToggleState> elements had a ImageUrl property.
The ToggleType property should be moved to the <ToggleStates> element as it has no relevance unless the button is to function as a ToggleButton.
So, you'd define a standard button with or without icons pretty much as you do now, and the same would go for a link button. But either (and the visual appearance wouldn't change unless the developer wanted it to) could be made in to a ToggleButton by simply adding <RadButtonToggleState> elements to the button's <ToggleStates> element. Creating a custom toggle button, like those in your examples, would work in the same way, but the user now has access to a standard-looking button that will toggle through a set of states just changing the text, or the icon or both.
I'm fairly confident that someone will tell me that it's too late now to change the code for the release of Q3, but I hope not. If, however, it is, I hope that you would consider introducing these changes, or something like them in a future release..
--
Stuart