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

Does Telerik Label suppurt "&" sign

3 Answers 129 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Haroon
Top achievements
Rank 1
Haroon asked on 22 Sep 2008, 04:34 AM
Hi Telerik Team,
I being trying to write some text (i.e. "A&&B") so that it should the displayed as "A&B" . The problem I am facing is that if I use "&&" between the displayed text is "A..." like and if I use "A&B" the displayed text would be "AB" (Second one is OK as its standard behaviour).

Can you please  help me that how can I display "A&B" text in Telerik Label.

Regards,
Haroon.

3 Answers, 1 is accepted

Sort by
0
John
Top achievements
Rank 1
answered on 22 Sep 2008, 08:32 PM
Haroon,
     You can change the UseMneumonic property to False which will allow you to display A&B in the label.  This will turn off the "A..." and "AB" behavior that you are seeing currently.

Hope this helps,
John Kellar
0
Haroon
Top achievements
Rank 1
answered on 23 Sep 2008, 02:45 AM
Hi John,
Thanks for the help.
The same thing happens with RadMenuItem and  there is no "UseMnemonic" property in case of RadMenu (Infact I have added the Menu Items in RadSpiultButton) can you please help me in this regard.

Regards,
Haroon.
0
Boyko Markov
Telerik team
answered on 25 Sep 2008, 12:17 PM
Hello Haroon,

Thank you for the additional feedback.

We have investigated the problems and found a problem in the TextPrimitive element (it is responsible for text drawing).

Basically, the problem lies in the fact that the TextPrimitive in RadLabel reports a smaller size than needed when & is used. Because of this, the text is displayed with "..." if the text is longer than the size of the label. If you type some letters after the & sign, you should be able to see it (e.g. "Test&& 123"). There are two workarounds to this issue until we fix it:
  1. You can place some spaces at the end of the text. This will enlarge the size of the text and the ampersand will become visible.
  2. You can use the "Edit UI Elements" menu form the smart tag to set the TextPrimitive.MinSize.Width property to a larger value. This will cause the same effect as the first solution. You should also set the AutoSize property to false and resize the label element manually. A more descriptive screenshot of the first part is attached.
Please, note that we do not support a way to enable/disable mnemonics in RadMenu. We will consider adding such.

The issues are now logged in our system and we will fix them as soon as possible.


Best wishes,
Boyko Markov
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
General Discussions
Asked by
Haroon
Top achievements
Rank 1
Answers by
John
Top achievements
Rank 1
Haroon
Top achievements
Rank 1
Boyko Markov
Telerik team
Share this question
or