Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.4k Posts
  • Wizard fails to generate code

    Unsolved
    8
    0 Votes
    8 Posts
    1k Views
    mrjjM
    @efjellanger Hi The buttons and menus are first added in section "Adding User Interaction" So first after than your .h file will have private slots: void newDocument(); void open(); void save(); void saveAs(); void print(); void exit(); and the other elements.
  • Debugging has failed

    Solved debug window debug error debugging debugger engine
    5
    0 Votes
    5 Posts
    3k Views
    xenovasX
    how about changing to MinGW 64 ?
  • How to resize newly added row in QTableView

    Solved
    7
    0 Votes
    7 Posts
    3k Views
    JonBJ
    @asc7uni Given that we have now proved it works after a delay. I don't know, this is a guess, but it might be that the resizing does not work till the new row has been shown, because something about that is required to determine the size. In your slot can you do some kind of .show() on the table view just before the resizeRowsToContents()? [There's no point asking me more about this, you'll have to try whatever you can find and see.]
  • Library OpenGL Mathematics (GLM)

    Unsolved
    2
    0 Votes
    2 Posts
    2k Views
    jsulmJ
    @Nio74 It's a header only library, so download the headers put them somewhere, then add the directory where the headers are to INCLUDEPATH variable in your pro file (see http://doc.qt.io/qt-5/qmake-project-files.html). For everything else you should read the documentation of that library.
  • facing problem in binding

    Unsolved
    12
    0 Votes
    12 Posts
    1k Views
    ManiRonM
    @jsulm actually socket creation itself is a problem server_fd = socket(AF_INET, SOCK_DGRAM, IPPROTO_IP) here server_fd is -1
  • How to set tab stop width and space width?

    Solved
    11
    0 Votes
    11 Posts
    3k Views
    JonBJ
    @legitnameyo One more time: as @J-Hilk and I have said, you'll never get things to line up perfectly if you do not use a fixed/monospaced font.
  • How to close QDockWidget from code?

    Solved
    4
    0 Votes
    4 Posts
    1k Views
    K
    @Yunus Looks like close() does work. There error was elsewhere in my code.
  • How to create a new DataBase in SOL Server

    Unsolved
    10
    0 Votes
    10 Posts
    1k Views
    JonBJ
    @zhmh but you did not know about it and just copied a link, so please do not confuse the questioner if you do not know the answer. That's very kind of you. I know that as I said Qt has no special call for creating a database, and I know that the link I gave you showed & explained the principle of how you can create a new database across ODBC, even if you do not know how to adapt it. I will obey your admonition and not suggest anything further for you.
  • Mouse pressed with right OR left click check?

    Solved click qpushbutt right-click
    5
    0 Votes
    5 Posts
    7k Views
    jsulmJ
    @legitnameyo This is not how it works. You will need to subclass QPushButton and override http://doc.qt.io/qt-5/qwidget.html#mousePressEvent You can find an example here: http://doc.qt.io/qt-5/qtwidgets-widgets-scribble-example.html
  • Arch linux system language mis-match

    Solved
    6
    0 Votes
    6 Posts
    734 Views
    jsulmJ
    @kanishkalback I don't know why this happens on Arch Linux. You could try to ask in a Arch Linux forum.
  • How to save the split string ?

    Solved
    6
    0 Votes
    6 Posts
    994 Views
    Chris KawaC
    @sonichy It does split it, but to parse it correctly you'd need to do another pass and detect that special case. You will also need that for parenthesis and other stuff. Like I said, a full expression parsing is a lot more involved than simple split + for loop.
  • 0 Votes
    9 Posts
    2k Views
    L
    @jsulm thanks for a head start line, figured it here
  • How to choose monitor main window appears on?

    Solved
    2
    0 Votes
    2 Posts
    242 Views
    J.HilkJ
    @kitfox the app appears in the monitor where your mouse curser was during launch, that's the default behavior. After startup, you can use move(), to move your main window over the desktop and you can use the QScreen class to query for information about your desktop. The rest is up to you ;-)
  • How to reset DB table

    Solved
    9
    0 Votes
    9 Posts
    1k Views
    VineelaV
    @jsulm , @VRonin yes well this worked query.prepare("DELETE from farmer1"); query.exec(); thank you guys.
  • Challenges in migration of Qt 4.8.2 project into Qt 5.7 and above

    Unsolved
    7
    0 Votes
    7 Posts
    896 Views
    IamSumitI
    you are right that I should go for latest version of Qt but the thing is I will face the same problem because I am migrating from Qt 4.8.2 and these declarative classes are deprecated and my client's requirement is to make application in Qt 5.7.. My problem is how to display the QML item in QGraphics scene or If I use QML scene then how will I place QGraphicsItem on it? As explained earlier, in 4.8.2 I used QGraphicsScene and some of my objects are created as QGraphicsItems and I place them in background and foreground of the scene. Some of the objects are created as QDeclarativeItem and I added them in QGraphicsScene. While migration in Qt5.7, I found a workaround to place the QDeclativeItem on scene as I have created QQuickWidget and added it on scene but I am not able to make its background transparent because of that my other GraphicsItems are not visible. What will be the best approach to solve this specific problem?
  • 0 Votes
    7 Posts
    7k Views
    4
    That error is usually happening with the shared version when an application has not been properly deployed. What do you mean shared? is that as opposed to the static build i've been trying to do? Sorry but I don't understand how your post is meant to help me. The application hasn't been 'deployed' (windeployqt? which i shouldn't need to do anyway because its meant to be static/standalone) yet because I'm still working on it in creator. The other plugins i need are now statically built / installed as was in an above response. The only thing that doesn't show up is the windows in "%QTDIR%\plugins\platforms" (I needed to add QT_QPA_PLATFORM_PLUGIN_PATH to windows environment variables) ive rebuilt the 5.12 static version multiple times now with other different configs to try to get it to work and the windows plugin simply never exists in plugins\platforms\
  • This topic is deleted!

    Unsolved
    2
    0 Votes
    2 Posts
    24 Views
  • Application crashes when loading database on weak notebook

    Solved
    15
    0 Votes
    15 Posts
    2k Views
    SGaistS
    No, there are no such scripts. Qt is a C++ framework and it follow its rules. You can use static analysers that will give you warnings about that kind of errors. As for why it did work better on one computer that the other: sheer luck.
  • Rotation item and change point (0,0) in canvas too.

    Solved
    2
    0 Votes
    2 Posts
    277 Views
    SGaistS
    Hi, What canvas are you talking about ?
  • Setting up scaled background image in QDialog

    Unsolved
    2
    0 Votes
    2 Posts
    675 Views
    SGaistS
    Hi, This thread talks about the same subject.