Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.7k Topics 458.0k Posts
  • How to set moc on VS addin 1.1.6 and Qt 4.7.0

    4
    0 Votes
    4 Posts
    3k Views
    S
    Wierd, works for me. All I do is add the Q_OBJECT macro and save the file and it generates everything needed to compile, both on 2010 and 2008....
  • QToolButton stylesheet

    2
    0 Votes
    2 Posts
    5k Views
    ?
    I think you know that the setToolButtonStyle() can only set the icon position wrt the text. e.g. the "folder" icon for the File->Open ... not to be confused with menu arrow position. From what I've seen, I don't think by default you can set the menu arrow position to a different location using stylesheet. Check this "faq":http://developer.qt.nokia.com/faq/answer/how_can_i_draw_custom_subcontrols_for_a_complex_control on a similar example on how to draw custom sub controls for a complex control
  • Extending SWT with Qt widgets

    3
    0 Votes
    3 Posts
    4k Views
    Z
    I have read this documentation - but experimenting with static linking takes a lot of time (i.e. you need to completely rebuild Qt) - and it does not build WebKit when you do configure -static. As I am not sure if it is really doable, I wonder if somebody could try to build it if he already have the configured information.
  • Error getting current time

    16
    0 Votes
    16 Posts
    8k Views
    F
    well i didnt post a complete code solution, i only mentioned a thread that sleeps a bit in every loop
  • Embedding Qt in SWT (win32)

    6
    0 Votes
    6 Posts
    7k Views
    Z
    I created a new "forum topic":http://developer.qt.nokia.com/forums/viewthread/1105/ that has link to published sources.
  • Automagically resize window

    6
    0 Votes
    6 Posts
    9k Views
    ?
    so would the solution be ... if the pixmap size is smaller than the current label size, then call setGeometry on the dialog based on the pixmap size? also if not programatically, then one can use the setSizeGripEnabled on the dialog I think.
  • Db application c++

    2
    0 Votes
    2 Posts
    2k Views
    S
    No, 'just' canghe the connection string, or maybe you can use ODBC for connection.
  • A bug in Qt's flash rendering using the flash plugin

    11
    0 Votes
    11 Posts
    6k Views
    1
    Note to all who had this problem, update Qt via the ubuntu repository, and you may or may not need to restart for it to take effect, but this bug is fixed.
  • Non-Ascii characters in Windows console

    4
    0 Votes
    4 Posts
    4k Views
    S
    Yes, the cmd shell does obviously not support Latin1. I can change the font using the chcp command, but no avaiable font matches Latin1. But QT supports encoding to the console encoding, which is "IBM 850" in my case. What I need is a method that tells me the current encoding of the console font, so I can set the correct encofing in my program.
  • Render directly to screen

    3
    0 Votes
    3 Posts
    3k Views
    Y
    It could be possible by either accessing your display driver/framebuffer directly or you can have your customized paint engine. bq. To render outside of Qt's paint system, e.g., if you require native painting primitives, you need to reimplement QWidget::paintEngine().
  • Using QThread

    10
    0 Votes
    10 Posts
    7k Views
    J
    Excellent discussion! Thanks for all the options. There's a few other conditions I have on this problem, but looks solvable at a much higher level than I'm using.
  • How can I add a label to a QWidget's title bar?

    2
    0 Votes
    2 Posts
    4k Views
    T
    Unless you mean a tool bar or the status bar, this is in general not possible since the title bar is outside of Qt's control (it is provided by the window manager). There may be platform-specific solutions for adding things to the title bar though. At least I've seen applications that appear to do that on Windows and Mac. But you would have to use the platform API for that.
  • Rendering Japanese text on PC / Mac / Linux

    2
    0 Votes
    2 Posts
    3k Views
    T
    You will need a font for the languages you want to use. If such a font is provided then Qt can render "most of the world's writing systems". This refers to being able to do all the complex arranging of the individual bits and pieces found in the font file correctly.
  • Incorrect CSS handling in Qt Svg module?

    3
    0 Votes
    3 Posts
    4k Views
    ?
    QtSvgRenderer also fails to load the CSS if the SVG uses relative path to the CSS. Have logged a bug "here":http://bugreports.qt.nokia.com/browse/QTBUG-14043
  • QAction Group Vs. Vector and Array

    9
    0 Votes
    9 Posts
    6k Views
    F
    Do remember that QAction is a QObject and can therefore not be copied. If you want to pass the QAction around, use pointers to the thing. @myAction[index] = new QAction(tr("HI"), this);@ Of course myAction has to be of the type QAction *[].
  • Suggestion for a setStyleSheet call for SVG

    3
    0 Votes
    3 Posts
    3k Views
    ?
    Added this to Issue Tracker: "http://bugreports.qt.nokia.com/browse/QTBUG-14000":http://bugreports.qt.nokia.com/browse/QTBUG-14000
  • How to get mousePressEvent by parent widget?

    3
    0 Votes
    3 Posts
    5k Views
    J
    Thank you very much! Your suggestion is very helpful. And I should reconsider my approach. I want to move QCommnadLinkButton by drag. But I should define the change of location in subclass inherited from QCommnadLinkButton, shouldn't you? I will try and apologize for my poor skill.
  • Qt 4.7 Gtk theme issues

    9
    0 Votes
    9 Posts
    6k Views
    J
    Thanks for the notification. Disregard the bugreport above since it seems to be unrelated to this issue. The build servers for the SDK had to be upgraded to a new version and a few dependencies required for GTK support were unfortunately lost in the process. We will rebuild and update the packages very soon as neither Qt itself or the SDK should be affected. The standalone builds of creator seems to work fine.
  • [Solved]Hide a tab widget from QTabWidget

    6
    0 Votes
    6 Posts
    15k Views
    ?
    cool :)
  • Comparing unicode chars

    4
    0 Votes
    4 Posts
    4k Views
    T
    Are you aware that 'ä' can be encoded in different ways in unicode? Your simple comparison only detects one way to encode it! You might want to normalize (see "QString::normalized":http://doc.qt.nokia.com/4.7/qstring.html#normalized) both strings before comparing them or be prepared to have strings that produce the same sequence of glyphs (the little drawings on the screen) be considered different. Some normalization forms encode 'ä' in a sequence of unicode codepoints. In that case your character-by-character comparison will miss it.