Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.5k Topics 457.3k Posts
  • qt forex trader app

    Locked Unsolved qt desktop app
    3
    0 Votes
    3 Posts
    265 Views
    JonBJ
    @majidpiryonesi Find out what the "#Forex broker" offers as an API to interface. Maybe you exchange data with it over https, Qt has QNetworkAccessManager.
  • GPU usage shooting up when using OpenGL

    Unsolved
    3
    0 Votes
    3 Posts
    398 Views
    S
    @J-Hilk I have tried this application in other systems and the issue remains. The thing is I am using qt only for wrapping up a web application i.e QT is only providing the framework for supporting it in desktop and providing the basic save, open project dialogs. We are not using it to provide shaders and textrues. We use OpenGL for hardware accelaraion. Is DekstopGL the default implementation in windows if we dont mention anything and use QApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
  • App is crashing for unknown reasons...

    Unsolved
    5
    0 Votes
    5 Posts
    297 Views
    C
    @rockonrover Given the warning, "QWidget: Must construct a QApplication before a QWidget", ask yourself: Does my main() construct a QApplication object at all? Does my application create any QWidgets before it constructs the QApplication? They could be explicitly created in main() before QApplication, or because you have QWidget objects as statics, file or global variables.
  • QSerialPort and local echo

    Unsolved
    3
    0 Votes
    3 Posts
    353 Views
    S
    @mzimmers Thanks for the reply! That is what I was thinking - that if something on my machine was "echoing", it would probably not be replacing the \r with a \n, and I could find nothing that indicated that QSerialPort would do such a thing - only that the ability to control local echo was not a part of the interface...which left me not knowing exaactly what to expect - read on one of these forums that I could get a "handle" for the port and maybe do something with that, but that was also a dead end. Will try an analyzer. Thanks again!
  • How to prevent QSystemTrayIcon's contextMenu from hiding when clicked?

    Unsolved
    1
    0 Votes
    1 Posts
    183 Views
    No one has replied
  • Creating Cross-platform application. Initial guidance requested. Please HELP!!!

    Unsolved
    2
    0 Votes
    2 Posts
    192 Views
    SGaistS
    Hi, No you don't need the commercial licence for the targets you listed. If you want LTS support then yes, a commercial licence is required. As for what to do, each platform has a getting started guide in the Qt documentation explaining what you need to download / setup in order to be able to build for that platform.
  • Qt 5.15.2 MySQL plugin for M1 architecture

    Unsolved
    4
    0 Votes
    4 Posts
    367 Views
    SGaistS
    The PostgreSQL plugin is already available. The only thing that you may have to do is to update the search path for the library in the plugin based on how you installed PostgreSQL. Way simpler in contrast to building the MySQL plugin.
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    12 Views
    No one has replied
  • Options for qscxmlc in .pro file

    Unsolved
    3
    0 Votes
    3 Posts
    211 Views
    larry104L
    @JonB I use qt 5.7 and I meant it does not get passed as argument.
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    2 Views
    No one has replied
  • I have a LogDisplay application. I want to reduce Time Complexity.

    Solved
    9
    0 Votes
    9 Posts
    692 Views
    JonBJ
    @piervalli Your thought is not wrong, but it will make 0.00001% difference here :) The only thing which could take any time is updating of the UI.
  • How Paint a background section in a QHeaderView?

    Solved qheaderview
    2
    0 Votes
    2 Posts
    552 Views
    Christian EhrlicherC
    Since you don't call the base class impl - what do you expect? Overrride initStyleOption() and set the desired color for QPalette::Window or even better override initStyleOptionForIndex()
  • QTableWidget hover entire row without hard-coding background color

    Solved
    6
    2 Votes
    6 Posts
    5k Views
    JoeCFDJ
    @JonB this piece of code will not work well when rows are selected. It is better to have a setting in QTableWidget/View: something like: enableRowHovering( bool value = false ); I will send a request in the developer's mailing list.
  • Dear ImGui recommended porting

    Unsolved
    3
    0 Votes
    3 Posts
    688 Views
    M
    @Pl45m4 thank you so much
  • Cent0S 7 best Qt5 version and xcb fix

    Solved
    6
    0 Votes
    6 Posts
    875 Views
    Q
    Well, i did figure it out, kinda ... For CentOS 7 - DevTools 7 - the best Qt version are 5.8 to 5.12. Depends on what you want to do. I wrote a script and did compile all of them in with all or nothing, shared and static. Kind like alchemy (-; I knwo there are docs and feature update news but it is still most of the time unclear what version will work at all.
  • Qt Static Compile Linux - Error Loading libxcb-xinerama.so

    Solved linux static build g++
    14
    0 Votes
    14 Posts
    11k Views
    Q
    I'm no expert but as far as i know, there is static and static. First static is static Qt-Libs second static is a real static standalone executable file. If you want a real standalone executable you have to get a static version of all dependencies ".a" files not ".so". And you have to add some magic to the compiler -static -static-libgcc -static-libstdc++ (add in the Qt source to qtbase/mkspecs/linux-g++/qmake.conf) and if you want to use any kind of networking, you may also need static nss https://github.com/nss-dev/nss (some Linux versions still got static nss avaliable over packed managers). And even if you don't use networking in your app, some other libs may include networking even if you don't use it in your code directly. Good luck! :)
  • Retentive variable value

    Solved
    3
    0 Votes
    3 Posts
    228 Views
    C
    Apart from "RetVal" and "values" not being obviously good choices for organisation and application name respectively, I do not see anything wrong here. I would generally set the organisation and application names on the application object (i.e. one place only) and use the parameter-free QSettings constructor elsewhere. See Basic Usage in the docs. There is rarely a need to call QSettings::sync() directly. It will be called internally when the stack-based QSettings instances are destroyed anyway.
  • Update part of the scrolling QWidget inside QScrollArea

    Solved
    8
    0 Votes
    8 Posts
    831 Views
    P
    @MarKS Can you please share with us what you discovered until now, that would be helpful for anyone facing the same issue as yours, like me. please.
  • QFile::read(char *data, qint64 maxSize) return value

    Unsolved
    3
    0 Votes
    3 Posts
    292 Views
    E
    @mzimmers Hmm. Usually it's a QFile constructed from local file path, but it also can be opened from a file descriptor returned from Android's ContentResolver.openAssetFileDescriptor() (which could be just about anything, although it's usually either a file or a pipe that's written to dynamically on the other end).
  • How can QTextEdit send a message to its owner?

    Unsolved
    20
    0 Votes
    20 Posts
    1k Views
    C
    @JonB There has to be some piece of code somewhere that manages the table row heights. The table itself is unable to handle that. Therefore that code is in its parent, the window. To me this is very simple. The table is unable to resize a row automatically when the editor in a cell needs to grow vertically. The SO code was in Python and some of the methods it showed didn't apply to C++, for instance there is no setHeightMin method.