I've been using QPlainTextEdit for editing text in our application. Recently it was decided that we need to display the text in a paginated format instead of a consistent block of text. After lots of research, I've come to the realization that while QPlainTextEdit does not have any knowledge of pages or pagination, QPlainTextDocument doe...
Greetings all,
I use MinGW,QT and CMake for my project.
As shown in the figure, my project has two modules.
libRinzoCore.DLL - a shared library which define some abstract classes and interfaces and some core functionality of the application.This module is used to implement dynamic Plugins (which are also shared libraries which auto...
(C++/Qt) I have a smart pointer to a QObject. Let's say a QWeakPointer. For some external reason (something that might happen in another object or due to an event), it is possible that the pointed object gets destroyed. Since I have a smart pointer there will be no dangling reference, so there's no problem. But I always have to check if ...
Hi,
I made a prototype of a project with PyQt and made it work there, now I'm trying to convert it to C++ and am having some problems.
If I don't put the Q_OBJECT macro in, it compiles and works, but if I comment it out, I get the following errors:
Undefined symbols:
"vtable for MapView", referenced from:
MapView::~MapView()in...
I cannot find a way to set the text alignment in a QTabWidget.
After I've created an instance of this widget, I've set its tabPosition property to West, but I wish it showed text/label horizontally.
I've given a look to the Qt's stylesheets, but as you can see, the text-align property can only be set on QPushButton and QProgressBar.
I...
Hi,
I want to place some widgets in a parent widget in some random places, like one button at Point (10,10) and another at (15,40),etc. How to achieve this. QGridLayout is pushing everything into row column style. But I want to put the widgets whereever I want,Can anybody help me?
...
i am creating a software using C++ and QT,and i have two widget one of type QRadioButon and one QTabWidget. My need is that i want to send signal from a radio button and i want that whenever the button is checked the content of tab get changed.
Can anyone suggest how to do that? I tried creating a slot of my widget class and in that slot...
I am using the Qt script engine in my application as an alternative way for the user to access its functionality. As such, I export some C++ classes to the Qt ScriptEngine, that will serve as the interface to the application. The problem is, these C++ classes can throw exceptions.
I have a "ScriptInterface" class running on its own thr...
What is the best way to render capsule-style toolbar controls (including the label text below the buttons) in a Qt application?
As far as rendering the buttons, I want to tap into what is provided by Mac OS as much as possible. (I'm not a Mac developer, so do not know if it has an API for this.) That is, I know I can draw them myself, u...
I want to display data in multiple columns in a QColumnView. I am using Qt Creator and Qt 4 for development.
Consider an address book application where you have multiple groups: Group 1, Group 2, etc. Your contacts can belong to any of those groups.
Group 1:
John Smith
Pocahontas
Group 2:
Chief Powhatan
Group 3:
...
W...
Here's my use case (very simplified).
I have some data from DB in QSQLTableModel and I need to transform it: merge few fields into one (and display as such) or split one field into few. How and where this should be done in Model/View?
Notes:
I tried using AbstractProxyModel to do this, but I guess, it's suitable only for filtering or...
I have a window containing a QScrollArea with a couple widgets in it.
Until now, I was creating the QScrollArea and its child widgets in the constructor of my window, and then I was resizing the window vertically to fit its content using resize(400, sizeHint().height()). So far, so good.
Now, I'm adding or removing widgets in the QScr...
We have a fairly large code-base. The vast majority of the code is compiled using qmake to produce the makefiles. However, there are some sub-projects that get produced by running batch files or running other programs.
I'd like to be able to have everything compiled using qmake, but I can't figure out how to get qmake to simply run a ...
In Qt, there is no "QGraphicsPolylineItem", so I have to implement it form QGraphicsItem.
I reimplement 'paint' and 'boundingRect' functions.In 'paint()' function, I just simply draw all lines in the polyline.
It's OK without any user's interaction.
For selection and movable function, I reimplement the 'QPainterPath* shape()' functio...
I have written a simple qt application with qt creator, I have tested with PC simulation and N900 device, It's OK. Qt Creator created a .deb file in my mobile. but it can't be installed. The installer always complained "incomplete package..."
The SDK document says I can modify my application's version, or I can skip the package step in ...
Is there a way to use QT 4.6.3 visual controls with Lazarus 0.9.28.2 Beta?
How I can install the QT widgets and have them in my Controls pallete?
...
I compiled the speex library for symbian using carbide C++. The compile completes with zero errors/warnings.
I use the compiled library in my QT application. Compiling the QT application gives the following error -
warning: COMDAT symbol '.exc$T' does not match section name '.rdata'
(Its really an error, not a warning. the word warnin...
Greetings all,
I am trying to implement a QT Plugin with CMake. But this "Q_EXPORT_PLUGIN2" directive stops my class from compiling. I can compile the plugin if I commented this out,but it won't work as a plugin if I do so.
QT doc says:
Q_EXPORT_PLUGIN2 ( PluginName, ClassName )
The value of PluginName should
correspond to the...
Hi all!
I have a question about supporting of QtConcurrent in Qt for Symbian. I use Qt 4.6.2 but I'dont understant how to use QtConcurrent. All works fine on Wice platform in the same version of QT, but doesn't work on Symbian. How to enable QtConcurrent, QFuture, QFutureWatcher?
Big thanks in advance for your answers!
...
Here my code snippet:
query.next();
qDebug()<<query.lastError();
qlonglong res=query.value(0).toLongLong();
qDebug()<<query.lastError();
and the corresponding log I have:
Debug: QSqlError(2006, "QMYSQL: Unable to execute query", "MySQL server has gone away")
Warning: QSqlQuery::value: not positioned on a valid record
Debug: QSqlErro...