Our application embed a RadDock element.Unfortunately, in a non-systematic way, our application crash with this stack trace:
Our application is a 64bit application (we migrated it to NET6 using Telerik 2022.2.510.60). As I told unfortunately in this case I'm not able to isolate the case in a simple project (as I'm used to to).
It would be useful by your side, however, make a check to the last trace line of the log I've gave to you:
at Telerik.WinControls.UI.ThemedFormBehavior.OnWMNCHitTest(Message& m)
If I decompile your code I find this:
In this case, we add a ToolWindow directly to the control in a floating state using FloatingWindow. Each add ToolWindow will have a different BackColor property value. Now we save the layout of the control into an XML file. The next step is to close the application and load the layout from the XML. The ToolWindows are loaded, however, their BackColor property is not restored.
this.toolWindow1.TabStrip.MinimumSize = new Size(200,200)
When closing the MDI child, its FormClosing event is called twice. This is not observed if we close its HostWindow first.
this.radDock1.DockTabStripNeeded += this.RadDock1_DockTabStripNeeded;
private void RadDock1_DockTabStripNeeded(object sender, DockTabStripNeededEventArgs e)
{
if (e.DockType == DockType.ToolWindow)
{
e.Strip = new MyToolTabStrip();
}
else
{
e.Strip = new MyDocumentTabStrip();
}
}
public class MyToolTabStrip : ToolTabStrip
{
protected override bool ScaleChildren => false;
}
public class MyDocumentTabStrip : DocumentTabStrip
{
protected override bool ScaleChildren => false;
}
Use cases: 1. You have a MainDocumentContainer with Document windows in it, placed in one under the other. Setting the DockState of the bottom DocumentWindow to Hidden, and restoring it afterwards, should place the DocumentWindow at the same place, instead of merging it with the above one 2. Same layout as above, when the layout is saved and then restored, the DocumentWindow positions should be exactly as they were
Use the following code snippet:
ToolTabStrip tabStrip = this.toolWindow1.TabStrip as ToolTabStrip;
this.toolWindow1.Text = "<html><span style=\"font-family:Segoe UI;font-size:8.25;\"><b>Hello</b></span><span" +
" style=\"font-family:Segoe UI;font-size:8.25;\">Woooooooooooooooooorld</span></html>";
TextPrimitive text = tabStrip.CaptionElement.FindDescendant<TextPrimitive>();
text.ClipDrawing = true;
text.StretchHorizontally = false;
text.DisableHTMLRendering = false;
text.AutoEllipsis = false;
Hi,
I have C# Winforms application targeting .Net 5.
I am trying to use the Raddock with the Visual Studio 2012 dark theme, adding to a radribbonform
There are several tool windows that i have tabbed using the Advance layout designer. When i try to select a tab in the main Visual studio designer i am unable to change it from the one i selected in the Advanced layout designer.
I am also unable to resize the windows using the split container while in standard design view.
I have attached a word document to try and explain.
My VS version is:
Microsoft Visual Studio Professional 2019
Version 16.9.1
thanks
Mark.
To reproduce: See attached video. Workaround: public Form1() { RadDockEvents.TabStripItemCreating += RadDockEvents_TabStripItemCreating; InitializeComponent(); radDock1.AutoHideAnimation = Telerik.WinControls.UI.Docking.AutoHideAnimateMode.None; } void RadDockEvents_TabStripItemCreating(object sender, TabStripItemCreatingEventArgs args) { if (args.AutoHide) { var currentScale = args.TabItem.DpiScaleFactor; Screen showScreen = Screen.FromControl(this); SizeF scale = NativeMethods.GetMonitorDpi(showScreen, NativeMethods.DpiType.Effective); if (scale != currentScale) { var font = args.TabItem.Font; var newFont = new Font(font.Name, font.Size * scale.Width, font.Style); args.TabItem.Font = newFont; } } } protected override void OnClosed(EventArgs e) { RadDockEvents.TabStripItemCreating -= RadDockEvents_TabStripItemCreating; base.OnClosed(e); }