QSF Forms&Dialogs Message box - show RadMessageBox when click on the right side of the title bar the popup dialog cannot be dragged.
The size of RadForm under Windows XP is incorrect when its initial state as MDI child is Maximized and after that the state is changed to Normal. Workaround: Imports Telerik.WinControls.UI Public Class BaseRadForm Inherits RadForm Private Shared LastWindowState As FormWindowState = FormWindowState.Normal Private Shared suspendClientSizeChangedFlag As Boolean = False Protected Overrides Sub OnResizeBegin(ByVal e As System.EventArgs) Me.MaximumSize = New Size(0, 0) MyBase.OnResizeBegin(e) End Sub Protected Overrides Sub OnActivated(ByVal e As System.EventArgs) Me.MaximumSize = New Size(0, 0) MyBase.OnActivated(e) End Sub Protected Overrides Sub OnDeactivate(ByVal e As System.EventArgs) Me.MaximumSize = New Size(0, 0) MyBase.OnDeactivate(e) End Sub Protected Overrides Sub OnClientSizeChanged(ByVal e As System.EventArgs) Dim osInfo As System.OperatingSystem = System.Environment.OSVersion If (suspendClientSizeChangedFlag OrElse osInfo.Version.Major >= 6) Then Return End If If Not LastWindowState.Equals(Me.WindowState) Then LastWindowState = Me.WindowState If Me.WindowState.Equals(FormWindowState.Normal) Then suspendClientSizeChangedFlag = True Me.MaximumSize = New Size(500, 500) suspendClientSizeChangedFlag = False ElseIf Me.WindowState.Equals(FormWindowState.Maximized) Then Me.MaximumSize = New Size(0, 0) End If Else Me.MaximumSize = New Size(0, 0) End If MyBase.OnClientSizeChanged(e) End Sub End Class
To reproduce: -Set RTL via the insane: RadMessageBox.Instance.RightToLeft = RightToLeft.Yes; - You will notice that layout is not changed when the messagebox is shown. Worlaround: - Use the RadMessageBox show method with the following parameters: RadMessageBox.Show(this, "test", "caption", MessageBoxButtons.OKCancel, icon, MessageBoxDefaultButton.Button1, RightToLeft.Yes);
If you have an MDI form with controls anchored to bottom-left, and if the form is shown the following way: Form form = new ChildForm() form.MdiParent = this; form.Show(); private void ChildForm_Load(object sender, EventArgs e) { this.ThemeName = "Office2007Black"; } the anchored controls will be misplaced. WORKAROUND: either set the parent after show: Form form = new ChildForm() form.Show(); form.MdiParent = this; or do not use the Load event to apply theme - use the constructor or the Shown event: public ChildForm() { InitializeComponent(); this.ThemeName = "Office2007Black"; }
To reproduce: use the following code snippet: public Form1() { InitializeComponent(); this.radDropDownList1.SelectedIndexChanged+=radDropDownList1_SelectedIndexChanged; this.radDropDownList1.Items.Add("TelerikMetro"); this.radDropDownList1.Items.Add("Windows8"); this.radDropDownList1.Items.Add("VisualStudio2012Dark"); this.radDropDownList1.SelectedIndex = 1; this.SizeChanged+=Form1_SizeChanged; } private void radDropDownList1_SelectedIndexChanged(object sender, Telerik.WinControls.UI.Data.PositionChangedEventArgs e) { ThemeResolutionService.ApplicationThemeName = this.radDropDownList1.Text; } 1. Use two monitors and decrease the screen resolution to the main monitor. 2. Run the application from the first monitor and move the form to the second monitor. 3. Resize the form on a way to increase the form's height to be greater than the height of the screen resolution of the main monitor. 4. Change the theme. You will notice that that form is resized. Workaround: public Form1() { InitializeComponent(); this.radDropDownList1.SelectedIndexChanged += radDropDownList1_SelectedIndexChanged; this.radDropDownList1.Items.Add("TelerikMetro"); this.radDropDownList1.Items.Add("Windows8"); this.radDropDownList1.Items.Add("VisualStudio2012Dark"); this.radDropDownList1.SelectedIndex = 1; this.SizeChanged += Form1_SizeChanged; } private void Form1_SizeChanged(object sender, EventArgs e) { if (fSize != Size.Empty) { this.SizeChanged-= Form1_SizeChanged; this.Size = fSize; this.SizeChanged += Form1_SizeChanged; } } Size fSize = Size.Empty; private void radDropDownList1_SelectedIndexChanged(object sender, Telerik.WinControls.UI.Data.PositionChangedEventArgs e) { fSize = this.Size; ThemeResolutionService.ApplicationThemeName = this.radDropDownList1.Text; fSize=Size.Empty; }
Use attached to reproduce. This was working in version 2017.1.221 Workaround: private void Instance_LocationChanged(object sender, EventArgs e) { var box = sender as RadMessageBoxForm; box.Location = new Point((this.Location.X + this.Width / 2) - (box.Width/2), (this.Location.Y + this.Height / 2 )- (box.Height/2)); }
To reproduce: - Add RadMenu to a panel which is docked to the top. - Add an MDI child and maximize it. - You will notice that there is one more set of form buttons visible. Workaround: - Leave the menu outside of the panel.
To reproduce: - Use the approach described here to localize the form: https://msdn.microsoft.com/en-us/library/y99d1cd3%28v=vs.100%29.aspx?f=255&MSPPError=-2147217396 - Open the resx file in Visual Studio.
How to reproduce: create a DPI-aware application and set the AllowAero property of the ribbon form to false, the titlebar will not be themed Workaround: override the ScaleControl method of in the RadRibbonForm instance in the project Protected Overrides Sub ScaleControl(ByVal factor As SizeF, ByVal specified As BoundsSpecified) MyBase.ScaleControl(factor, specified) If Me.HasOwnToolbar AndAlso Me.AllowTheming AndAlso Not Me.IsDesignMode AndAlso Me.IsInitialized Then Me.AllowTheming = False End If End Sub
To reproduce: add a RadForm and start the application. Workaround: public partial class Form1 : RadForm { public Form1() { InitializeComponent(); } protected override void OnLoad(Size desiredSize) { this.ElementTree.InitializeRootElement(); this.RootElement.ApplyShapeToControl = false; base.OnLoad(desiredSize); } protected override void OnLoad(EventArgs e) { base.OnLoad(e); this.RootElement.ApplyShapeToControl = true; } }
RadRibbonForm back stage button is missplaced when in maximized state with office2010SilverTheme Workarouond: Set the margin when the window is set to maximize. void Form1_Resize(object sender, EventArgs e) { if (this.WindowState == FormWindowState.Maximized) { this.radRibbonBar1.RibbonBarElement.ApplicationButtonElement.Margin = new Padding(3, 35, 3, 0); } else { this.radRibbonBar1.RibbonBarElement.ApplicationButtonElement.Margin = new Padding(3, 33, 3, 0); } }
Workaround: ((RadFormControlBase)this).MinimumSize = new Size(350, 350); ((RadFormControlBase)this).MaximumSize = new Size(350, 350);
Steps to reproduce: 1. Create Telerik WinForms Application and add two RadForm 2. Select one of forms and set the IsMdiContainer property to true 3. Select the child form. Open the Properties window and set the following properties at design time: - WindowState to Maximized - ThemeName to Windows8 or any other theme 4. Run the application and show the child form. The child form is cut off instead maximized. Workaround: 1. Reset the WindowState property at design time 2. Subscribe to the Form`s Load event and set the WindowState property private void RadForm2_Load(object sender, EventArgs e) { this.WindowState = FormWindowState.Maximized; }
Please refer to the attached sample project. Workaround: Initialize the form just before showing it.
After each call to the Show method of RadMessageBox, the message box form is disposed. This causes each new call to Instance (or Show which internally calls Instance) to create a new instance of a message box form, loosing any user settings.