This is a migrated thread and some comments may be shown as answers.

Button like ApplicationBarIconButton

4 Answers 83 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
prog1
Top achievements
Rank 1
prog1 asked on 24 Mar 2011, 09:36 AM
I would like to have Buttons that can look like the ApplicationBarIconButton.
But I want to use them everywhere or build my own ApplicationBar.

They should be theme aware and it should be possible to switch text and Icon on and off.

Kind regards
Fabian

4 Answers, 1 is accepted

Sort by
0
Victor
Telerik team
answered on 30 Mar 2011, 08:39 AM
Hello Fabian,

 Thank you for writing.

You most likely need an instance of the ApplicationBarIconButton class that can serve as a protoype for the other buttons in your application. Since the ApplicationBarIconButton is not a dependency object and therefore not a Control child, you will not be able to provide templates or styles.

By default the Text and IconUri properties are configurable, that is, have public setters so you should be able to dynamically change them.

In order for the buttons to be theme aware, you will need to stick to a certain set of best practices when creating custom icons.
The text color is not configurable, unfortunately, and automatically changes with the theme.

In order to circumvent the limitations described above you will have to implement the application bar from scratch which could theoretically be done with RadWindow (which provides hardware acceleration) or with the default Popup control.

Best wishes,
Victor
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
prog1
Top achievements
Rank 1
answered on 31 Mar 2011, 09:48 AM
Hi Victor,

thanks for your explanations. 
What I found:
http://www.windowsphonegeek.com/articles/Creating-theme-friendly-UI--in-WP7-using-OpacityMask

Would be nice if telerik would offer a control like this, but till than I have to do the work ;-)
0
Georgi
Telerik team
answered on 05 Apr 2011, 03:32 PM
Hi Fabian,

Thanks for the link, we will consider implementing such a button in the near future. It is a very simple control that however seems to be pretty useful for our users.

Regards,
Georgi
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
prog1
Top achievements
Rank 1
answered on 05 Apr 2011, 04:26 PM
Hi Georgi,

thanks a lot. Great news for me.

Kind regards
Fabian
Tags
General Discussions
Asked by
prog1
Top achievements
Rank 1
Answers by
Victor
Telerik team
prog1
Top achievements
Rank 1
Georgi
Telerik team
Share this question
or