Results 1 to 2 of 2

Thread: Unable to animate QColor with statically compiled QtEmbedded

  1. #1
    Join Date
    Oct 2010
    Posts
    3
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Question Unable to animate QColor with statically compiled QtEmbedded

    Hi everyone !

    I'm using QtEmbedded 4.6.3 on an ARM processor, and I compile Qt as a static library to save some start time and memory.

    Recently I tried to start a QPropertyAnimation on a QColor, which works with the "classic" version of Qt (X11/shared), but doesn't with my static library.

    I found out that the QColor interpolation function for animations is declared in qguivariantanimation.cpp:70 in the "qRegisterGuiGetInterpolator" function. This function is declared with the Q_CONSTRUCTOR_FUNCTION macro, so when the application is started with the shared library, the function gets called even before the main function starts, which is OK. However, with the static version, the function never gets called, and then my QColor is not interpolated.

    I found out a similar behavior with QVariant : the QColor helper methods are declared in the qRegisterGuiVariant function, which is also declared with the Q_CONSTRUCTOR_FUNCTION macro. However, this function is also explicitely called in the QApplication constructor, so it works with both the shared and static library.

    Shouldn't the qRegisterGuiGetInterpolator function in the QApplication constructor too ? I didn't report this as a bug yet as I don't know if it is one, or if there is something I'm doing wrong. But the qRegisterGuiGetInterpolator function has no explicit call anywhere in the Qt code, so I believe it is assumed to be done by the library loading. Maybe there is an option I have to give to my compiler, in order to have the static library properly initialized at start ?

    Thanks for help !

  2. #2
    Join Date
    Oct 2010
    Posts
    3
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Unable to animate QColor with statically compiled QtEmbedded

    For those who are interested :

    http://bugreports.qt.nokia.com/browse/QTBUG-14788
    Last edited by wawanbreton; 28th October 2010 at 07:54.

Similar Threads

  1. Qt 4.7.0 statically compiled and Qt Creator
    By Suppaman in forum Installation and Deployment
    Replies: 6
    Last Post: 12th October 2010, 12:47
  2. Replies: 3
    Last Post: 20th September 2010, 22:36
  3. Statically compiled Qt 4.1.4 and mySql
    By Djony in forum Installation and Deployment
    Replies: 1
    Last Post: 26th January 2007, 07:13
  4. Replies: 3
    Last Post: 26th July 2006, 13:23
  5. Qt is compiled statically, now what ?
    By probine in forum Qt Programming
    Replies: 1
    Last Post: 30th May 2006, 12:46

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.