Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.5k Topics 457.3k Posts
  • Design button is disabled in Qt-Creator 2.1.0

    7
    0 Votes
    7 Posts
    8k Views
    S
    Tobias, There was no inconvenience. I rather think that it was a learning opportunity for me. I found out about this forum and made my first (albeit minor) contribution to the Qt community. Next challenge for me is to start designing my application (or software system) (it is meant to be a learning exercise of different techniques: Qt, HTML5, "CSLA.net":http://www.lhotka.net/cslanet/, behavioural modelling, persistence frameworks...). I think I have to ask your opinion about some of the issues, but that is a discussion for another thread.
  • [SOLVED]Q_DECL_EXPORT works, but macro not...

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • 2nd QInputDialog after QFileDialog immediately closes

    6
    0 Votes
    6 Posts
    6k Views
    L
    It gets worse. I experimented, and it seems that after a call to QFileDialog::getOpenFileName(), many (built-in) dialogs are somehow broken. I confirmed this for QMessageBox and QErrorMessage. Go ahead and change the code in doMain() to this: @ void CMain::doMain() { // check that the message box is working as expected! QMessageBox::information(nullptr, "Test Msgbox", tr("Qt Version: %1").arg(QT_VERSION_STR)); // THIS QFILEDIALOG BREAKS SOMETHING! // comment the next line out to see everything working normal! QFileDialog::getOpenFileName(nullptr, "Open some file", QString(), tr("All files (.)"), nullptr, QFileDialog::ReadOnly); // you'll hear the message box sound, but don't see anything QMessageBox::warning(nullptr, "Test Msgbox 2", "Hi, I'm another msg box"); // the error msg will show up, but it will stay "unusable" in the background // also the program will execute the following file dialog at the same time without waiting QErrorMessage ErrMsg; ErrMsg.setModal(true); ErrMsg.showMessage(tr("This is some sort of error message")); ErrMsg.exec(); // this pops up too early QFileDialog::getOpenFileName(nullptr, "Open another file", QString(), tr("All files (.)"), nullptr, QFileDialog::ReadOnly); cout << "doMain() done. Time to quit()." << endl; qApp->quit(); }//end method @ Comment out the first QFileDialog::getOpenFileName() where the comment suggest it. You'll see the expected behaviour. Now, enable that line, and watch every dialog (except another file dialog) "break" after that line. I've tested this on 2 different machines, both VS 2008, Qt 4.7.1, one Windows 7 32bit, the other WinXP SP3 32bit.
  • Reading Data from CSV FILE

    7
    0 Votes
    7 Posts
    46k Views
    L
    There are plenty of implementations around the internet, just use google. Otherwise you can have a look at the "specification":http://tools.ietf.org/html/rfc4180 and write one yourself for fun/practice. Use Layouts, have a look at the "documentation":http://doc.qt.nokia.com/4.7/layout.html and if you have specific questions, you can always ask (try to figure it out yourself with the documention, though)
  • TableView with header and footer for sums, avg and so on

    6
    0 Votes
    6 Posts
    5k Views
    G
    this goes in directtion of "this":http://developer.qt.nokia.com/forums/viewthread/1978/ topic. From my point of view, you need external tools (like that from ICS), as I think the sollution proposed in the docs (2 views, on rfixed, one scrolling) has some unusual behavior issues (moving focus by keys to the fixed rows etc.).
  • Can Qt host WPF controls?

    12
    0 Votes
    12 Posts
    10k Views
    V
    Maybe this can help you http://www.codeproject.com/KB/toolbars/Ribbon.aspx
  • 0 Votes
    4 Posts
    3k Views
    L
    You're welcome! Don't forget to add "[Solved]" to the thread title if it has been solved for you.
  • [SOLVED] [QComboBox and PSQL] Access PK from another column in the table

    5
    0 Votes
    5 Posts
    3k Views
    L
    I think it's because QSqlRecord uses it only as a key by which to access the field. It is therefore not part of a query to the database (or at least it is not inserted directly into an SQL query) and doesn't need the quotes (which AFAIK you really don't need anyway if you query doesn't contain any whitespaces). Another thing, if you are using MySql (the only database I have experience with, I don't know about other databases) you could also use `` or ' ' as quotes.
  • Reply to Mariusg, Area 51 engineer

    4
    0 Votes
    4 Posts
    2k Views
    G
    I only closed the original thread that was then splitted 3 times, should we remove both?
  • Class hierarchy diagram

    9
    0 Votes
    9 Posts
    15k Views
    J
    @Lukas: +1 We use doxygen with graphviz in our project made in Qt, you could very well use it on Qt itself. It should give you some diagrams and actually probably a complete API reference too.. considering the level of documentation Qt code has.
  • How to get Hardware Info in the Linux using Qt?

    3
    0 Votes
    3 Posts
    4k Views
    G
    Thanks i will to update..
  • How to get the rotate angle by QMatrix.

    5
    0 Votes
    5 Posts
    5k Views
    J
    But, the real problem is probably the order of transformations you are doing because that can alter the result completely.. I say this because you should be able to write your transforms to get the intended result (mathematically).. without needing to try and hard-modify the matrix like you plan to.. maybe you need more specific transformation than a matrix can provide...
  • Can I use ActiveQt to expose custom Qt widgets at ActiveX controls?

    2
    0 Votes
    2 Posts
    2k Views
    G
    It works the same way.
  • Dinamic add resource[Solved]

    21
    0 Votes
    21 Posts
    21k Views
    R
    Many, many thanks for your help!!!
  • Thread priority boosting.....

    11
    0 Votes
    11 Posts
    7k Views
    K
    [quote author="Andre" date="1308260525"]The reason that qDebug() is not listed between the classes, is because it isn't a class. [/quote] Yeah but QDebug is one. "QDebug class":http://doc.qt.nokia.com/4.7/qdebug.html
  • Qmake and white spaces in TARGET, DESTDIR, etc...

    2
    0 Votes
    2 Posts
    7k Views
    F
    Spaces in qmake are (at least in my experience) handled differently per setting. I've had the most luck with good old trial and error. Oftentimes you have to multiple escape characters. Like for example: @\\ @ Or @\\\ @ I've also had luck with quoting "\\ " and other techniques. It has often proved useful to have a look at the generated Makefile and at the actual command produced at the command line. Check if it is what you would have typed in in that case, then add or remove backslashes or quotes as necessary. If that all doesn't work, I'm afraid you'll have to stick to the "No spaces" mantra.
  • [SOLVED] ssh connection

    3
    0 Votes
    3 Posts
    7k Views
    A
    Hi All, I fixed my problem temporarily. I had to make sure that i have access to both client/server via passkeys. And then all the we have to do is something simple as this : QProcess *proc = new QProcess(); proc->start("ssh server_name /path/to/shell/script"); proc->waitForFinished(); QString result=proc->readAllStandardOutput(); ui->textBrowser->setText(result); //writing the result to my text browser Thanks, Hope this helps.
  • StyleSheet issues with MainWindow, Menu

    2
    0 Votes
    2 Posts
    3k Views
    K
    OK, I've found a solution. You need to select the menu item explicitly. Here's an example that leads to the desired style: @ import PyQt4.QtGui as QtGui class MyMainWindow(QtGui.QMainWindow): def __init__(self, parent=None): super(MyMainWindow, self).__init__(parent) self.menu_bar = self.menuBar() print self.menu_bar.isNativeMenuBar() self.menu_bar.setNativeMenuBar(False) print self.menu_bar.isNativeMenuBar() self.session_menu = self.menu_bar.addMenu("&Session") button = QtGui.QPushButton("Testomat") self.setCentralWidget(button) self.setStyleSheet(""" * { background-color: blue; } QMenuBar::item { background-color: blue; } """) if name == "main": import sys app = QtGui.QApplication(sys.argv) main_window = MyMainWindow() main_window.show() app.exec_() @
  • Second use of a QSqlDatabase instance in a QSqlQuery fails.

    5
    0 Votes
    5 Posts
    5k Views
    E
    Ahhh, that is so much easier to read when it's formated :o). Thank you for your insights. I suspect that the problem lies somewhere in there. I appreciate your help.
  • 0 Votes
    1 Posts
    2k Views
    No one has replied