qt4

Updating a QProgressDialog with a QFuture

What's the proper way for the main GUI thread to update a QProgressDialog while waiting for a QFuture. Specifically, what goes in this loop: QProgressDialog pd(...); QFuture f = ...; while (!f.isFinished()) { pd.setValue(f.progressValue()); // what goes here? } Right now I have a sleep() like call there, but that's not optimal (...

Most elegant/safe/easy solution to store and edit (GUI) a directory-like tree structure?

Hello, I've got a slightly tricky problem to solve; imagine this: One of my applications needs to make heavy use of scripting, so my idea was to provide the user a way to write script snippets and organize them in a directory-like tree structure. This is much like a source code directories with subdirectories and source files. Data Cl...

QSignalMapper and original Sender()

I have a bunch of qComboboxes in a table. So that I know which one was triggered I remap the signal to encode the table cell location (as described in http://stackoverflow.com/questions/1332110/selecting-qcombobox-in-qtablewidget) (Why Qt doesn't just send the cell activated signal first so you can use the same currentRow/COlumn mechani...

Qt Application Customization

How to make Qt app look in Adoby Lightroom style? Is it skin or css style? Or maybe some other UI framework is used in Lighroom? I want to create some form with "Video Timeline" custom widget, like in Adobe flash, and in lightroom style but i'm not sure from what to start, especially with "timeline widget" ...

QAbstractSocket::UnknownSocketError

What could be cause of QAbstractSocket::UnknownSocketError when using QTcpSocket? CODE I'm getting this error code with the following code: this->connect(socket, SIGNAL(socketError(QAbstractSocket::SocketError)), SLOT(handleSocketError(QAbstractSocket::SocketError))); ... void MyClass::handleSocketError(QAbstractSocket::SocketError ...

QsciScintilla marker background color

How to set a marker's background color (SC_MARK_BACKGROUND) within a QsciScintilla instance? I cannot see any way to pass it to markerDefine(). ...

In Qt, how to show keyboard shortcuts in menu but disable them?

I'm adding a bunch of QActions to my main window's menus. These actions can also be triggered by the keyboard, and I want the shortcut to be visible in the menu, as usual, e.g. ----------------- |Copy Ctrl+C| ----------------- I can do this using QAction.setShortcut(). However, I don't want these QActions to be triggered by the s...

How to mix C++ Qt objects and Qt Jambi objects

Hi, I'm trying to combine some existing Qt code written in C++ with some code written in Java using Qt Jambi, but I'm not quite sure how to do it. I'm basically trying to acieve two things: Pass a QObject from C++ to Java using JNI Pass a Qt Jambi QObject from Java to C++ It looks like I can pass the pointer directly and then wrap i...

compiling maya (3d application ) with qt

including the maya ( 3d application ) classes in qt program gives lot of errors..... i have added all required include paths and libs...the same problem persists .... this is pro file for my qt project TARGET = FileCon TEMPLATE = app SOURCES += main.cpp \ dialog.cpp HEADERS += dialog.h \ ConvertFunction.h FORMS += dialog.ui LIB...

QT4: Transparent Window with rounded corners

How can i create a partially transparent window with rounded borders (no standard borders)? (i used Qt::FramelessWindowHint to disable standard borders) I tried stylesheets, but "border-radius" and "opacity" doesnt seem to have any effect on the window, it only works on children of the enclosing widget. My second idea was, to make the...

Ruby + QT4; how to start

trying to add QtRuby support on my gentoo linux.. i dont find any qt gem in repository download qt4-qtruby but cmake fall.. please say right way to setup.. ...

What is the'debug out " from Qt's QObject::dumpObjectInfo()

The doc says it "Dumps information about signal connections, etc. for this object to the debug output." How does one set the binding of Qt's "debug output" to a file or stderr or something? ...

use dll in qt creator

how can use dll in qt Creator? which i created in visual Studio. ...

How to serialize shared/weak pointers?

I have a complex network of objects connected with QSharedPointers and QWeakPointers. Is there a simple way to save/load them with Boost.Serialization? So far I have this: namespace boost { namespace serialization { template<class Archive, class T> void save(Archive& ar, QSharedPointer<T> const& ptr, unsigned version...

How to cross compile qt application for different platforms.

How can I cross-compile my application on Qt. As for each project I need two version 1). Which runs on computer on Qvfb & i386 Architecture 2). Which runs on device with Linux Framebuffer & ARM Architecture I have already compiled Qt for device as well as for Qvfb. I am able to run examples on both platforms, But How can I cross-co...

how to have a virtual onscreen keyboard in qt for embedded linux?

how to have a global virtual onscreen keyboard in qt for embedded linux? ...

qlist error when running qprocess in a loop

Hi, I am doing following in the attached file 1.txt. a) read a list b) for each item in the list c) run an external process save it in A file d) read A file, save modification in B file e) thatz it and following error occurs. ASSERT failure in QList:perator[]: "index out of range", file /opt/qtsdk-2009.02/qt/include/QtCore/qlist.h, l...

Accessing the child UI elements in a Qt UI

I have defined a UI (let's call it myUI) using the Qt designer, and using it in my applications. I need to access all the sub-widgets (QToolButtons) in myUI. I want to get all the subwidgets as a QObjectList. Is there any way to do this? The QObject::children() doesn't work here because the Qt UI Compiler, when converting the .ui file...

What is a good way to load an application specific font on Qt on Symbian?

Is it possible to use QFontDatabase::addApplicationFont() in Symbian? It seems to return -1 (error) even if the file exists? If not, is there some alternative to this, apart from system-wide font installation? Thanks. ...

Qt designer plugin does not load in Eclipse CDT

Hi, I have installed the Qwt widgets and they run fine in Qt Creator and QT 4 Designer; however when I run the QT Designer via Eclipse CDT they don't show up. Any ideas what is wrong? I am on x32 Ubuntu 9.04 (Jaunty Jackalope) and running Eclipse CDT 3.4.2 (Ganymede). Note the Qt add in otherwise is working fine and I can create and de...