Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.5k Topics 457.3k Posts
  • How to change color of the text cursor

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • [SOLVED] Help on QListWidget's Event..

    3
    0 Votes
    3 Posts
    3k Views
    M
    Thanks for your valuable inputs.. DSav.. Its working fine...
  • Qt Custom closable windows

    5
    0 Votes
    5 Posts
    2k Views
    G
    But there are restirictions to the windows flags. Like if you want to have a system menu on windows, you (AFAIK) automatically get a close button. AFAIK you can change that on windows by reimplementing WM_NCXXX messages in the winEvent function of a widget...
  • 0 Votes
    7 Posts
    3k Views
    A
    [quote author="task_struct" date="1314781082"]@Cpowa, as I understand from Andres answer QGraphicsPolygonItem has a bounding rectangle and 0,0 is at its lower right corner. [/quote] Then you misunderstood my post. My point was, that (0,0) is not a fixed point for any item. It is just the origin of the coordinate system, but because you are allowed to use negative coordinates, the actual drawing of the item could happen anywhere relative to this point. You can make (0,0) the upper left or the lower right corner of your item, but you can also make it the center, or draw you item so that (0,0) is completely outside your item. Bottom line: (0,0) can be anywhere. It is another question whether it should, of course.
  • Mac (Cocoa) Command+A does not work with QFileDialog

    3
    0 Votes
    3 Posts
    2k Views
    S
    You can track the status of the bug "here":https://bugreports.qt.nokia.com/browse/QTBUG-8453.
  • How to delete an empty row in QTableWidget?

    5
    0 Votes
    5 Posts
    5k Views
    O
    Indeed, it should work. This snippet perfectly works for me : @ QTableWidget *table = new QTableWidget(2, 3, this); Q_ASSERT(table->rowCount() == 2); table->removeRow(1); Q_ASSERT(table->rowCount() == 1); @
  • Error Message - Could Not Decode [Solved]

    8
    0 Votes
    8 Posts
    16k Views
    M
    Be sure and edit the post title to add [Solved].
  • Qt executable file not working

    3
    0 Votes
    3 Posts
    2k Views
    O
    [quote author="Cayan" date="1314734115"]Which executable is not working then? This should be happening from a different executable that had been generated before.[/quote] My class in Qt Creator is called Wave. I have two files: "Wave" and "Wave-build-desktop". "Wave-build-desktop" was generated by Qt and the executable file called Wave.exe is in there. When i click on Wave.exe to open it, it opens the application window, but none of the push button are working and no items are displayed in the comboboxes. But when i navigate to this file in terminal and execute it from there, the application window pops up and everything works ok.
  • Saving index of QcomboBox[SOLVED]

    7
    0 Votes
    7 Posts
    6k Views
    M
    You do know that you don't have to put save and read code together, right? Volker's examples (settings and getting) were meant to be put in separate places in the code, not called one right before the other...
  • Qt Help Project XML link

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • Edit line in .ini file from Qt Creator[SOLVED]

    9
    0 Votes
    9 Posts
    8k Views
    O
    Yes, thanks guys. Thanks mlong. I used QSettings. Solution: @void wave::on_addboardButton_clicked() { QMap<QString,double> map; QSettings settings("/home/test/Documents/Wave/signalgenerator.ini", QSettings::IniFormat ); settings.beginGroup( "values" ); foreach( QString childKey, settings.childKeys() ){ if (childKey.toInt() == ui->comboBox->currentIndex()+1) { int i = ui->comboBox->count(); i += childKey.toInt(); map[ QString::number(i) ] = ui->newCalNumberAdd->text().toDouble(); ui->comboBox->addItem("Board"+QString::number(i)); } QMapIterator<QString,double> it(map); while( it.hasNext() ){ it.next(); settings.setValue( it.key(), it.value() ); } } settings.endGroup(); }@
  • Getting screen information in both desktop and mobile

    3
    0 Votes
    3 Posts
    3k Views
    AlicemirrorA
    Many thanks! I think that this is sufficient.
  • [Moved] Support of Unicode hindi font

    2
    0 Votes
    2 Posts
    3k Views
    L
    I'm not that font expert but does a font embedded in the applications resources and "QFontDatabase::addApplicationFont()":http://doc.qt.nokia.com/latest/qfontdatabase.html#addApplicationFont not work?
  • QVTK and QGLViewer Difference!!

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • 0 Votes
    9 Posts
    6k Views
    G
    Problem is this code snippet: @     listButtons[grid_button]->setMinimumSize(QSize(grid_button_width, grid_button_height));     listButtons[grid_button]->setMaximumSize(QSize(grid_button_width, grid_button_height));     listButtons[grid_button]->setBaseSize(QSize(grid_button_width, grid_button_height)); @ The sizes of buttons and the spacing of layouts differ from platform to platform. You do set a fixed size, which will clash with the platform defaults.
  • When to delete QThread

    11
    0 Votes
    11 Posts
    16k Views
    L
    ... and what if I try: @ GestoreComunicazioneSatellite::~GestoreComunicazioneSatellite() { m_thread->exit(123); m_thread->deleteLater(); } @ ?
  • Can I Customize QTreeView this way?

    2
    0 Votes
    2 Posts
    3k Views
    D
    Yes, a delegate is definitely what you want. Subclass QStyledItemDelegate and do your custom painting there.
  • [SOLVED] smiles in textedit

    4
    0 Votes
    4 Posts
    2k Views
    A
    I have merged your two topics into one.
  • 0 Votes
    3 Posts
    1k Views
    A
    As stated by Gerolf: you already asked that question, and got your answer. Closing this topic.
  • New to Qt having fun but...

    3
    0 Votes
    3 Posts
    2k Views
    O
    And remember that a slot is a normal C++ function (member function). Therefore you can perform any action in your slot. For your example, it will give : @ void MyClass::onMyButtonClicked() { myLabel->setText(myLineEdit->text()); } @ And btw, welcome and have fun with Qt :)