Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.5k Topics 457.1k Posts
  • Unable to Do Windows Deployment for LLVM

    Unsolved
    1
    1 Votes
    1 Posts
    1k Views
    No one has replied
  • QTextEdit - not accepting keyboard inputs

    Moved Unsolved
    2
    0 Votes
    2 Posts
    2k Views
    SGaistS
    Hi, You should provide minimal compilable example that shows that behaviour. Also, which version of Qt are you using ? On which OS ? Finally, in this code you are leaking QDate objects. The same goes of the widgets you create in that function. Each time you call it a new set of them will be created without deleting the old ones.
  • This topic is deleted!

    Unsolved
    2
    0 Votes
    2 Posts
    15 Views
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    6 Views
    No one has replied
  • 0 Votes
    4 Posts
    2k Views
    R
    @Bonnie Thanks -- yes, that was exactly the problem! :) The Qt Creator wizard "helpfully" set up the parameters like this when I added the class. When I changed the parameter name, it works without qualifying the function call. Marking this now as "solved".
  • 0 Votes
    5 Posts
    2k Views
    D
    @JonB Thank you for your suggestion. It is feasible for me to move it after "ui_mainwindow.h"
  • how to make a combo box read only

    Unsolved
    11
    0 Votes
    11 Posts
    6k Views
    JonBJ
    @stokito As @SGaist says. What does "ReadOnly" here mean to you, and what is "Modified" about? For read-only, do you perchance mean setEditable(false)? That is for the user to be able edit/insert items into the combobox choices. But that is the default anyway.
  • QTOPCUA simulationserver examle

    Unsolved
    6
    0 Votes
    6 Posts
    2k Views
    JKSHJ
    @dencla said in QTOPCUA simulationserver examle: @sbela I thought that I did that when I did the build on qtopcua. Or am I missing something? It said that it was successful. Did you install it? cmake --install . This assumes that you had your CMAKE_PREFIX_PATH set correctly, for example by using the qt-cmake tool: https://doc.qt.io/qt-6/cmake-build-on-cmdline.html#qt-cmake
  • How to make QByteArray read Full Text file?

    Solved
    21
    0 Votes
    21 Posts
    15k Views
    SGaistS
    @stokito said in How to make QByteArray read Full Text file?: Java has Files.readFileContent() and even Files.readAllLines(), similar .NET has File.ReadAllText(). Why does the QT/CPP doesn't provide a simple way to do this? Hi, It has: QFile::readAll.
  • Qt6Widgets.lib linker error

    Unsolved
    3
    0 Votes
    3 Posts
    1k Views
    SGaistS
    Hi and welcome to devnet, You seem to have somehow configured Visual Studio to point to the libraires installed along Qt Design Studio which are not meant for development but just for the tool to run. You should have a full Qt installation available and should point VS to that one.
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    1 Views
    No one has replied
  • How do I check for Shift + Tab?

    Solved
    10
    0 Votes
    10 Posts
    2k Views
    J
    @SGaist alright... thanks for the advice! Since I'm only targetting KDE and I have to map the Qt key bindings to custom cross-platform enums used by my application, I've tested that Shift + Tab works. But this is indeed useful to know as soon as I'm building cross-platform stuff. Marking as solved.
  • QTextBrowser causing a program to crash

    Unsolved
    7
    0 Votes
    7 Posts
    4k Views
    BugSleeperB
    try QString Dialog::cleanText(const QString text) { QString temp = text; QChar* str = temp.data(); for(int z = 0; z < temp.size(); z++) { if(str[z] > 0x7F || str[z] <32) { str[z] = 0x20; } } return temp; }
  • 0 Votes
    6 Posts
    456 Views
    SGaistS
    I think I looked at the former. I currently don't know if it's possible to have a better error handling / assert but it might be worth to open a feature request on the bug tracker for that.
  • How to keep background-color of QTavbeView when it lose the focus?

    Solved
    2
    0 Votes
    2 Posts
    517 Views
    SGaistS
    Hi, You can alter the palette of your QTableView to modify the colors in the inactive state. This StackOverflow answer shows it.
  • GUI events slow down long computations

    Unsolved
    27
    0 Votes
    27 Posts
    7k Views
    V
    graph points() is the function to be called to log/save the calculated value in a text file. New_data() is the signal which is emitted in this function has to be received in QML side. I surfed through the website.They are saying the Math library operations will slow down the performance.That's why I'm using concurrent run. I doubted at the Batch processing because i'm developing real time application in which batch processing introduce a little bit delay I wish to develop the UI in QML that's why i avoid the Qt c++ gui. when not implenmented in concurrent run, it is introducing some delay
  • RichText: how to insert "icon from theme" ?

    Unsolved
    4
    0 Votes
    4 Posts
    1k Views
    KH-219DesignK
    Hopefully someone with more experience than I with "icon themes" can come and comment. Please, come one; come all 🙏 @dextermagnific Ok got it. Well in your case, I went and skimmed this file: https://github.com/qt/qtbase/blob/dev/src/gui/image/qiconloader.cpp In skimming the code, it appeared to me that the only platform-specific implementation is QIconCacheGtkReader. Thankfully (for my sanity), it appears that the docs confirm this: https://doc.qt.io/qt-6/qicon.html#themeName (quote: "Platform icon themes are only implemented on Freedesktop based systems at the moment") https://doc.qt.io/qt-6/qicon.html#fallbackThemeName (quote: "Platform fallback icon themes are only implemented on Freedesktop based systems at the moment") So that makes me wonder if you only need your planned icon-theme approach to work on Linux? Have you tried QIcon::fromTheme on Windows or Mac and were you happy with the results? (Keep in mind that I am still speaking as someone who has not used the "icon theme" feature of QWidgets even once. Please double-check my comments with added research because I don't want to lead anyone astray!) If you only need it to work on Linux, then you can probably just look at QIconCacheGtkReader and learn how the icon selection is done for Freedesktop. (note to readers: I acknowledge my sloppy language conflating Linux and Freedesktop.)
  • what should i do to disable the qDebug() method on the release version?

    Unsolved
    2
    0 Votes
    2 Posts
    974 Views
    JonBJ
    @nicker-player said in what should i do to disable the qDebug() method on the release version?: DEFINES += QT_NO_WARNNING_OUTPUT This is misspelled (you should always look things up and copy+paste not type, especially if English is not your native language), so if you are getting a warning it might be why? If there are qDebug() statements in Qt code rather than explicitly in your own, #define will make no difference. I do not know whether Qt's own Release libraries are are compiled with QT_NO_DEBUG_OUTPUT or not. Correct the spelling and see where that gets you.
  • QTextDocument + QML TextArea ideas for handling large content

    Unsolved qtextdocument textarea richtext
    2
    0 Votes
    2 Posts
    997 Views
    D
    I found marknote, I see that the performance is fine, but I don't understand why, the logic in general is very similar
  • This topic is deleted!

    Solved
    4
    0 Votes
    4 Posts
    348 Views