Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.9k Posts
  • Stopping a thread that tries to acquire a QSystemSemaphore

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • Source code encoding under Qt5

    8
    0 Votes
    8 Posts
    16k Views
    M
    I get something like this (window style: oxygen, app style: plastique because of @Old plugin format found in lib /usr/lib/kde4/plugins/styles/oxygen.so@): http://dl.dropbox.com/u/680693/qt5label-screenshot.png For me it looks like Latin1 or Windows CP-1251. But maybe problem isn't in Qt itself but in Qt configuration? Maybe font is wrong (serifs? Why there are serifs when my whole system use verdana?)? I didn't set up anything, just use default. EDIT: Interesting... even if I manually change font of label (in designer or in source code) it doesn't change anything in binary.
  • [solved] Promoting with preview

    3
    0 Votes
    3 Posts
    2k Views
    D
    You'll need to create a QtDesigner widget plugin. How to do that is described here http://qt-project.org/doc/qt-4.8/designer-creating-custom-widgets.html
  • Promote widget to custom with preview in designer

    Locked
    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • QTreeView

    18
    0 Votes
    18 Posts
    8k Views
    S
    You are welcome, Kindly edit your first post and add[Solved] to the title.
  • [Solved] Qt- Trouble changing color of Line

    8
    0 Votes
    8 Posts
    15k Views
    V
    If it is going to be only Horizontal or Vertical lines, would suggest to consider QFrame class (Horizontal & Vertical lines comes with Qt Creator Toolbox).
  • Set model not working!!

    5
    0 Votes
    5 Posts
    2k Views
    V
    Would you update the subject with prefix [SOLVED]?
  • Qt creator search window

    3
    0 Votes
    3 Posts
    1k Views
    D
    Great Thank you.
  • Qt 4.6.3

    4
    0 Votes
    4 Posts
    6k Views
    C
    Did you look in the documentation on Qt Project resources before you asked? Here is the result a quick search. http://doc.qt.nokia.com/qtmobility/index.html#platform-compatibility The latest QtMobility available through the Symbian Smart Installer: http://qt-project.org/wiki/Support_for_Symbian#c524a4505a18172e3e7f90528d8b83b4
  • Resolution-independence

    5
    0 Votes
    5 Posts
    2k Views
    B
    Also try using layouts as suggested, but inside the layout properties, remember to use my tips :)
  • How to implement a web control in STATIC COMPILE

    1
    1 Votes
    1 Posts
    1k Views
    No one has replied
  • How to access QTreeWidget items added using qt Creator gui builder

    2
    0 Votes
    2 Posts
    3k Views
    C
    To change the data in the current item use QTreeWidgetItem::setText(). To access the data in arbitrary cells use the QTreeWidget::model() to generate QModelIndex values and then use QAbstractItemModel::data()/setData() To change which item is the current item use QtreeWidget::setCurrentItem() To find another item by its content use QTreeWidget::findItems().
  • QtCreator c++ editor

    5
    0 Votes
    5 Posts
    3k Views
    D
    Hello. Seems i'm late, but maybe someone else will save a few minutes/hours. Qt Creator is great IDE, i prefer it even for plain C++, but the feature you mentioned is really irritating. So, use the source, it's opensource software after all. qt-creator-2.5.0-src\src\plugins\cpptools\cppmodelmanager.cpp: @ QTextCharFormat errorFormat; /* disable error underline errorFormat.setUnderlineStyle(QTextCharFormat::WaveUnderline); errorFormat.setUnderlineColor(Qt::red); */ // set up the format for the warnings. QTextCharFormat warningFormat; /* disable warning underline warningFormat.setUnderlineStyle(QTextCharFormat::WaveUnderline); warningFormat.setUnderlineColor(Qt::darkYellow); */@
  • Is there a working example to create AES and RSA encryption with openSSL

    2
    0 Votes
    2 Posts
    5k Views
    No one has replied
  • [Solved] Center Text in QTextEdit with HTML

    4
    0 Votes
    4 Posts
    6k Views
    J
    Super! Thanks.
  • QGraphicsView inside a QGraphicsView

    3
    0 Votes
    3 Posts
    3k Views
    M
    Missed that part. Thanks for the help. I'll try it.
  • Having problem in creating tree

    3
    0 Votes
    3 Posts
    2k Views
    K
    thanks alot i found the problem i need QList<Tree *>
  • Lambda problem with Qt5

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • Qmake -project searching for fortran sources

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • Drawing data on Qwidget

    10
    0 Votes
    10 Posts
    15k Views
    D
    Every time the laser scanner performs one measurement, you have four data to process: x, y (scanner position), phi (angle) and r (measured distance). This results in a single straight line starting at (x,y) with direction phi and length r, and a black dot at the end, as shown in the images. Everything else in the image stays the same. This is easily doable, also with QPainter. Just create a buffer QPixmap which is initially filled gray once. Then, at every scanner iteration, use drawLine and drawEllipse to draw the line and black dot respectively. These two operations are extremely fast, much faster than painting 16 million pixels individually. In the paint event of your widget, create a QPainter(this) as you did previously, and now use drawPixmap to draw the visible portion (->scrollbars) of the pixmap onto your widget surface. This, too, is very fast. That should solve your problem. Further I suggest you don't fix your coordinate system to 40004000 but adjust its size dynamically. What would you do when the area the scanner sees is very narrow but longer than 4000 pixels? Or why waste so much memory when the area it sees in one run is maybe just 500500?