qt4 Questions
10
i just asking myself how to restart my own qt application?
Can somebody please show me an example?
Revealment asked 26/2, 2011 at 21:13
7
Solved
I've tried these in my mainform's constructor:
QRect desktopRect = QApplication::desktop()->availableGeometry(this);
move(desktopRect.center() - frameGeometry().center());
QRect desktopRect = ...
3
Solved
I am using Qt 4.5 in Windows XP. My pro file has the variable VERSION = 1.0. Now i need to read this variable and get its value (1.0) from the source code. So that I don't have to maintain another ...
1
I want to get a screen shot of the widget application and then set its raw data buffer to QMeidaPlayer with setMedia(). What I have done so far is to receive the image, SAVE it, and then read from ...
1
Suppose I have a gridlayout of three columns. I want each column to have custom width. Seems to me that the width of the columns are fixed automatically.
How can I do this in the qt designer?
Pinter asked 19/10, 2015 at 4:18
2
Solved
I have small doubt about Qt memory management.
Let's take an example of Listview, in listview we add each item by allocating memory dynamically. So in this case do we need to delete all the "n...
3
Solved
I am using Qt 4.6.3 and the following not-working code
QStringList userInfo;
QNetworkRequest netRequest(QUrl("http://api.stackoverflow.com/1.1/users/587532"));
QNetworkReply *netReply = netman->...
Mogador asked 30/3, 2011 at 12:11
4
connect(ui->ComboBox,SIGNAL(currentIndexChanged()),this,SLOT(switchcall()));
in qt, combobox items i have none,server,client.when i select one of this it should call switchcall function.in thi...
10
Solved
I want to remove all the trailing whitespace characters in a QString. I am looking to do what the Python function str.rstrip() with a QString.
I did some Googling, and found this: http://www.qtfor...
5
Solved
Although Qt's docs indicate that these two functions are different (the first doesn't include the frame) no matter what widget I choose - including the main window of my application - someWidget-&g...
2
Solved
I am making a GUI program using Qt4, under git source control (Github page). Small part of project requires scanning and parsing. So I want to use flex and bison with the project. I can think of 3 ...
Tennant asked 19/1, 2013 at 8:14
3
Let's say some images have to be generated by a Qt console program and that font metrics are needed by internal algorithms (they use the text width/height as input to compute the position where the...
Betts asked 30/7, 2015 at 19:44
5
Solved
Is there any way to integrate Boost.Asio with Qt4 (preferred) or GTK main loop?
GTK provides poll(2) like API so technically is should be possible. Qt provides its own networking layer, however I p...
Overcareful asked 16/6, 2009 at 11:57
4
Solved
The net is flooded with similar questions, but for all I have seen nothing suits to solve the problem at hand.
In my QT-C++ app, I have a mainwindow form with some functions, there is a QPushButto...
3
7
Solved
What do you guys/gals think would be the best way to remove leading zeros from a QString?
I am dealing with numbers like:
099900000002
008800000031
88800000043
Do I have to iterate over every c...
4
Solved
I am aware that to use the signals and slots mechanism of Qt inside a class, the class must include the Q_OBJECT macro, but I am attempting to use signals and slots in main(), without using any cla...
Marketa asked 24/5, 2013 at 12:5
6
I am trying to open and read a PDF file using Qt, but there is no specific way to do that.
6
Im trying to read from a file and put into to the text edit and it keeps saying QIODevice::read:device not open. The .txt file is in the same location as my .qrc and .cpp file. I was following a st...
Pinchcock asked 25/7, 2014 at 19:22
4
Solved
I've just downloaded Qt (LGPL - Qt SDK for Windows) and when i run some of the demos they complain about Qt not having SSL.
How can i get the Qt SDK with SSL enabled? Do i really need to compile it...
2
Solved
I'm facing strange problem. Namely, Qt somehow turns off exception handling in my program. I can't catch any exception, and when I throw an exception application crashes.
I'm using Qt 4.7.0 (32 b...
2
Solved
I need to display text with a QLabel with following requirements:
Word wrapping
Expand from small width to full width according to the length of the text while the label takes a single line
Always...
4
Solved
My development box is Windows 7 x64. I have both 32-bit and 64-bit versions of Qt 4.7.4 built on my box. When I configure my app to use the 32-bit version of Qt, it runs fine in Qt Creator (ctrl-R)...
Hageman asked 23/8, 2012 at 20:2
5
Solved
I'm working on a custom Qt button that allows you to edit the text on the button if you double click it. When the button is double clicked, a QLineEdit appears where the text on the button is allow...
2
Solved
I have a open file dialog with three filters:
QString fileName = QFileDialog::getOpenFileName(
this,
title,
directory,
tr("JPEG (*.jpg *.jpeg);; TIFF (*.tif);; All files (*.*)")
);
This disp...
© 2022 - 2024 — McMap. All rights reserved.