6 Answers, 1 is accepted
0
Accepted
Hi Damien,
There is no property that controls this but you can set the Margin of the view:
I hope this will be useful. Let me know if you have additional questions.
Regards,
Dimitar
Progress Telerik
There is no property that controls this but you can set the Margin of the view:
protected
override
void
OnLoad(EventArgs e)
{
base
.OnLoad(e);
var topMargin = (radTextBoxControl1.TextBoxElement.ViewElement.Size.Height / 2) - (radTextBoxControl1.TextBoxElement.ViewElement.Children[0].Size.Height / 2);
radTextBoxControl1.TextBoxElement.ViewElement.Margin =
new
Padding(0, topMargin, 0, 0);
}
I hope this will be useful. Let me know if you have additional questions.
Regards,
Dimitar
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0

Damien
Top achievements
Rank 1
answered on 26 Dec 2017, 03:11 AM
Hi Dimitar
So when do I actually call this function?
thanks.
0

Damien
Top achievements
Rank 1
answered on 26 Dec 2017, 03:19 AM
Will this also affect the NullText to display in the vertical middle? If not, is there a way of doing that too?
Is this a likely feature that will be included in the future, as I have many TextBoxControl controls in my application, and having to add this extra code for all of this is tedious?
Thanks.
0
Hi Damien,
To center the null text you need to set the Margin of the following element as well:
This code should be called when the form layout is loaded or when the textbox is resized.
Should you have any other questions do not hesitate to ask.
Regards,
Dimitar
Progress Telerik
To center the null text you need to set the Margin of the following element as well:
radTextBoxControl1.TextBoxElement.Children[1].Children[0].Margin =
new
Padding(0, topMargin, 0, 0);
This code should be called when the form layout is loaded or when the textbox is resized.
Should you have any other questions do not hesitate to ask.
Regards,
Dimitar
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0

Damien
Top achievements
Rank 1
answered on 28 Dec 2017, 12:12 PM
thanks, all sorted.
Is this a likely feature that is coming or can it be?
thanks.
0
Hello, Damien,
Thank you for writing back.
By design, vertical alignment for RadTextBoxControl is not supposed to be supported. It is an input control and the text is purposed to be shown from top to bottom in a multiline text box. The standard MS TextBox also supports only horizontal text alignment. Currently, we don't have plans to change this behavior. If other customers have a similar request we will consider it in future.
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Dess
Progress Telerik
Thank you for writing back.
By design, vertical alignment for RadTextBoxControl is not supposed to be supported. It is an input control and the text is purposed to be shown from top to bottom in a multiline text box. The standard MS TextBox also supports only horizontal text alignment. Currently, we don't have plans to change this behavior. If other customers have a similar request we will consider it in future.
I hope this information helps. If you have any additional questions, please let me know.
Regards,
Dess
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.