Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.7k Posts
  • QRayCaster initialization on first frame

    Unsolved
    1
    0 Votes
    1 Posts
    138 Views
    No one has replied
  • Cannot pass vector<float> to the function

    Unsolved
    4
    0 Votes
    4 Posts
    411 Views
    JoeCFDJ
    @lukutis222 And it is better to pass your vector as const reference. I guess you do not want to make a copy of it. float calculate_1_min_average(uint32_t sample_counter, uint8_t index_1_min, const std::vector< float > & average_vector){
  • SIGSEGV in fromStdString

    Unsolved
    23
    0 Votes
    23 Posts
    4k Views
    Pl45m4P
    @Robert-M said in SIGSEGV in fromStdString: other_options If other_options is your struct with your data, you want to send to your dialog, it's fine. Nobody said it's not :) The QVector would make it more variable
  • QFileDialog is works but invisible

    Solved
    20
    0 Votes
    20 Posts
    1k Views
    R
    @JonB Thanks for help, I solved it, I called other method in my constructor and it was blocking everything.
  • how to prevent the QJSONObject to sort by the keys?

    Unsolved
    3
    0 Votes
    3 Posts
    426 Views
    JonBJ
    @nicker-player As @jsulm says. The order is undefined and that is how Qt QJson... sorts output. If you search this forum there have been several long discussions about this a while ago. One of them elected to use some third-party library to do their desired JSON output sorting. I cannot recall what that was, whether it was Python, whether it's available to you....
  • Convert ipAddres to bytes

    Solved
    2
    0 Votes
    2 Posts
    199 Views
    JonBJ
    @Damian7546 QList<QByteArray> QByteArray::split(char sep) const with . as splitter. You might alternatively convert to a QString, pass it to QUrl and use its methods to parse the IP address into segments for you.
  • QCustomPlot changing color with Y values

    Unsolved
    3
    0 Votes
    3 Posts
    922 Views
    L
    @kshegunov Hard to believe this issue been around since 2015. This is good reading but I didint manage to solve my problem. I use different methods of drawing graph than they are discussing. I am very new to QCustomPlot and C++ in general so the whole overriding virtual function thing is still complex to me. Hoping that someone who had simillar issues before with this can give me some additional help here. Thanks
  • QTableWidget itemSelectionChanged triggers

    Unsolved
    2
    0 Votes
    2 Posts
    284 Views
    JonBJ
    @Dummie1138 Well, adding/deleting items will also likely trigger a "selection changed". Check QList<QTableWidgetItem *> QTableWidget::selectedItems() const for what is now selected, maybe it's the same items as before, maybe all selections get cleared on changing items....
  • Can't able to change the pixmap color with QLinearGradient

    Solved
    8
    0 Votes
    8 Posts
    777 Views
    A
    Hi @JoeCFD, Thanks, your idea is working. I have iterated through all the pixels and I have ignored the background color pixels. While iterating through the image, I have incremented the RGB channel data values to apply gradient inside the icon.
  • 0 Votes
    7 Posts
    420 Views
    S
    @jsulm thank you
  • What inspired property binding reactivity?

    Unsolved bindings reactivity
    2
    0 Votes
    2 Posts
    677 Views
    sierdzioS
    @trusktr With property bindings in C++ the answer is easy: the inspiration were property bindings from QML :-) They came first (around 2007, back in Qt 4.7 days). And with QML I think the inspiration was just in the nature of this (by then) new language: QML is a declarative language so you need a mechanism to automatically update values when their components change. And since Qt had signals and slots since early days (early '90), it was quite straightforward to implement this using existing "backend" technology.
  • Suddenly qt creator doesnt launch, linux

    Unsolved
    4
    0 Votes
    4 Posts
    386 Views
    jsulmJ
    @masa4 Looks like another Qt version was installed (looks like 32bit) in /lib. So now, if you start QtCreator the loader finds Qt libraries in /lib which cannot be used with QtCreator as it was linked against Qt libs in /usr/lib64.
  • missing Pyuic5 in installation

    Unsolved pyuic5
    2
    0 Votes
    2 Posts
    462 Views
    Pl45m4P
    @Dsig Are you using PySide or PyQt? What "box"? AFAIK PyUic is a tool that comes with PyQt
  • QMenu And QSqlQueryModel translation problem !

    Solved qmenu qsqltablemodel qtranslator problem qt5.15.2
    5
    0 Votes
    5 Posts
    1k Views
    P
    @SGaist said in QMenu And QSqlQueryModel translation problem !: QEvent::LanguageChange @ SGaist Hi bro <3 i didn't know about QEvent::LanguageChange before really thank you, i will check it <3
  • This topic is deleted!

    Unsolved
    5
    0 Votes
    5 Posts
    60 Views
  • This topic is deleted!

    Unsolved
    2
    0 Votes
    2 Posts
    18 Views
  • QSslSocket::readyRead() never triggered with Python server

    Unsolved
    14
    0 Votes
    14 Posts
    2k Views
    SGaistS
    @ArtiFAS That's one of the issue with the code sample you gave. There's not enough context to fully understand how it is working. Now the question is: why do you need a separate thread to handle your network connection ? Most of the time there's no need for that as Qt is asynchronous.
  • Brings up the image nicely on the label

    Solved pyqt6 image display python
    3
    0 Votes
    3 Posts
    692 Views
    A
    @Pl45m4 Thank you. Documentation for Python : https://doc.qt.io/qtforpython-5/PySide2/QtGui/QPixmap.html Example of code : I give this because of the minimum examples on the internet from PyQt6.QtCore import Qt ... self.labelCropFace.setPixmap(pixmap3.scaled(self.labelCropFace.size(), Qt.AspectRatioMode.KeepAspectRatio)) For other people who need it, hopefully it helps too
  • Automatically include needed files in .pro file

    Solved
    5
    0 Votes
    5 Posts
    426 Views
    JoeCFDJ
    @ocgltd It is totally up to you how to build shared libs, like which classes are added to .so. Qt can not automatically detect what is included in the lib. But when Qt code uses any of classes which are supposed to be in the lib, they should be there. Otherwise, you will see errors like undefined symbols.
  • Qt MySQL does not support TLS 1.2

    Unsolved mysql tls
    2
    0 Votes
    2 Posts
    576 Views
    Christian EhrlicherC
    See https://bugreports.qt.io/browse/QTBUG-84797 MYSQL_OPT_SSL_MODE is not yet added and when it will only be added for Qt6.6 and higher.