All Questions
3,381
questions
-1
votes
0
answers
25
views
How to read/write whole drive in Qt?
I'm looking for a Qt class to handle whole drive like the following Windows APIs:
HANDLE hd=CreateFile("\\\\.\\C:",GENERIC_READ,...);
...
ReadFile(hd,...);
WriteFile(hd,...);
QFile seems to ...
1
vote
1
answer
59
views
Why is this QAbstractItemModel based model not working?
I create a simple QMainWindow app as follows:
The header file:
//mainwindow.h
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include <QAbstractItemModel>
#include <QTreeView>
#include <...
0
votes
1
answer
11
views
Qt5: "socket notifiers cannot be disabled from another thread" issue
I am also facing a similar issue I have a C++ Qt application built on Qt4 and all QTcpSocket implementation was working as expected when I migrated to Qt5 I got this issue:
socket notifiers cannot be ...
0
votes
0
answers
20
views
GroupedDragging in Qt4
In Qt5 I can set the GroupedDragging dock option to my QMainWindow to allow dragging a tabbed dock widget into a new docking area. Is there a way to achieve this same functionality in Qt4. ...
0
votes
0
answers
62
views
Compiling Qt 4.5.0 without QT_NO_CAST_FROM_ASCII
For refactoring an existing project with some older code, I need to compile Qt 4.5.0 as static library, on Windows using the MSVC v143 compiler (Visual Studio 2022).
I'm using configure.exe -static -...
0
votes
1
answer
37
views
Connecting a function to QHttp::requestFinished
I am using Qt 4.1, the last version that compiles to Windows 98 (although I am running this on Windows XP because I have an AMD processor which cannot virtualize win98). I do not have access to more ...
0
votes
1
answer
47
views
In Qt4.8, add a QToolButton to a QMenu, the auto connect not work
I have a QToolButton button1 with a popup QMenu menu. I add another QToolButton button2 into the menu. I have already defined the ObjectName. But the auto connect only works for button1, not button2.
...
0
votes
1
answer
27
views
Unable to retrieve the y-coordinate of the selected cell of a QTableWidget
I'm implementing a QTableWidget in my Qt app (version Qt 4.8).
This QTableWidget is made of 18 QTableWidgetItems
When the user wants to change the current selected cell, it just calls:
tblWdgList->...
0
votes
1
answer
1k
views
How to investigate heap corruption on Windows?
I've observed a crash to desktop. After debugging it turned out that it was somehow due to an unintended destruction of an object, but I'd like to understand why this results in heap corruption. And ...
0
votes
1
answer
364
views
Convert custom type to QVariant
I have my custom type:
enum class MyType : int {
TYPENAME1 = 0,
TYPENAME2 = 1,
TYPENAME3 = 2
};
I need to convert MyType to QVariant. I tried qDebug() << QVariant::fromValue(...
0
votes
0
answers
224
views
How to remove default blue selection of QTreeWidget?
I have a QTreeWidget with rows having some colors. When I try to select row (using mouse click) row's color changes to blue.
I have clicked on middle row
To avoid change in color, I used following ...
0
votes
1
answer
252
views
How to convert a TIF file into a BMP file in C++98 using QT 4?
I am new in C++. How can I convert a TIF file into a BMP file in C++98?
Here is my "newForm.h".Here is private slots for loading tiff and coverting the image.
#ifndef _NEWFORM_H
#define ...
1
vote
0
answers
50
views
Getting wrong name in mouse hover property in Qt
I am having QGraphicsScene which contains many digital gates ( AND,OR,NOR etc ) which are made up of Arc, Polyline, Circle, Straight line etc.
I am implementing a feature like, when I hover mouse over ...
0
votes
1
answer
40
views
What is different QKeyEvent modifiers in Qt4 and Qt5
When I enter the number pad side of the keyboard in qt4, I want to receive QEvent::KeyPress and process it.
However, if I check the modifiers() of the event, KeypadModifier should come in, but ...
1
vote
1
answer
35
views
How to easily recognize searched item in a dense QGraphicsScene?
I have a QGraphicsScene with many QGraphicsItem like circle, rectangle, polylines, arc etc.
Every QGraphicsItem has a name. And I have a Search feature which highlights searched items using that name. ...