Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.5k Posts
  • [SOLVED] Qt GUI for my multi-threaded console app on Linux?

    5
    0 Votes
    5 Posts
    6k Views
    V
    [quote author="MuldeR" date="1335138403"] Qt provides a QThread class to manage threads. As with all GUI frameworks that I am aware of, you can't access GUI widgets directly from any thread, except for the "main" thread (i.e. the thread that processes the event loop). [/quote] -- Ohhh, I see. I got it, I might have more detailed questions later. Thanks for your post!
  • How to get bugreport/suggestion evaluated.

    3
    0 Votes
    3 Posts
    2k Views
    M
    Thanks for the quick reply! [quote author="1+1=2" date="1335138267"]This suggestion can not be accepted by Qt4.8, unless there is plan for Qt4.9. Otherwise, application linked to Qt4.8.3 will refuse to work with Qt4.8.0.[/quote] That's a pity. But I see that it would break binary compatibility. I really hope there will be a Qt 4.9, as Qt 5 looks like it will still need a lot of effort and time until it can replace Qt 4 for native C++ development. Until then, I'll need to build Qt 4.8.x with custom patches... [quote author="1+1=2" date="1335138267"]However, If you think this important for you, you can push a commit through gerrit http://wiki.qt-project.org/Setting_up_Gerrit for Qt5.0 before Qt5.0 beta released.[/quote] Will do that. Thanks.
  • How to use <QGeometryData> namespace

    Locked
    2
    0 Votes
    2 Posts
    1k Views
    G
    Closed due to "double post":/forums/viewthread/16550.
  • Qt Gui Application cannot locate QGeometryData namepsace

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • [Solved]Make a widget "untouchable"

    9
    0 Votes
    9 Posts
    3k Views
    G
    [quote author="TheDestroyer" date="1335095483"]Oh, OK! I thought there's some button for that... weird. But OK. Done! :) Thanks.[/quote] It's in the works. You can have a look into the new feature in the "QnA Testing Area":/forums/viewforum/46/.
  • 0 Votes
    2 Posts
    2k Views
    K
    AFAIK retrieving this information requires a special driver for your printer. You might want to check for special driver API.
  • [SOLVED] Add a search QLineEdit to a QTableView

    4
    0 Votes
    4 Posts
    4k Views
    F
    Thank you very much for your suggestions. Will look into them!
  • Print using DYMO LabelWriter 450 twin turbo

    2
    0 Votes
    2 Posts
    2k Views
    A
    What OS? What printer drivers? What problems? I am using a Brother label printer, in Linux, Win. XP and Vista works fine however Win. 7 is adding some extra margins which is messing up the labels.
  • [Solved] Remembering the last used printer

    3
    0 Votes
    3 Posts
    2k Views
    A
    Thank you Volker. It looks like the method QPrinter.printerName() returns the name of a real printer only. That's exactly what I am looking for. Just that during testing I was printing to PDF file and the printerName for that was coming as NULL string.
  • Mysql plugin not loaded when running in debug mode

    3
    0 Votes
    3 Posts
    2k Views
    J
    Actuelly, i had already created the symlinks as I too thought it was the issue. However, activating linker logs showed that it was not even loading the original plugin to start with. I then looked at what QStringList QCoreApplication::libraryPaths would return, and the value was different to when running in non-debug mode. In non-debug it points to the Qt system plugin directory (where the MySQL plugin was copied) but when running in debug mode it is set to the working dir. So I simply created a link in my working directory to the system Qt lib. And it's now working. A tad confusing... Since I've found why it's crashing, and the bug is in qt unfortunately. Thanks for the help.
  • No console window in GUI app with CONFIG+=console

    8
    0 Votes
    8 Posts
    14k Views
    G
    A QApplication always initializes the graphics system. For a real console app, without using QtGui module, you need QCoreApplication. There is no easy way to provide a "debug console" in your application. You will need to attach to the windows service for that or provide a logger window for qDebug/qWarning/qError yourself. For the latter, there is an example for a "Browser for QDebug Log Output":/wiki/Browser_for_QDebug_output in the wiki. PS: There's another, more sophisticated logger framework. See the "announcement in the showcase forum":/forums/viewthread/2654.
  • DrawText() taking high cpu usage.

    7
    0 Votes
    7 Posts
    3k Views
    G
    Moved to the General Forum, this is Qt related and no C++ issue.
  • How to delete object on the heap when another heap object is deleted

    5
    0 Votes
    5 Posts
    2k Views
    A
    Check the documentation on using Qt Designer. It explains you all the ways you can use the .ui files, including the setupUi call.
  • Errors I am getting in my class definition of Qt Widget Application

    3
    0 Votes
    3 Posts
    2k Views
    F
    gmaro, Thanks for the ideas. To answer your question, I am trying to access my textboxes in the widget application so I can change the text. I am still dissecting your code though (still learning C++), so your's could solve my problem.
  • Keyboard event not functioning until first mouse click

    6
    0 Votes
    6 Posts
    4k Views
    L
    Will be trying the proposed solutions this morning. Thank you for the great suggestions,
  • QSqlQuery fails to execute "drop database xyz" query

    3
    0 Votes
    3 Posts
    2k Views
    G
    What error they gives with lastError() ? Worked fine for me in 4.8
  • Sample application - QTreeWidget, QTableWidget, QItemSelectionModel

    3
    0 Votes
    3 Posts
    5k Views
    S
    Hi, You need to use a QTreeView,QTableView and a model(eg: QStandardItemModel to store the information). You also need a class to store the information/data(eg class Student { int m_rollNumber , QString m_name; }; etc ) and in the treeView u need to store the object of this class. When an item/object from the treeView is selected u need to cast this object to your class and then get the information and for the particular columns in tableView u can set the values. You can try this approach to create a sample application.
  • Customize QMenu

    6
    0 Votes
    6 Posts
    4k Views
    N
    thanks for your reply. I will check..
  • Qt SDK doesn't pick up native widgets in Kubuntu

    3
    0 Votes
    3 Posts
    2k Views
    H
    [quote author="GentooXativa" date="1334903757"]Launch QtCreator with @-style native@[/quote] I think that's the default style when launch QtCreator. In Ubuntu, QtCreator can pickup ambience (GTK) style but in Kubuntu, it can not use oxygen style. I've tried that option but it has no effect. Another problem relating to this bug is that: All applications built by QtSDK can not pickup oxygen style in Kubuntu. It will use plastik style instead, just like Qt Creator.
  • 0 Votes
    7 Posts
    2k Views
    R
    (y) franco é um gênio. deu certo aki tbm. :)