qt

problem with QMainWindow setCentralWidget and stackedWidget

Hello i have gui the i created in the designer , simple one . QMainWIndow that contains stackedWidget , the application starts with stackedWidget index 0 that contains qwebkit widget and after some user flow ,it changes to stackedWidget index 1 that contains QTree widget , to center the first widget i use in the QMainWindow constracto...

looking for examples on how to set/build Good looking GUI's in QT

are there some tricks on the subject any thing that will give good looking gui maybe like skype? beyond the OT reference ...

how to create window that opened when close main window??

Hi everyone .. Iam a absolute Beginner in QT.. i am trying to create window that has only text and one push button when you press it, you will get another window that has menu for program .. but Unfortunately, i didn't know how can i create new window and connect it with main window! so, i need to helping you ...

RESTful interface for C++/Qt ?

I want to integrate the RESTful-API in my Qt-Project. I already read the example on this page, but this is only for receiving data from a RESTful-interface, not for sending new data to the server. In Java, I can use RESTlet for example, is there any possibility to use something like that for Qt, too? Or is there even a simple way to send...

How get a focus element in QWebView/QWebPage?

Hi everyone, i need to be able to react on focus changes in QWebPage. I used microFocusChanged() signal and it gives me almost desirable behavior, but anyway i don't know how to know which element is selected. I want to do some actions when any editable element on page gets or loses focus. Thank you in advance ...

Help Me: Loading Qt dialogs from python Scripts

Hello, im a novice into developing an application using backend as Python (2.5) and Qt(3) as front end GUI designer. I have 5 diffrent dialogs to implement the scripts. i just know to load the window (main window) from qt import * from dialogselectkernelfile import * from formcopyextract import * import sys if __nam...

How to find the global screen position of a Qt app?

I need the global screen position of a Qt widget for which I need the application's global position. How can this be found? Thanks. ...

QWebFrame::evaluateJavaScript vs. script-tag in HTML

Hi, I want to develop an application that uses QtWebKit and JQuery. What I need to know is, is there any difference between reading JQuery from a file and evaluateJavaScript it, or embedding it as a script tag within the "page" that is displayed within the widget? EDIT: It seems that I have this figured out at least partially. evalua...

Creating a QMainWindow from Java using JNI

Hi everybody: I'm trying to create a Qt main windows from Java using JNI directly and I got a threading error. My code looks like this: Test class: public class Test { public static void main(String... args) { System.out.println(System.getProperty("java.library.path")); TestWindow f = new TestWindow(); ...

Qt: QAbstractItemModel and 'const'

Hello. I'm trying to use a QTreeView for a first time, with a QAbstractItemModel. And instantly it's a problem: QAbstractItemModel interface declares methods as 'const', assuming they will not change data. But i want a result of SQL query displayed, and returning data for a record with specified indeq REQUIRES to use QSqlQuery::seek() t...

Include QT file problem in Visual Studio 2008

When I type #include <QObject> it complains that it couldn't find file. but if I type #include <QtCore\QObject> It works properly. I moved VS2005 to VS2008, this was not the case in VS2005, and it started with VS2008. Why am I getting this error? ...

QT how to detect the systray area for creating systary pop up windows

hello all i need to create/design QT systray popup windows , i was thinking about creating custom windows that derived from QDialog , so it could look better then the ordinary "Information,Warning,Critical styles" my question is how can i detect the position of the desktop systray ,so how could give the popup windows the look and feel ...

cpp/Qt : per class debugging

I'm developing a Qt application. For each class, I'm trying to mimic the framework, such as error() and errorString() method, use of Private implementation. But I would like to add a per class debugging: Set a macro to the desired level of debug, have a macro or a function that knows the level of debug, and use qDebug() or qWarning()...

Button with text bellow icon

Hi, I am very new to QT UI development. I need to create a button with text should be below the icon. There is no option to set this property to the QPushButton. When I tried to search in the net, they told me to use QToolButton. When I used the QToolButton I could set the Qt::ToolButtonTextUnderIcon. But I couldn’t find a way to chang...

Doing Cross-platform builds with Qt Creator

I am working on a desktop application using the Qt framework and Qt Creator IDE. I am doing my development on mac, and would like to begin testing on Windows as well. I am having trouble finding documentation on how do this. What's is the best way to develop on mac and automate windows builds of a Qt Creator project? ...

Qt - multiple copies of the same app open & settings syncronisation

I have a pretty standard Qt GUI application. It uses Qt's QSettings to store a number of settings, and it all works fine. However, when multiple copies of the application are launched, and settings are changed in one or the other, the different copies can appear inconsistent (as one has the "old" copy of the data). What are the prefer...

Translations using Qt Linguist?

Hi all, I am working on Ubuntu 9.10 aka Karmic Kola and latest version of gcc, Qt 4.6.2. I have installed the french fonts and hindi fonts for ubuntu. I changed the language and Keyboard layout accordingly so that I could type in the abovementioned languages. It worked fine. I then made a sample application and added appropriate transla...

sending custom mouse event into QGraphicsScene

Hi, i'm trying to send custom events into an existing QGraphicsScene. first event is being fired in the scene with the desired location. from now on, all other events go to the same location (as the first event) even if they were provided with other locations. after i manually click somewhere inside the scene, it "restarts" and the next...

problem with QPropertyAnimation in Qt

Hi , i have a problem with QPropertyAnimation in Qt my code: QString my_text = "Hello Animation"; ui->textBrowser->setText((quote_text)); ui->textBrowser->show(); QPropertyAnimation animation2(ui->textBrowser,"geometry"); animation2.setDuration(1000); animation2.setStartValue(QRect(10,220/4,1,1))...

Getting QT to respond to power-events (sleep/hibernate)

I'm trying to develop software that is intelligent wrt sleep events (cleanly closing network connections, making sure data restart locations are set properly, etc). Are there mechanisms in QT (4.6) currently that facilitate me responding to system power events? ...