Bug Report T1211378
Visible to All Users

TdxRibbonForm whose SupportNonClientDrawing property is True does not support Snap Layout

created a year ago (modified 6 months ago)

Steps to reproduce:

  1. VCL PDFViewer demo.
  2. Hover over the Maximize button.

Expected results:

Windows 11 has a capability to snap layouts when you hover over the form's Maximize button

Snap Layouts popup appears

Clipboard-File-2.png

Current results:

TdxRibbonForm does not support snap layouts.

Clipboard-File-1.png

Comments (2)
AP AP
Alex Pa (DevExpress Support) 6 months ago

    Please test the following code modification.

    Replace the TdxRibbonFormCaptionHelper.CalculateWindowCaptionHitTest procedure's implementation in dxRibbonFormCaptionHelper.pas and use the Recompile option of our installer.

    Delphi
    procedure TdxRibbonFormCaptionHelper.CalculateWindowCaptionHitTest(var Message: TWMNCHitTest); var APoint: TPoint; begin if IsInCaptionArea(cxPoint(Message.XPos, Message.YPos)) then begin Message.Result := HTCAPTION; APoint := Control.ScreenToClient(cxPoint(Message.XPos, Message.YPos)); if cxRectPtIn(FBorderIconsArea, APoint) then begin StartMouseTimer; HotBorderIcon := GetBorderIconAtPoint(APoint); if HotBorderIcon <> tbiNone then begin if (HotBorderIcon = tbiMaximize) and IsWin11OrLater and (GetMouseKeys = 0) then Message.Result := HTMAXBUTTON else Message.Result := HTNOWHERE; Exit; end; end; if cxRectPtIn(FSysMenuBounds, APoint) then Message.Result := HTSYSMENU; HotBorderIcon := tbiNone; end; end;

      Just stopping by to quickly say: Thank you!
      (working with Delphi 12.1 + EAP 24.2.1)

      Answers approved by DevExpress Support

      created 6 months ago (modified 6 months ago)

      We have addressed the issue described in this ticket and will include a fix in our next maintenance update. Should you need to apply our fix prior to official release, you can request a hotfix here.

      Important Notes:

      • Hotfixes may be unavailable for Early Access/Beta builds or updates set for release within a week.
      • .NET only: in the NuGet Package Manager, use your personal NuGet feed and check the "Include prerelease" option to view the hotfix package in the "Updates" tab.
      Additional information:

      We implemented Snap Layouts support:

      Clipboard-File-1.png

        Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

        Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.