简体   繁体   English

如果C ++没有这方面的功能,像Qt这样的框架如何创建GUI?

[英]How frameworks like Qt create GUI, if C++ has no functionality for that?

From the answers recieved for the question here: Graphics using Standard C++ only? 从这里收到的答案回答: 图形仅使用标准C ++?

Seems to be that C++ itself does not have GUI functionality. 似乎C ++本身没有GUI功能。 So how do other Frameworks like Qt which support GUI in C++ do that? 那么像Ct这样在C ++中支持GUI的其他框架如何做呢? Do they use some other language internally or is there some other standard lobrary/protocol for GUI? 他们是否在内部使用其他语言或是否有其他一些标准的GUI /协议?

And I am concerned about the C++ language frameworks only. 我只关心C ++语言框架。

Thank You. 谢谢。

They call operating system APIs, or APIs in other frameworks, in order to create GUI components. 他们调用操作系统API或其他框架中的API,以创建GUI组件。

Eg. 例如。 on Windows they call the Windows CreateWindow API to create a window. 在Windows上,他们调用Windows CreateWindow API来创建一个窗口。

Where a framework works on multiple platforms, it contains different GUI code for each of those platforms, calling CreateWindow on Windows or whatever the Mac equivalent is on a Mac, for example. 如果框架在多个平台上运行,它为每个平台包含不同的GUI代码,例如,在Windows上调用CreateWindow或在Mac上调用Mac等价物。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM