I want to integrate DirectFB with Qt. Which Qt class will be useful for it in Qt 4.8?
There is no public class as a middleware component dedicated to DirectFB. There is a plugin, however, that you can enable in the following way:
./configure -plugin-gfx-directfb
or
./configure -qt-gfx-directfb
Note that you would better use Qt Embedded for that. Please read the following documentation for details.
That being said, I suggest to wipe Qt 4 out of your mind, and concentrate on Qt 5, which is much neater in this regard. There is a proper directfb QPA plugin in there, etc.
Related
I have some codes in Qt Creator that work properly. I need to use this codes but in win32 application in .net framework. Does anyone have any idea how can I do this? I am totally new to Qt and do not know how to use this useful codes in c++ project?
I appreciate any help in advance
I think I could not get my message across. Qt is c++ but It has some differences with the native c++ app that we use in .net framework. so I can't just copy all the codes in my project to run it properly. Can we make a dll or library to use this qt code in .net or not? and how can I do this?
I really need help. Thank you so much
For almost all cases, you do not want to mix .net and Qt in same application. It's less work to just take the logic and rewrite it for .net (managed C++ or C#).
Next best option might be to keep the parts separate and have them communicate through some IPC mechanism.
This is, because any non-trivial Qt code depends on it's own event loop, so getting the existing Qt code play nice with other event loop is always a hassle, and trying to get it play nicely when actual application is managed .net code... No, just no, unless you have a very compelling reason, are expert on both Qt and .net, and have extra time to make it work right.
I'm not sure if you don't know how to download and install Qt or how to create a Qt project in Visual Studio IDE. Try this installation guide.
Do you want to link the Qt library to your win32 c++ app? I think you should build the qt source code first with your win32 compiler. I think you could include the qt header and link the library as normal win32 library to your application after that.
Does Qt SDK provides some facilities for CD/DVD burning.
More specific , if yes please give some class reference.
Thanks.
Qt has nothing to do with CD/DVD burning. Its a GUI toolkit. it also have general purpose structures.
for CD/DVD burning you need to use other tools like wodim
No, Qt doesn't include any CD or DVD burning API. You'll need to find another software package to do that (of course you are still free to use Qt for the GUI parts)
Its also a good idea to see what others are doing at qt-apps.For instance i found this application http://qt-apps.org/content/show.php/Silicon?content=149696
You can download it and look at the source.
I want to develop a custom window system in c++ that should not depend on win32 library. As an example, Google Chrome has an interface that is not similar to windows own interface. Similarly MPCstar and adobe products have their own interfaces. Please help me where to start for such a project?
You can use cross platform
Qt
or
wxWidgets
but in my opinion Qt is better.
Qt is awesome even if you don't need cross platform support. I assure you after using it you won't understand how anyone could ever develop native GUI on frameworks like Win32 and MFC. Its only shortcoming is the size of the DLLs you'll have to distribute with your app.
BTW is C++ a prerequisite? if not, and you only need windows, use .Net.
I believe Qt should do the trick. I've never used it myself but it is platform independent. I know a few applications that use it, and it seems fine.
Qt and WxWidgets are the better options. And since its GUI I think Qt performs better and has greater support and lots of libraries.
Find Qt here!
I have a Qt-embedded application that I develop in OpenSuse 11.4 where I need to load a TTF font file. However when I call int QFontDatabase::addApplicationFont() function, it's returning -1.
Upon reading the documentation, I found out that adding application fonts on Unix/X11 platforms without fontconfig is currently not supported.
I checked through YaST whether I have fontconfig installed, and it is installed - but I don't think it's related coz I'm using a qt-embedded library. I'm thinking I gotta have fontconfig support qt-embedded library, but how do I do that?
Does fontconfig even support qt-embedded? Can anybody tell me what's going on?
You can use QPA or Qt Platform Abstraction (formerly known as Lighthouse). You need to create an implementation (could be made as a plugin or just being used directly) of QPlatformIntegration which exposes a custom QPlatformFontDatabase. The trick here is to reuse much of Qt's existing implementation of QFontconfigDatabase (which is just as subclass of QBasicUnixFontDatabase).
This is exactly the technique we use for PhantomJS so that it works headlessly (without X11) on Linux while still leveraging Fontconfig (and thus also FreeType) for text rendering.
Unfortunately I think Qt 4.5 is too old to run Lighthouse. Either move to 4.8 which officialy supports QPA or try to backport Lighthouse.
I love that Qt is cross-platform but I want to make an application that will call into some Windows specific .dll's. Kinda like Google Chrome does with the glass on Windows Vista/7 (I know Chrome isn't written using the Qt framework just thought it was a good example).
How can I do this in Qt? Is it feasible?
Yes, this is no problem. You just go ahead and do it! Qt itself is just a DLL you call into, it just happens to be the same across different platforms. Just link against the DLLs you like and call them.
There is nothing wrong with using Qt to make a Windows-only application if you like.
As long as you have the relevant Windows SDK headers to hand, and can link with the appropriate libs, then it is easy to mix and match Qt and Win32 code. I use Qt Creator for C++ development which ships with MinGW and includes all the most common Win32 SDK headers and libs. You can even wrap the Windows specific parts of your code with suitable #ifdefs in case you ever come to build for a different platform, e.g.:
#ifdef Q_OS_WIN
#include <windows.h>
void someWindowsSpecificFunc()
{
...
}
#endif // Q_OS_WIN
You can of course call WinAPI functions directly from your Qt code, then it's better to include qt_windows.h not windows.h.
If you just want to add the cool new Windows 7 features to your application then you are better of using a dedicated Qt add-on. There is one called Q7Goodies.
Fearlessly go ahead an write your Win-specific app. You can utilize all the Windows DLLs you want. In this sense, Qt has no limitations. You will still be gaining the advantages of those nifty Qt layout components and customizable skinning. In terms of skinning there is no better framework that Qt. Your users will love all the resizable dialogs you provide them with.