Completed
Last Updated: 07 Nov 2019 14:11 by ADMIN
Release R1 2020 (LIB 2019.3.1111)
JeffSM
Created on: 28 Oct 2019 10:20
Category: Dock
Type: Bug Report
1
RadDock: setting the ElementTree.EnableApplicationThemeName property to false doesn't respected the RadDock.ThemeName

If you apply one theme to the entire application and want to apply another theme for RadDock as it is demonstrated in this help article, the ThemeName property of RadDock is not respected:

             

        public RadForm1()
        {
            InitializeComponent();

            radDock1.ElementTree.EnableApplicationThemeName = false;
            radDock1.ThemeName = "FluentDark"; 
            ThemeResolutionService.ApplicationThemeName = "Windows7"; 
        }

 

Attached Files:
6 comments
JeffSM
Posted on: 01 Nov 2019 14:37
hi, I just left registered for others. Thnaks.
ADMIN
Dess | Tech Support Engineer, Principal
Posted on: 01 Nov 2019 11:21
Hello, Jeff,         

Usually, it is expected that the RadDock.ElementTree.EnableApplicationThemeName property is set to false in your case. However, feel free to use this approach which suits your requirements best.

Note that we will do our best to introduce a fix as soon as possible in the upcoming latest internal builds. Make sure that you follow this item. Thus, you will get notified once any status changes occur.

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik

Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
JeffSM
Posted on: 31 Oct 2019 16:09

Dear Dess,

your way not work, but mine.

After set .MdiParent

I call:

  public void SetThemes()

        {            
            foreach (var strip in ControlHelper.GetChildControls<DockTabStrip>(this, true))
            {
                if (strip.DockManager != radDock1) continue;                
                strip.ElementTree.EnableApplicationThemeName = false; // radDock1.ElementTree.EnableApplicationThemeName;
                strip.ThemeName = "FluentDark";
            }
        }

 

in the Form with Dock

ADMIN
Dess | Tech Support Engineer, Principal
Posted on: 29 Oct 2019 12:24

Hello, Jeff,        

I completely understand the impact of this issue. However, RadDock is quite a complex control which uses another nested controls to provide the rich layout capabilities it offers.

We will do our best to introduce a fix as soon as possible. Meanwhile, feel free to use the suggested approach and apply the specific theme for each separate DockTabStrip

Should you have further questions please let me know.

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik

Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
JeffSM
Posted on: 28 Oct 2019 15:50
What I'd like is that all components work as it should do.
ADMIN
Dess | Tech Support Engineer, Principal
Posted on: 28 Oct 2019 10:29
Hello, Jeff,        

Indeed, RadDock doesn't apply the theme properly because it hosts other controls.  I have also updated your Telerik points.

Currently, the possible solution that I can suggest is to handle the ThemeNameChanged event and use the following code snippet:

        private void radDock1_ThemeNameChanged(object source, ThemeNameChangedEventArgs args)
        {
            string themeName = this.radDock1.ThemeName;

            foreach (DockTabStrip strip in ControlHelper.GetChildControls<DockTabStrip>(this, true))
            {
                if (strip.DockManager == this.radDock1)
                {
                    strip.ThemeName = themeName;
                    strip.ElementTree.EnableApplicationThemeName = this.radDock1.ElementTree.EnableApplicationThemeName;
                }
            } 
        }
I hope this information helps. If you need any further assistance please don't hesitate to contact me. 

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik

Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.