Do Qt apps look and feel native under Windows?

后端 未结 5 1347
执念已碎
执念已碎 2021-01-03 19:53

I’m about to port one of my Mac applications to Windows. The Mac app uses Apple’s native Cocoa/Appkit frameworks for the UI. The UI is Obj-C code, and the core app functiona

相关标签:
5条回答
  • 2021-01-03 20:10

    No they do NOT. It's close, but the controls look non-native. What people mean is that it uses the Win32 API for rendering the controls similar to how Windows renders the native controls so the performance should be comparible.

    Only Windows specific frameworks like .NET Windows Forms use the actual native Win32 controls for common UI elements.

    0 讨论(0)
  • 2021-01-03 20:11

    They look a bit and they don't feel a lot.

    Especially if you design the app with windows in mind (like you do with cocoa). I have not yet seen ribbons (there is a commercial 3rd party clone) and the MFC blue/black style or a list view in grouped icon view.

    Unfortunately WxWidgets is also very ugly to program. Better then MFC for sure. There are only two options left if you want a real native looking app, MFC (if you need fast and small) or .NET (if you don't care about speed).

    A previous company had a 50000 LOC layer on top of MFC which was necessary to be able to program this 1992 framework a bit more comfortable). Unfortunately i do not know of anything available on the market that does the same.

    The question is do your customers really appreciate a native look that it becomes a sales factor or not. I'm now using QT because it is good enough.

    0 讨论(0)
  • 2021-01-03 20:16

    You can easily change the style of a Qt application. On Windows and Mac the default style is actually using the native functions for drawing windows, controls and the like.

    Additionally Qt does take many measures so that even the smallest aspects of an application (things you wouldn't even think of) emulate the native behaviour of a specific platform. So your Qt application can also replace your current Mac application when ported.

    I extremely advise you not to use MFC, you will regret it (especially if you never worked with the native Win32 API). It's the complete opposite of Qt regarding flexibility and ease of use.

    0 讨论(0)
  • 2021-01-03 20:20

    You should have a look at the Style reference. Yes it's possible, and no it doesn't require a lot of work (at all).

    0 讨论(0)
  • 2021-01-03 20:24

    As you can read on doc.qt.io:

    Qt Widgets are traditional user interface elements that are typically found in desktop environments. The widgets integrate well to the underlying platform providing native look'n'feel on Windows, Linux and Mac OSX.

    Take a look at Qt Widget Gallery:

    Qt's support for widget styles and themes enables your application to fit in with the native desktop enviroment.

    You might be interested in a presentation called How to Make Your Qt Application Look Native:

    Qt uses native style APIs on each supported platform, however there are some additional tricks you can use to make sure your Qt-based application looks, feels and behaves better. This presentation will run through examples, tips and ticks to help you make your applications look great on all platforms.

    0 讨论(0)
提交回复
热议问题