I wanna use wxSVG to render SVG file in my Win32 program. But wxSVG is only used with wxWidgets toolkits. So I wanna know if it's possible to use wxWidgets in my origin Win32 program without change the Win32 framework?
Related
I find a lottie library for windows https://github.com/LottieFiles/Lottie-Windows, but I think it is for UWP programme, and I want to use it in my win32 programme. I don't know if that can be done.
Like with toolkits such as qT, wxwidgets and such, how does an API designer provide and api that is the same, even though it calls totally different system calls to do so? For example, in Windows OS you have to mess around with a whole lot of functions in the GDI. On Linux you have to mess around with a whole lot of functions in XLib and whatever other layers the distribution has on top of in. So how how can you design an widgit kit that can unify all that functionality? so that say CreateWindow() will create a windon on any platform? I don't comprehend how this can be done.
Instead of using Xlib or GDI, you could use something that is more universal. For example, you could use OpenGL, which is supported everywhere. I think that is what Blender's UI does.
Some toolkits can be modified to use some kind of backend for each platform they support. This is basically what Qt does. On Mac OS X, Qt apps use Cocoa as a backend. Qt for OS X was made specifically for that OS. However, there are other Qt implementations on other platforms, so that's what makes Qt work on more than one platform. SWT for Java works the same way (using the OS's native toolkit as a backend).
Other toolkits can use some kind of high-level layer to render. For example, Swing for Java is rendered purely using Java APIs, and is not tied to any platform at all.
I read this advice:
How do I use Qt and SDL together?
and now I have question connected to it. This example was created for Linux, but how use it under Windows? winId() under Windows return WinAPI Handler for widgets, other then Linux. Is there any possibility to use SDL under Windows with Qt?
Yes.
Both of them are portable frameworks and tools. I think there is no huge problem but maybe there is some easy compilation issues.
Note: winId() returns OS-specific value such as HWND for Windows, HIView for Mac and Window for X.
Returns the window system identifier of the widget.
Portable in principle, but if you use it you are probably about to do
something non-portable. Be careful.
If a widget is non-native (alien) and winId() is invoked on it, that
widget will be provided a native handle.
On Mac OS X, the type returned depends on which framework Qt was
linked against. If Qt is using Carbon, the {WId} is actually an
HIViewRef. If Qt is using Cocoa, {WId} is a pointer to an NSView.
Can anybody tell if I can use the Windows APIs in my qt application?
If yes can anybody tell me the procedure to do it? I need to use the msdn winapi "GetSystemPowerStatus" in my qt application to show the battery status in my qt GUI based application.
Yes, you can use those APIs (generally speaking), by including the appropriate header files.
It will make your code platform-specific (non-portable), so if there is a cross-platform way of doing so, I would use that.
What underlying rendering system does the Qt GUI toolkit use on Windows? (I'm assuming it is GDI)
QT is a c++ library, and preduce native application. so the only option is:
gdi/gdi+