Jump to content
Clayton A. Alves

Old Window border style on Delphi MDI child form

Recommended Posts

Posted (edited)

In Delphi 7 (don't ask) the MDI form (window) is displayed using Windows 10 style. But the MDI child is using the old Windows style.

Does anyone has any clues on why this happens ?

 

I've attached a screenshot of this problem.

 

Delphi Version: 7
Windows Version: 10

Captura de tela de 2024-10-04 16-38-57.png

Edited by Clayton A. Alves

Share this post


Link to post

Windows 10 doesn't support MDI child forms with Windows 10 style. Microsoft deprecated MDI since about XP and proper support for newer features will probably never be done for MDI windows.

 

See also: MDI window title in Windows 10

 

 

Share this post


Link to post
6 minutes ago, Uwe Raabe said:

Microsoft deprecated MDI since about XP

Any authoritative sources for this?

I've seen people make the same claim many times about both COM (claimed to be superseded by .NET) and GDI (claimed to be superseded by GDI+). Both ridiculous claims.

 

Just because MDI windows doesn't support the same features as SDI windows doesn't mean that they're deprecated. The documentation certainly doesn't give any indication that it is so: https://learn.microsoft.com/en-us/windows/win32/winmsg/multiple-document-interface

Share this post


Link to post
Posted (edited)
1 hour ago, Clayton A. Alves said:

In Delphi 7 (don't ask) the MDI form (window) is displayed using Windows 10 style. But the MDI child is using the old Windows style.

Does anyone has any clues on why this happens ?

It is a underlying Windows issue.  Microsoft simply doesn't render MDI windows using modern styles or high DPI support (ie, MDI does not operate under DWM).  That is why Embarcadero finally decided to revamp their MDI system in the VCL in Delphi 12:

https://docwiki.embarcadero.com/RADStudio/Athens/en/What's_New#MDI_Reworked_for_HighDPI_and_Styles

26 minutes ago, Anders Melander said:

Any authoritative sources for this?

Not on-hand, but I've seen MS employees verify the issue.  I also found this tidbit, take it with a grain of salt:

https://www.akadia.com/services/dotnet_software_design.html#The MDI (Multiple Document Interface) Approach

Quote

MDI was used a lot with versions of Windows prior to Windows 95. However, Microsoft researchers discovered that users found this split artificial and confusing. So from Windows 95, Microsoft announced that MDI would be deprecated and it should not be used for Windows applications ... well, Microsoft's story on MDI has never been consistent; legacy support has continued to be included with windows and the .NET Framework supports the MDI Approach in an excellent manner.

26 minutes ago, Anders Melander said:

I've seen people make the same claim many times about both COM (claimed to be superseded by .NET) and GDI (claimed to be superseded by GDI+). Both ridiculous claims.

Nobody ever claimed that .NET would replace COM.  GDI+ augments GDI, but does not replace GDI.

Quote

Just because MDI windows doesn't support the same features as SDI windows doesn't mean that they're deprecated.

It is a well-known fact that after XP, MDI has been left behind in visual handling.  MS simply never bothered to update MDI for modern systems.  Feels like deprecation to me.

 

Edited by Remy Lebeau
  • Like 1

Share this post


Link to post
9 hours ago, Anders Melander said:

Any authoritative sources for this?

Well, no official announcement from MS, if you are looking for something like this. The source is the shear lack of proper support in Windows itself. One can talk and write a lot or not - in the end it is facts that count.

  • Like 1

Share this post


Link to post
14 hours ago, Remy Lebeau said:

(ie, MDI does not operate under DWM).

This is the fundamental answer to the question, IMO.

Share this post


Link to post
15 hours ago, Anders Melander said:

Any authoritative sources for this?

I've seen people make the same claim many times about both COM (claimed to be superseded by .NET) and GDI (claimed to be superseded by GDI+). Both ridiculous claims.

That looks like a straw man to me.

 

It may be true that MDI is not technically deprecated, but it seems to exist in a state of de-facto deprecation. MDI is a strange middle place between Mac's windowing model and the Windows windowing model. Other than supporting legacy applications, I can't see why anyone would use it. A decent docking system should easily replace any perceived benefits of an MDI paradigm.

  • Like 1

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×