High DPI RadRibbonBar / form start menu sizing issues

1 Answer 121 Views
General Discussions RibbonBar RibbonForm
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Toby asked on 08 Jul 2022, 05:42 PM

Hi, I'm having strange resizing issues when moving an application between "normal" DPI and High DPI monitors. I have managed to reproduce the the issue in a small project which is attached.

To reproduce the issue move the application between monitor with different DPI's and and re-select the start menu button (blue blank in this case)

Tthis is what I see, it appears there is a resizing issue going on, thi sgets worse the more menu items in the right hand column (recently used file names in my application)

1 Answer, 1 is accepted

Sort by
0
Accepted
Stoyan
Telerik team
answered on 11 Jul 2022, 02:49 PM

Hello Toby,

Apparently you have encountered a bug in the RadApplicationMenu.

I have created a public item in our feedback portal based on your ticket. There you can follow the item and vote for it. If you follow the item, you will get notified on its status updates.

Furthermore I have update your Telerik Points in gratitude for pointing out this issue to us. 

We will do our best to have a fix soon, but until it is done I can offer you the following workaround:

    public partial class RadRibbonForm1 : Telerik.WinControls.UI.RadRibbonForm
    {
        public RadRibbonForm1()
        {
            InitializeComponent();

            this.AllowAero = false;

            this.radRibbonBar1.RibbonBarElement.ApplicationButtonElement.DropDownOpening += ApplicationButtonElement_DropDownOpening;            
        }

        private void ApplicationButtonElement_DropDownOpening(object sender, CancelEventArgs e)
        {
            var appMenuButton = sender as RadApplicationMenuButtonElement;
            if (appMenuButton == null)
            {
                return;
            }

            var menuElement = appMenuButton.DropDownMenu.PopupElement as RadApplicationMenuDropDownElement;

            if (menuElement != null && !this.IsDesignMode)
            {
                Size size = menuElement.TopRightContentElement.Layout.Size;
                size = Telerik.WinControls.TelerikDpiHelper.DescaleSize(size, menuElement.DpiScaleFactor);
                size.Width -= 3;
                size.Height -= 3;
                menuElement.MinSize = size;
            }
        }
    }

I hope this will work for you, until we have a fix for the issue.

Regards,
Stoyan
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Tags
General Discussions RibbonBar RibbonForm
Asked by
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Answers by
Stoyan
Telerik team
Share this question
or