Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.4k Topics 456.5k Posts
  • How to calculate the x value of the pixel based on scale changes

    8
    0 Votes
    8 Posts
    4k Views
    J
    The Value variable holds the position of the scroll bar. It varies from 0 to 99. The below code is present inside the HScrollbar value change event: QRectF sceneRect = plotScene->itemsBoundingRect(); plotScene->setSceneRect((value * ((sceneRect.width())/100)),0,600 ,350); If the ScrollBar position is 0, then the QGraphicsView should hold the QGraphicsScene data from the left edge of the GraphicsScene to the width of the view area. If the ScrollBar position is 99, then the QGraphicsView should hold the QGraphicsScene data from the right edge of the GraphicsScene to the width of the view area. Same kind of behavior, i am expecting for all scale levels. But it is not happening.
  • QPushButton over QGLWidget works wrong

    3
    0 Votes
    3 Posts
    2k Views
    A
    Ok, but how I accomplish that? How can I show the button over the GLWidget?? Has somebody an idea about that?
  • 0 Votes
    5 Posts
    5k Views
    A
    We're continuing this discussion in "this":/forums/viewthread/16199 topic. This topic is closed.
  • Qt QSqlDatabase ODBC and MySQL connection

    2
    0 Votes
    2 Posts
    3k Views
    A
    There is no need to recompile all of Qt to compile the MySQL driver. You can build it separately. That will result in a much faster connection with MySQL than via the ODBC driver. So, I would not recommend your approach.
  • Extending QLineControl

    4
    0 Votes
    4 Posts
    2k Views
    A
    If you think your needed changes are generic enough, you might also considder creating a patch for Qt itself, and contributing that back so others can use it as well in the future, and you don't have to maintain your own copy of QLineEdit and all that is needed for that for the indefinate future...
  • Qt QSqlQueryModel::setQuery control what display in in the column

    5
    0 Votes
    5 Posts
    4k Views
    A
    Hiding the data from the view does not stop you from using the data in other contexts...
  • Understanding code generated by Qt Designer

    4
    0 Votes
    4 Posts
    2k Views
    A
    Actually, uic normally produces a .h file, not a .cpp file... Note that qmake will make sure that the uic tool is called on all .ui files that you list in the FORMS section of your .pro file.
  • Best practices while creating a download manager

    3
    0 Votes
    3 Posts
    2k Views
    A
    All I get from your question, is that you want to write a download manager (who uses these things any more?!), but you have not the faintest idea of what that entails, as you need help on basically every step of the way. Perhaps you should re-think your goals?
  • Qsharedmemory problem

    2
    0 Votes
    2 Posts
    2k Views
    A
    Sorry, we're not here to debug your code. You're not even describing your symptoms...
  • Emiting signal does not work

    13
    0 Votes
    13 Posts
    4k Views
    D
    Andre thanks for your help. I have made some changes in program and it worked. @ QApplication a(argc, argv); mainWindow *w=new mainWindow; mainWidget *mw=new mainWidget; w->setCentralWidget(mw); w->show(); QObject::connect(mw, SIGNAL(signalForShowMessageInStatusBar(QString)), w, SLOT(slotForStatusBarMessage(QString))); mw->functionDatabaseOpen(); return a.exec(); @
  • Questions about QStringBuilder

    6
    0 Votes
    6 Posts
    6k Views
    A
    I think it would be best to raise this issue on IRC. Get onto the freenode network, and pop into the @qt-labs channel. That's where the developers working on Qt itself hang out. There you can discuss if your suggestions are feasible or not. There might be technical reasons for these missing operators, such as the technique used for QStringBuilder not working with these operators... However, a lot of technical insight in how this class actually works interally is needed to answer such questions, and you'll find a lot more of such knowledge on that channel.
  • QT5 QML Desktop Widgets

    4
    0 Votes
    4 Posts
    4k Views
    A
    I don't think there currently is a fixed plan. It certainly wasn't planned to be released in Qt 5.0. Perhaps in a later . release? I guess it will be on the table again at the Qt Contributors Summit in June.
  • QWizard and QWizardPage

    5
    0 Votes
    5 Posts
    3k Views
    A
    I think the best way to go forward is to make your checkboxes available as fields in the wizard (read the documentation on those!). Then, subclass QWizard, and reimplement the nextId() function. That way, you can control which page is the next page. As you can access fields from the wizard as well, you can find access the values of the checkboxes from that function, and return the right value accordingly.
  • How display Time (hh:mm:ss) not statically?

    8
    0 Votes
    8 Posts
    12k Views
    A
    You're welcome, have fun learning Qt!
  • Show a BMP image

    3
    0 Votes
    3 Posts
    4k Views
    E
    i've resolved thanks
  • How to create 'x' CLOSE/ EXIT button on the dialog Box?

    5
    0 Votes
    5 Posts
    7k Views
    B
    @VRonin: Done Successfully! Thanks in tons =)
  • [SOLVED] making Qpainter graphics clickable

    21
    0 Votes
    21 Posts
    20k Views
    ?
    I almost forgot, you may want to take a look here: http://vmpk.sourceforge.net/ It is a piano controller application, the project is quite big and you may have problems finding what you need in there, but it has the type of input you want to achieve. It uses QGraphicsScene thou.
  • QDockWidget and QML

    2
    0 Votes
    2 Posts
    5k Views
    I
    Created "suggestion":http://qt-project.org/forums/viewthread/16116/
  • SQLite :: Unable to read sql view which has aggregate functions

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • QWidget crash on Qt5-alpha

    3
    0 Votes
    3 Posts
    3k Views
    S
    Ok, I found the problem. its from my code. I thought that I should use QGuiApplication instead of QApplication for gui app, and after debugging it appears that the crash happened when QWidget try to get QApplication instance to know the type of the application. Here is my first Qt5 app :) @#include <QtWidgets/QApplication> #include <QtWidgets/QWidget> int main(int argc, char *argv[]) { QApplication a(argc, argv); QWidget w; w.show(); return a.exec(); }@ Thanks.