Excel-like pop-up location is not scaled properly on High DPI.
Hi Jackson,
Thank you for reporting this behavior. Here is a possible workaround that can be used until this item is resolved:
public RadForm1()
{
InitializeComponent();
this.radGridView1.FilterPopupInitialized += RadGridView1_FilterPopupInitialized;
}
private void RadGridView1_FilterPopupInitialized(object sender, FilterPopupInitializedEventArgs e)
{
RadListFilterPopup popup = e.FilterPopup as RadListFilterPopup;
popup.MinimumSize = new Size(300, 300);
popup.PopupOpened += Popup_PopupOpened;
}
private void Popup_PopupOpened(object sender, EventArgs args)
{
RadListFilterPopup popup = sender as RadListFilterPopup;
popup.LocationChanged += Popup_LocationChanged;
popup.Location = new System.Drawing.Point(MousePosition.X, MousePosition.Y);
}
private void Popup_LocationChanged(object sender, EventArgs e)
{
RadListFilterPopup popup = sender as RadListFilterPopup;
if (popup != null)
{
popup.LocationChanged -= Popup_LocationChanged;
Screen screen = Screen.FromPoint(new System.Drawing.Point(popup.Left, popup.Top));
if (popup.Left + popup.Width > screen.WorkingArea.Right)
{
popup.Left = screen.WorkingArea.Right - popup.Width;
}
}
}
Regards,
Dinko | Tech Support Engineer
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.