Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.6k Posts
  • How to size QPushButtons to width of text and pack left?

    Unsolved
    3
    0 Votes
    3 Posts
    5k Views
    SGaistS
    Hi, To ensure they are pushed to the left, add a stretch after the last button.
  • Simple REST API receive image and return json

    Unsolved
    5
    0 Votes
    5 Posts
    438 Views
    SGaistS
    What are you going to use for your AI related activities ?
  • 0 Votes
    5 Posts
    875 Views
    SGaistS
    Hi and welcome to devnet, You are using a relative path so your application will not find the file as it is not located in the same folder. On an unrelated not, please give your thread a meaningful title and put the actual text of your enquiry as the body of the post along with your code.
  • In MAC system in which path I can see the Makefile executable

    Unsolved
    3
    0 Votes
    3 Posts
    297 Views
    SGaistS
    Hi, Xcode will ask you if you want to install the command line tools the first time you'll try to build something. Or you can do it from within Xcode if memory serves well.
  • QObject member variable destruction: deleteLater vs this

    Unsolved
    3
    0 Votes
    3 Posts
    211 Views
    SGaistS
    Hi, One thing that your code does not show is what are the base classes of class A and B. If you want to use them as parent of the members variable, they have to from a suitable base classe.
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    9 Views
    No one has replied
  • multiple resize callbacks on QWindow when user drags corner

    Unsolved
    2
    0 Votes
    2 Posts
    189 Views
    Christian EhrlicherC
    Don't redraw on a resize event but use a QTimer so you repaint only when e.g. the size did not change for 50ms or so.
  • Find exact match for substring in a QString using QRegularExpression

    Solved
    7
    0 Votes
    7 Posts
    2k Views
    MarKSM
    @KroMignon Indeed!
  • Export QTableView to Excel file

    Unsolved
    6
    0 Votes
    6 Posts
    2k Views
    Thank YouT
    @lincoln Did you get the way to do it ? Can you share your code if you have done it
  • QThread parent issues

    Unsolved
    6
    0 Votes
    6 Posts
    931 Views
    R
    @JKSH Here is the output of the debugging it. SocketThread(0x1d02b90b3d0) QThread(0x1d02b870250) QThread(0x1d02b870250) It would see they all have the same id. You don't usually need a thread for a socket. Just leave the socket in the GUI thread. Qt socket classes and other communications classes are asynchronous. i am running a server and i would like to use blocking since that is how i set my sockets up. but i am not sure how you want me to call it if not like i am doing right now.
  • thanks

    Unsolved
    1
    0 Votes
    1 Posts
    102 Views
    No one has replied
  • Cant compile project

    Solved
    8
    0 Votes
    8 Posts
    637 Views
    M
    After a new install from Qt and MinGW it works. Thanks for the help everyone
  • Font size on a 125% display

    Solved
    8
    0 Votes
    8 Posts
    7k Views
    D
    Thank you all, I'll deal with it !
  • printing: Why have you disabeled "reverse order" in "QTextDocument::print" ?

    Unsolved
    5
    0 Votes
    5 Posts
    360 Views
    D
    Thank you all. and The application is responsible for reading the page order and printing accordingly. Not all developers of QT programs are aware of this. Many of them think something like: "My program has no control over the print process. It only calls Qt's print dialog; the rest is done by Qt (and CUPS)." See here: https://github.com/tsujan/FeatherPad/issues/455#issuecomment-731603828
  • Listening and receiving data from a socket.

    Unsolved
    15
    0 Votes
    15 Posts
    1k Views
    SPlattenS
    @jsulm , whilst I try to resolve it myself, granted I could also be reading the documentation.
  • How to move Qt from C:\ to another drive?

    Unsolved move qt
    6
    1 Votes
    6 Posts
    3k Views
    S
    You should reinstall Qt to make sure everything works correctly. Some of the Qt tools - especially qmake - have the installation path baked in. They will not work right away when copied to a different directory. I believe there is a way to fix the paths. However, I cannot remember and I don't know which tools need fixing. To be safe: reinstall Qt in the proper location. It's way easier.
  • QFuture<void> Thread is not Starting

    Solved
    35
    0 Votes
    35 Posts
    4k Views
    KroMignonK
    @Ketan__Patel__0011 said in QFuture<void> Thread is not Starting: try to start and stop both function again and again As written in documentation, to start a new function there must be an available thread in the used thread pool: Runs function in a separate thread. The thread is taken from the global QThreadPool. Note that function may not run immediately; function will only be run once a thread becomes available. You could check before starting function how many thread are already used: qDebug() << "Allowed thread:" << pool.maxThreadCount() <<"/ threads in use:" << pool.activeThreadCount() << "/ available threads:" << (pool.maxThreadCount() - pool.activeThreadCount());
  • How to save QMap

    Solved
    6
    0 Votes
    6 Posts
    822 Views
    Kent-DorfmanK
    The more general term for this is object serialization: translating the object into a well defined format that can be saved to disk or transfered across a network. I'd advise that instead of reinventing and coming up with a custom format. You should review existing formats like XML or JSON, and if appropriate, then acquire or write translators to go between native format and the "serialized" format. Qt already has some serialization capabilities but I don't use them so I'm not sure what specifically exists.
  • One more basic C++ question

    Unsolved
    3
    0 Votes
    3 Posts
    239 Views
    jsulmJ
    @AnneRanch connect(ui->list, &QListWidget::itemClicked , ui->list_2, &QListWidget::addItem); https://doc.qt.io/qt-5/signalsandslots.html If using overloaded signals see https://stackoverflow.com/questions/16794695/connecting-overloaded-signals-and-slots-in-qt-5
  • QFileSystemWatch -checking the possibility

    Unsolved
    8
    0 Votes
    8 Posts
    706 Views
    M
    @meganathan If you must call it from a python script, call exit(your_process_exit_code) at the end of the script; passing along the exit code of your process.