This happens because resizing the button doesn't resize the inner parts of the button (children in its hierarchy). ImageAlignment
is effective only when there is a text that is larger than the image (i.e. text with bigger height than the image).
To set the desired location of such an element as the image in the button, you should set the Alignment
property of the ImageAntTextLayoutPanel
. This can be done either via the property grid at design-time, or by using the following code:this.radDropDownButton1.RootElement.GetChildAt(0).GetChildAt(1).GetChildAt(1).GetChildAt(1))).Alignment = System.Drawing.ContentAlignment.MiddleCenter;
Feel free to examine the structure of the RadDropDownButton
in our examples with the RadControlSpy .
Please, let me know if this works fine for you.
the Telerik team