Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

SyntaxEdit Find and Find/Replace Dialogs don't resize properly under with high DPI

I don't know why I didn't notice this before but the Find and the Find/Replace dialogs don't resize correctly under high DPI (>100%). A customer had to bring this to my attention (I mostly use 100% scaling so that's probably why I didn't catch this).

See:

Notice the "Bounds for replace all" and "Start from" sections are barely visible... and it gets worse if the DPI is even higher.
Tagged:

Comments

  • 13 Comments sorted by Votes Date Added
  • Cannot reproduce. I often check two scenarios:

    1) Open dialog on my main monitor with 100% DPI, and then move it to second monitor with higher DPI and back.
    2) Open dialog on second monitor directly.

    Both work fine.
  • edited February 20 Posts: 132Vote Up0Vote Down
    I'm opening with LMDEditExecReplaceDialog(L"Replace Text",Edit,LMDSearchDlgOptions)

    Could that make a difference?

    Also, my app uses "System Aware" DPI awareness because I'm still waiting for a component I use to support per monitor DPI.... could that make a difference?
  • I made a simple test project that reproduces the problem. Works at 100% scaling but the replace dialog does not scale properly on my high DPI systems.

    Please download test project and check:
  • Confirmed. I've also made simple experiment: I've created new project and just copied form content (without any code, and with replacing our internal TPanelD6 to simple TPanel) to project's main form. 

    And I see a lot of strange bugs, while moving the form between monitors. So, its definitely Delphi's bug (all standard controls without any code).

    Next question, what can be done? Thinking...
  • Btw, I still cannot reproduce your issue exactly. An application with system dpi awareness works fine (with 125% DPI settings on both my monitors). And its actually work fine also in "per monitor V2 mode", if both monitors have same DPI settings. 

    Mentioned by me issue previously happens only when secaling during moving between monitors. So, this is probably not your case.
  • If I open the EXE in the ZIP file I posted above on my Notebook computer (at 125%) then the Find/Replace dialog does not scale properly. This isn't even about moving the dialog from monitor to monitor.

    If you open that EXE file on a computer running over 100% then does it scale properly for you?

    While it is only now that I'm getting a report of this issue, I think it is a serious problem because a lot of people run at over 100% nowadays.

    My other forms seem to display properly so I'm not sure what's going on with the LMD Find/Replace dialog. I hope you are able to figure it out ASAP because I'd like to release a fix right away.

    If there is anything further I can do to help you figure out what's going on then please let me know.

    Thank you.
  • Confirmed. Its the Delphi's backward compatibility issue. The bug is not occures if the form (dfm) is re-saved in latest IDE versions, but from time to time we check, that all forms can be opened in Delphi 6 (min supported version), and Delphi 6 saves properties of form differently, and because of that, scaling not work.

    Thinking what can be done.
  • edited February 25 Posts: 132Vote Up0Vote Down
    OK, thank you. Please let me know as soon as you've found a fix or workaround so I can implement it in my app.
  • If you are able to work with sources, then the problem is in AutoScoll form's property. It just need to be set to False, and dfms need to be re-saved after that. And so, Delphi's scaling mechanism will work.

    The bug is fixed already.
  • Thank you. I may try that but because I work in C++Builder it makes everything more complicated and prone to problems so I try to avoid working with sources if I don't have to.

    When will the fix be incorporated in the official release?
  • edited February 26 Posts: 132Vote Up0Vote Down
    I tried to do what you said - open the form and re-save it making sure that LMDSedFindDlg's AutoScroll property is False.... then recompile.

    I thought it was too easy and of course it was.

    When I rebuild my app and try to show the Find/Replace dialog I now get an error message - "Class TPanelD6 not found.".

    What should I do now?

    UPDATE: Looks like copying/updating files from source to lib\d26\Win64 fixes the issue. But now I'm getting an Assertion failure in the print preview.... in LMDPrintToolBar.pas.

    What a mess.

    A new "official" release that fixes all this would be great. :)

  • edited February 27 Posts: 0Vote Up0Vote Down
    > But now I'm getting an Assertion failure in the print preview.... in LMDPrintToolBar.pas.

    Cannot reproduce this issue. May be it caused by differences in versions of your installed compiled files, and used sources. Anyway, we can create release this weekend.
  • I'll just wait for the new release.

    I do think there were version conflicts.... but I will wait for the new release instead of trying to get what I have now working.

    Thank you!

Sign In or Register to comment.