Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.4k Topics 456.4k Posts
  • How to link two data sources with QListView?

    5
    0 Votes
    5 Posts
    4k Views
    L
    [quote author="zither" date="1310885907"]I thought that, bad performance may be during paint event of QListView. Is it correct?[/quote] No. [quote author="zither" date="1310885907"]How can I fix that?[/quote] You can't. See "here":http://developer.qt.nokia.com/forums/viewthread/7835/#46011.
  • [Linux] Some problems with arguments...

    3
    0 Votes
    3 Posts
    2k Views
    K
    My program should do the same with any arguments list. http://www.youtube.com/watch?v=O4an9pp_VPs I've created a little creencast with my attempts of debugging. Maybe it will be useful.
  • Phonon::MediaSource from QBuffer

    4
    0 Votes
    4 Posts
    4k Views
    G
    [quote author="jim_kaiser" date="1308302390"]Okay... from documentation: So, guessing you're missing the isSequential()? [/quote] I'm try to use QFile as MediaSource to access to mp3 files in Qt Resource (qrc). And I have the same problem as MiGryz. Reimplement isSequential() in QFile with a 'false' result have no effect. Mp3 sometimes playing, sometimes not, sometimes breaks in the middle. If I open the same mp3 as local files(not from qrc) - no problem.
  • [Solved] Error in QStandardItemModel.appendRow

    4
    0 Votes
    4 Posts
    6k Views
    L
    Documentation for appendRow() clearly states that it "Appends a row containing items. If necessary, the column count is increased to the size of items." So what you get is one row with three columns. To do what you want to do, use appendColumn() instead.
  • QTreeView: Root node isn't shown

    2
    0 Votes
    2 Posts
    6k Views
    E
    @ model = new QFileSystemModel; QString home_files = QDesktopServices.storageLocation(QDesktopServices.HomeLocation); QModelIndex homeIndex = model->parent(model->index(home_files)); QString home_path = model->filePath(homeIndex); QModelIndex root_index = model->setRootPath(home_path); treeView = new QTreeView; treeView->setModel(model); treeView->setRootIndex(root_index); QVBoxLayout *mainLayout = new QVBoxLayout; mainLayout->addWidget(treeView); setLayout(mainLayout); @ You can use treeView->expand(), treeView->scrollTo() functions to expand the directory content and scroll to a specific item.
  • Windows Vista/7 cmd.exe problem

    2
    0 Votes
    2 Posts
    3k Views
    L
    -Pressing CTRL + SHIFT while clicking on a shortcut will run the linked program as Administrator.- -Be aware that a Windows service is more than just a regular application. See "QtService":http://qt.gitorious.org/qt-solutions/qt-solutions/trees/master/qtservice.- Me should read the question first. However, I think that this is "not directly possible":http://bugreports.qt.nokia.com/browse/QTBUG-7645 using QProcess.
  • Enable GUI for one platform, disable it for others

    7
    0 Votes
    7 Posts
    4k Views
    D
    [quote author="lord$now" date="1310807244"] Does the Qt plugin bring it's own compiler or uses the one of VS? Which IDE do you recommend for this project? [/quote] Yeah, VS using its own compiler whether or not you using Qt plugin. If you are looking for an crossplatform IDE, you can choose QtCreator or eclipse. However, you can use Visual Studio under windows, and use another IDE under other platform.
  • 0 Votes
    4 Posts
    2k Views
    G
    Where is the problem? you need start and end coordinates and then some QPropertyAnimation. That should do the trick. But calculating start and end positions is up to you.
  • Qt Layout problem: better explained.

    4
    0 Votes
    4 Posts
    3k Views
    L
    If I were to do the same thing, I would just have added a stretch @this->buttonLayout->addStretch()@ Maybe that's exactly the same thing, just a different way to do it, I'm not sure, but you might give it a try to see if it causes the same problem.
  • Searching for strings within a QTextBrowser?

    9
    0 Votes
    9 Posts
    6k Views
    S
    Hi, also you can use regular expression method : link: http://developer.qt.nokia.com/doc/qt-4.7/qml-regexpvalidator.html bq. Detailed Description This element provides a validator, which counts as valid any string which matches a specified regular expression.
  • Removal of TWM frames

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • Wobbling effect in a QLabel

    3
    0 Votes
    3 Posts
    2k Views
    J
    I had this idea in mind but found it a bit dirty :p
  • [Drag&Drop;] QTabWidget

    3
    0 Votes
    3 Posts
    3k Views
    B
    Thx for the answer. I think I'm going to this that way because I haven't found anything better yet. Could anybody say something about my last question?
  • How to use same action of the key across any widget in the application?

    2
    0 Votes
    2 Posts
    1k Views
    G
    You use a QAction with a QKeySequence and set the QActions "shortcut context":http://doc.qt.nokia.com/4.7/qaction.html#shortcutContext-prop
  • Not responding dialog

    8
    0 Votes
    8 Posts
    4k Views
    C
    [quote author="r@h@" date="1310724528"] @ AddContent *myAddContent=new AddContent; myAddContent->show(); this->close(); @ [/quote] You have some problems here. Where you delete the memory allocated for myAddContent ? And ... are you sure you want to close first dialog ? If you just want to hide call QWidget::hide() or QDialog::setVisible(false)
  • QDebug messages don'T appear in static library

    3
    0 Votes
    3 Posts
    3k Views
    L
    No, none of them...
  • When to start learning QT

    12
    0 Votes
    12 Posts
    4k Views
    Z
    Hi and welcome. Here is a very simple introductory "tutorial":http://developer.qt.nokia.com/wiki/Basic_Qt_Programming_Tutorial that walks you through a first Qt application project using Qt Creator (the best IDE ever)! As long as you have the basics of C++ under your belt, learning Qt should not be difficult. Some areas are more tricky than others or require some domain-specific knowledge (ie QtSql assumes some knowledge about SQL). If you encounter any specific problems then please ask on these forums and the community will do its best to help you resolve them. Good luck with your adventure!
  • Debugging in the Qt Event Loop?

    2
    0 Votes
    2 Posts
    6k Views
    L
    You could set a conditional breakpoint on "QCoreApplication::postEvent":http://doc.qt.nokia.com/latest/qcoreapplication.html#postEvent checking for receiver=0, event_type=0, etc. . If you need more information as to what exactly happened, you could have a look at "reverse debugging":http://www.gnu.org/software/gdb/news/reversible.html EDIT: fixed second link
  • How to add translation to Qt repository?

    5
    0 Votes
    5 Posts
    3k Views
    L
    AFAIK, all translation merge requests are always on the qt repository. However, you could ask the Qt developers via IRC at irc.freenode.net #qt-labs.
  • KGlobal::Locale Warning

    8
    0 Votes
    8 Posts
    6k Views
    L
    This problem was discussed before "here":http://developer.qt.nokia.com/forums/viewthread/7159 ,although no solution was found. However, I would suggest that you try debugging: From KGlobal.cpp @ 00173 // If you hit the warning below, here's how to debug it in gdb: 00174 // (gdb) set auto-solib-add on 00175 // (gdb) b qt_message_output 00176 // (gdb) run 00177 // It will stop at the "-nograb" information. 00178 // (gdb) b KLocalePrivate::KLocalePrivate 00179 // (gdb) c 00180 // And now it will stop at the first construction of the KLocale object, type bt or go up to find the 00181 // guilty i18n call. @