Completed
Last Updated: 15 Feb 2016 09:08 by ADMIN
ADMIN
Dess | Tech Support Engineer, Principal
Created on: 20 Jul 2015 10:31
Category: Form
Type: Bug Report
2
FIX. RadForm - setting the Size property at run time is not respected when the MinimumSize is set at design time for an MDI child RadForm
UPDATED: this is reproducible in a non-MDI scenario is well.

Sub New()
    InitializeComponent()
    Me.Size = New Size(500, 500)
End Sub


To reproduce:

1. Add two RadForms - a parent and a child.
2. Set the MinimumSize property of the child form at design time.
3. Use the following code snippet:

public partial class ParentForm : RadForm
{
    public ParentForm()
    {
        InitializeComponent();

        this.IsMdiContainer = true;

        ChildForm form = new ChildForm();
        form.Text = "MDI Child 1";
        form.MdiParent = this;
        form.Size = new System.Drawing.Size(600, 600);
        form.Show();
    }
}

public partial class ChildForm : Telerik.WinControls.UI.RadForm
{
    public ChildForm()
    {
        InitializeComponent();
        this.SizeChanged += ChildForm_SizeChanged;
    }
    
    private void ChildForm_SizeChanged(object sender, EventArgs e)
    {
        this.Text = "ChildForm " + this.Size.Width + " x " + this.Size.Height;
    }
}

When you run the application with version 2015.2 623, you will notice that the child form is loaded with its MinimumSize. However, in the previous version it is loaded with the expected specified Size(600, 600).

Workaround: use ShapedForm with titlebar. An alternative solution is to set the RadForm.Size property in the Shown event.
2 comments
ADMIN
Stefan
Posted on: 15 Feb 2016 09:06
It is fixed in Q2 2015 SP1 and should be ok in any version afterwards. Should you observe different behavior, please let us know of the precise case and the version you are using and we will check it once again.
Laura
Posted on: 12 Feb 2016 18:19
Was this fixed in a subsequent version of Winforms controls?