qt4

How to enable context menu on a VerticalHeaderItem inside a QTableWidget?

I have QTable widget, where I set setVerticalHeaderItem(0, QTableWidgetItem("some header", 0)) I set a contex menu by setContextMenuPolicy(Qt.ActionsContextMenu) and it works fine on my table's elements other than 1st column, i.e. a VerticalHeaderItem. Basically, when I right-click on 1st column item a context menu doesn't pop up, ...

get several values from the user in QT

Hello, I am working on an application which uses the QInputDialog command to get a value from the user. The value is then used in several computation in the application. I want to modify the application in the following way: I want to the able to read several values from the user before the computations are performed. Any idea of what ...

Qt - Switching from shared build to static build? (VS 2005)

The situation is this: I have a shared (DLL) build of Qt 4.5.1 and some reasons given by the project lead, I have to convert to Qt 4.5.2 static. I am using the Qt Visual Studio plug-in to manage my project. 1) Would DLLs (Qwt 5.2 and other Qt solutions) compiled with the shared Qt 4.5.1 work with an EXE compiled with static Qt 4.5.2, or...

QProcess::setStandardOutputFile only creates 0kb File

I'm using a simple QProcess-Project on a WindowsXP-Machine: QString program = "U:\\ffmpeg.exe"; QStringList arguments; arguments << "-i" << "U:\\clock.avi" << "U:\\tmp_jpeg\\foo-%03d.jpeg"; process.setStandardOutputFile("U:\\log.txt", QIODevice::Append); process.start(program, arguments); The Process works just fine, ffmpeg creates a...

Qt4 starting and stopping (pausing)

Ok, so I'm having this problem tonight: [...] connect(startButton, SIGNAL(clicked()), this, SLOT(startCalculation())); connect(stopButton, SIGNAL(clicked()), this, SLOT(stopCalculation())); [...] void MainWindow::startCalculation() { qDebug() << "hello"; this->startButton->setDisabled(true); this->stopButton->setEnabled(t...

In Qt, create a table with an blank editable row

This is a Qt-specific question. It's convenient to be able to add new data to a table by typing content into a blank row at the bottom of a table. When the data is committed, a new blank row is added to the table. Has anyone found a way of implementing this in a generic way, that fits into Qt's model-view programming architecture? My c...

Trouble with ActiveQt

I'm trying to get the examples of using ActiveQt working with my Qt Commercial 4.4.2 release (my commercial support expired). So far no luck. I keep getting "Failed to create component 'AxHost'". Sorry, not much to go on. My goal is to allow a client to use a widget from my app in their C# application. Am I taking the right approach...

PyQt: Trouble with asterisk on modification in QPlainTextEdit

I'm having a problem with a QPlainTextEdit. I want the "contents have been modified" asterisk to appear in the title bar whenever the contents have been modified. In the example below, type a few letters. The asterisk appears as it should. Hit Ctrl+S, the asterisk disappears as it should. But then if you type a few more letters... w...

Create Linux install for Qt application.

Hi, I just made a great program with Qt Creator. I'm very pleased with myself. How do I move it from my desktop to my laptop? So, the best way would be an installer right? And for Ubuntu, that's a debian package right? How do I do that? Has someone done this and could they share the template files for QT 4.5? Thanks, Mike ...

Building Qt 4.5 with Visual C++ 2010

Did somebody tried to build Qt 4.5 with Visual Studio 2010 (Beta 2)? Any hints on doing that successfuly? Later edit I tried to run configure from a Visual Studio 2010 console. There is no makespecs support for 2010, so configure fails because of that. ...

Nokia QT 4 for Visual Studio 2005 and Visual Studio 2008

I downloaded the latest open source version of QT4-and its installed in c:\qt\2009.04. I've also downloaded the QT4 Visual Studio add-in 1.1.0. I want to set it up for both Visual Studio 2005 and Visual Studio 2008 . Most of the docs online are for older versions. What steps do I follow? ...

How do I controll clipping with non-opaque graphics-item's in Qt?

I have a bunch of QGraphicsSvgItem's in a QGraphicsScene that are drawn connected by QGraphicsLineItem's. This show's a graph of a tree-structure. What I want to do is provide a feature where everything but a selected sub-tree becomes transparent. A kind of "highlight this sub-tree" feature. That part was easy, but the results are ugly ...

Smooth text animation (Marquee text effect) using QT

I have a question about how to make marquee text smooth (using Qt 4.5.3) on not powerful hardware (Atom N270 + Intel 945GSM). My approach is as follows: I draw my text (36px Arial bold) onto a QPixmap (off-screen paint device) I set a timer to shift 1px content to left in each 30ms. When onTimer event is triggered, I make a selection...

How develop a financial software in Qt?

I want to create a little finance-software for my association. I want to keep it simple and easy-using, creating new persons should be possible, and every person has entries and costs. The programm should calculate the sum in every step and the total of every person. Now my question: What is a good way to realize that? I thought about SQ...

Moving Qt UI code out to separate class

I'm just starting with Qt. Despite spending sometime on it this evening, I'm struggling to move my UI setup code out of main into it's own class. #include <QtGui> int main(int argc, char *argv[]) { QApplication app(argc, argv); QWidget *window = new QWidget; QLabel *hw = new QLabel(QObject::tr("Hello World!")); QHBox...

Qt in a professional setting

While I have played with parts of Qt in the past I am thinking of putting some real effort into learning it but also wondering what the potential monetary payback might be down the road. So I have some general questions about Qt's future. What is Qt's place in the job market? Are there many, or do you sense a growing number of install...

Windows-like Qt4 Menubar in Mac Os X.

I would like my application to look similar to that of the Windows version: instead of the menu being displaced to the top menu in Os X, I'd like my program to have the file menu right on top of the application itself. I've looked at the Qt documentation regarding this, but I can't seem to create an empty QMenuBar as the top level QMenu...

Where is qembed tool in QT4.5?

Or how could i embed .qm files into my application? I'm using qt-creator. Thanks. ...

QComboBox inside QTreeWidgetItem

Is there something similar to the (PyQT) QTreeWidgetItem.setCheckState(0, Qt.Checked) but for the combo box? I can't see anything in the reference, so how can I insert a custom QComboBox as one of the elements within QTreeWidgetItem? ...

Installing Qt4 on Windows - do I need to fully install MingW or just have local copies

That is, can I get away with DLLs in the install directory or does the installer need to ensure that MingW is fully installed? ...