6 Answers, 1 is accepted
Thank you for your question.
You should select RadPanel's Smart Tag, trigger the "Edit UI Elements" command, locate the child TextPrimitive and apply the desired value to the TextAlignment property (see the attached screenshot ).
Another option is to add this line in form's load event:
this
.radPanel1.PanelElement.PanelText.TextAlignment = ContentAlignment.TopCenter;
I hope this helps. Do not hesitate to contact us if you have other questions.
Kind regards,
Peter
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
The first and preferred method DOES change the setting in the "Edit UI Elements" dialog; however at runtime there is no difference whatsoever. The text is still centered.
The 2nd method doesn't exist as a property. From my Panel.PanelElement I can find no "PanelText" property.
I'm using the demo version of your latest control set.
Declare a member variable...
TextPrimitive m_text = null;
In the constructor...
TextStyle.TextAlignment = ContentAlignment.TopCenter;
In the class...
private TextPrimitive TextStyle
{
get
{
if (null == m_text)
{
foreach (RadElement element in m_pnl.PanelElement.Children)
{
if (element.GetType() == typeof(TextPrimitive))
{
m_text = (TextPrimitive)element;
break;
}
}
}
return m_text;
}
}
Please, excuse us for the inconvenience. Yes, we introduced this property in Q1 2010 and I am happy that you managed to find a solution for your case.
Don't hesitate to contact us if you have other questions.
Kind regards,
Peter
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
i am using windows forms UI and using split container to keep controls based on the requirement, i have hide and show them in c#.
The problem is if i hide control, that place is reserving as a empty space, once it is hidden, the other controls needs to move up.
if you see the attached screen you will understand it. is there any property to set like visibility: collapsed.
thanks in advance.
Thank you for writing.
You can set the Dock property of the controls located in the split panel to Top. This way when you hide the upper control the one underneath will take its location.
I hope this helps. Should you have further questions please do not hesitate to write back.
Regards,
Hristo Merdjanov
Telerik by Progress